Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
41 commits
Select commit Hold shift + click to select a range
420ab33
Last build before major rebuild
Jan 23, 2025
58e0de2
add dependence file system, copyright
Feb 11, 2025
4acff9a
add bweas context
Feb 22, 2025
b71c9c3
new interpreter and system of logging
May 13, 2025
6b412c4
fixed lua bugs
May 24, 2025
c781ae2
added integral generator of commands
Jun 2, 2025
46acb98
code refactoring, add doxygen docs
Jun 6, 2025
dfb8f93
added process handler
Jun 7, 2025
5f7c235
new implementation of template creation (regex)
Jun 8, 2025
63120f6
added WinAPI process handler
Jun 9, 2025
663e8eb
fixed configs for build on Windows
Jun 10, 2025
c9ad197
fixed bugs outputs file and cfg cmake
Jun 10, 2025
30e326e
code refactoring and switching to c++23
Jun 11, 2025
6bd3997
code refactoring
Jun 26, 2025
4439c7c
Update README.md
svec1 Jun 26, 2025
d081f22
fixed processes handler
Jun 27, 2025
b08ca5c
refactoring code and bug fixes
Jul 3, 2025
7313e98
fixes bugs and first successful build
Jul 12, 2025
0d8d39c
edit syntax of bwlang
Jul 17, 2025
9cceb30
add anon cc and fixed bug(proc handler)
Jul 21, 2025
c9b29e2
new concept of profiles
Aug 17, 2025
d2d96ce
generators api removed
Aug 18, 2025
8d5051e
package profiles adds
Aug 20, 2025
f53e2b8
new template regex string
Aug 21, 2025
b043bd6
refactoring code and fixed fast cache
Aug 22, 2025
840d2e7
Update cmake-linux.yml
svec1 Aug 28, 2025
6a0798a
creates first bweas package
Aug 28, 2025
17cb921
fixed error compilation
Aug 28, 2025
1485664
fixed error compilation 2
Aug 28, 2025
83a3ca1
new logo
Aug 28, 2025
6cddd55
Merge branch 'unstable' of https://github.com/svec1/bweas into unstable
Aug 28, 2025
2771b1b
fixed error compilation 3
Aug 28, 2025
21c879d
added formatter extenstion
Aug 28, 2025
0e14ff6
fixed logo
Aug 28, 2025
0f60c01
fixed bugs and errors(on win)
Aug 29, 2025
b8ed49a
Update cmake-windows.yml
svec1 Aug 29, 2025
b78c577
fixed linux cmake
Aug 29, 2025
71e2170
Merge branch 'unstable' of https://github.com/svec1/bweas into unstable
Aug 29, 2025
97a65fb
Update CMakeLists.txt
svec1 Aug 29, 2025
113b36b
dev
Aug 29, 2025
8560684
Merge branch 'unstable' of https://github.com/svec1/bweas into unstable
Aug 29, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion .clang-format
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,9 @@ BraceWrapping :
AfterEnum: False
BeforeElse: True

StatementMacros: [call_err_tk_inf_lex, wrap_interpreter, debug_init_time, debug_mark_time_func]
AlignConsecutiveAssignments:
Enabled: true
AcrossEmptyLines: false
AcrossComments: false

StatementMacros: [call_err_tk_inf_lex, wrap_interpreter, debug_init_time, debug_mark_time_func]
10 changes: 5 additions & 5 deletions .github/workflows/cmake-linux.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# This starter workflow is for a CMake project running on multiple platforms. There is a different starter workflow if you just want a single platform.
# See: https://github.com/actions/starter-workflows/blob/main/ci/cmake-single-platform.yml
name: CMake on multiple platforms
name: CMake build on linux

on:
push:
Expand All @@ -25,12 +25,12 @@ jobs:
matrix:
os: [ubuntu-latest]
build_type: [Release]
c_compiler: [gcc, clang]
cpp_compiler: [g++, clang++]
c_compiler: [clang]
cpp_compiler: [clang++]
include:
- os: ubuntu-latest
c_compiler: gcc
cpp_compiler: g++
c_compiler: clang
cpp_compiler: clang++

steps:
- uses: actions/checkout@v4
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/cmake-windows.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# This starter workflow is for a CMake project running on a single platform. There is a different starter workflow if you need cross-platform coverage.
# See: https://github.com/actions/starter-workflows/blob/main/ci/cmake-multi-platform.yml
name: CMake on a single platform
name: CMake build on windows

on:
push:
Expand Down Expand Up @@ -31,7 +31,7 @@ jobs:
- name: Configure CMake
# Configure CMake in a 'build' subdirectory. `CMAKE_BUILD_TYPE` is only required if you are using a single-configuration generator such as make.
# See https://cmake.org/cmake/help/latest/variable/CMAKE_BUILD_TYPE.html?highlight=cmake_build_type
run: cmake -DBWEAS_BUILD_VCPKG=ON -DBWEAS_TEST=ON -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}}
run: cmake -DBWEAS_TEST=ON -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DCMAKE_TOOLCHAIN_FILE=${{github.workspace}}/vcpkg/scripts/buildsystems/vcpkg.cmake -B ${{github.workspace}}/build

- name: Build
# Build your program with the given configuration
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ build_linux/
external/LuaJIT/
external/json/
external/lz4/
docs/doxygen
vcpkg_installed/
vcpkg/

Expand Down
77 changes: 51 additions & 26 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,44 +1,69 @@
option(BWEAS_BUILD_VCPKG "Build bweas with vcpkg" OFF)
if(WIN32 AND BWEAS_BUILD_VCPKG AND EXISTS "${CMAKE_SOURCE_DIR}/vcpkg/scripts/buildsystems/vcpkg.cmake")
execute_process(COMMAND ${CMAKE_COMMAND} -E chdir vcpkg vcpkg/bootstrap-vcpkg.bat WORKING_DIRECTORY ${CMAKE_SOURCE_DIR})

set(CMAKE_TOOLCHAIN_FILE "${CMAKE_SOURCE_DIR}/vcpkg/scripts/buildsystems/vcpkg.cmake" CACHE STRING "")
set(BWEAS_BUILD_VCPKG_N TRUE)
endif()

set(BW_NAME_PRJ bweas)

cmake_minimum_required(VERSION 3.20)
project(${BW_NAME_PRJ} LANGUAGES CXX C)

option(USER_BUILD_LZ4 "Rep LZ4 on external" OFF)
option(USER_BUILD_JSON "Rep JSON_C on external" OFF)
option(USER_BUILD_LUA "Rep LuaJit on external" OFF)
option(BWEAS_TEST "Build of bweas test" OFF)

set(CMAKE_CXX_STANDARD 17)
cmake_minimum_required(VERSION 3.5 FATAL_ERROR)

set(CMAKE_BUILD_TYPE Release)
set(CMAKE_CXX_STANDARD 23)

set(BW_NAME_PRJ bweas)
set(BWEAS_SLIB slbweas)

project(${BW_NAME_PRJ} LANGUAGES CXX)

add_subdirectory(src/)
add_executable(${BW_NAME_PRJ} src/bweas.cpp)

target_link_libraries(${BW_NAME_PRJ} PRIVATE slbweas)

include_directories(${BWEAS_INCLUDE})
include_directories(${BWEAS_INCLUDE} "src/bs/")

if(BWEAS_TEST)
enable_testing()
add_subdirectory(test/)
endif()

if(WIN32)
file(COPY ${CMAKE_SOURCE_DIR}/bweas-config.json DESTINATION ${CMAKE_BINARY_DIR}/${CMAKE_BUILD_TYPE})
set(CURRENT_BINARY_DIR ${CMAKE_BINARY_DIR}/${CMAKE_BUILD_TYPE})
else()
file(COPY ${CMAKE_SOURCE_DIR}/bweas-config.json DESTINATION ${CMAKE_BINARY_DIR})
set(CURRENT_BINARY_DIR ${CMAKE_BINARY_DIR})
endif()

install(TARGETS ${BW_NAME_PRJ} DESTINATION bin)
install(TARGETS bwhook_safe DESTINATION bin)
install(FILES ${CMAKE_SOURCE_DIR}/bweas-config.json DESTINATION bin)
file(COPY ${CMAKE_SOURCE_DIR}/bweas-config.json DESTINATION ${CURRENT_BINARY_DIR})
file(MAKE_DIRECTORY ${CURRENT_BINARY_DIR}/packages)

set_target_properties(bweas PROPERTIES INSTALL_RPATH "${CMAKE_INSTALL_PREFIX}/bin")
endif()
file(GLOB SOURCE_FILES_PACKAGES ${CMAKE_SOURCE_DIR}/packages/*.json)
foreach(SOURCE_FILE IN LISTS SOURCE_FILES_PACKAGES)
file(READ ${SOURCE_FILE} JSON_CONFIG_PACKAGE)
string(JSON NAME_PACKAGE GET ${JSON_CONFIG_PACKAGE} "package-name")
list(APPEND BWEAS_PACKAGES_OUTPUT "${NAME_PACKAGE}.bweas-package")
endforeach()

if(BWEAS_TEST)
enable_testing()
add_subdirectory(test/)
endif()
add_custom_target(
BWEAS_PACKAGES ALL
WORKING_DIRECTORY ${CURRENT_BINARY_DIR}
DEPENDS ${BWEAS_PACKAGES_OUTPUT}
)

set(I_SOURCE_FILE 0)
foreach(SOURCE_FILE IN LISTS SOURCE_FILES_PACKAGES)
list(GET BWEAS_PACKAGES_OUTPUT ${I_SOURCE_FILE} NAME_PACKAGE)
add_custom_command(
OUTPUT ${BWEAS_PACKAGES_OUTPUT}
WORKING_DIRECTORY ${CURRENT_BINARY_DIR}/packages
COMMAND ${CURRENT_BINARY_DIR}/bweas --nolog --package ${SOURCE_FILE}
DEPENDS ${SOURCE_FILE} ${CURRENT_BINARY_DIR}/bweas
COMMENT "Compiled ${BWEAS_PACKAGES_OUTPUT}"
)
set(I_SOURCE_FILE ${I_SOURCE_FILE}+1)
endforeach()

add_dependencies(BWEAS_PACKAGES ${BW_NAME_PRJ})

install(TARGETS ${BW_NAME_PRJ} DESTINATION bin)
install(FILES ${CMAKE_SOURCE_DIR}/bweas-config.json DESTINATION bin)
install(DIRECTORY ${CURRENT_BINARY_DIR}/packages DESTINATION bin)

set_target_properties(bweas PROPERTIES INSTALL_RPATH "${CMAKE_INSTALL_PREFIX}/bin")
Loading
Loading