Skip to content

Commit c223425

Browse files
committed
NITWORK: Try fix zstd deps on windows and macos
PATCH
1 parent 4bccb1a commit c223425

File tree

8 files changed

+25
-3
lines changed

8 files changed

+25
-3
lines changed

.github/workflows/compil.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ jobs:
6161
run: sudo ./scripts/install-deps-linux.sh
6262

6363
- name: Compil
64-
run: ./scripts/compil.sh --dry-run
64+
run: ./scripts/compil.sh --no-tidy
6565

6666
macos-compil:
6767
runs-on: macos-latest
@@ -76,4 +76,4 @@ jobs:
7676
run: ./scripts/install-deps-macos.sh
7777

7878
- name: Compil
79-
run: ./scripts/compil.sh --dry-run
79+
run: ./scripts/compil.sh --no-tidy

deps/CMakeLists.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
11
cmake_minimum_required(VERSION 3.15)
22

3+
include(FetchContent)
4+
set(FETCHCONTENT_QUIET OFF)
5+
36
add_subdirectory(raylib)
47
add_subdirectory(boost)
58
add_subdirectory(json)

deps/boost/CMakeLists.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@ FetchContent_Declare(
66
Boost
77
URL "https://github.com/boostorg/boost/releases/download/boost-1.83.0/boost-1.83.0.tar.xz"
88
DOWNLOAD_EXTRACT_TIMESTAMP ON
9+
CMAKE_ARGS "-DCMAKE_BUILD_TYPE=Release" "-DCMAKE_CONFIGURATION_TYPES=\"Release;Release\"" "-DCONFIG=Release"
10+
DOWNLOAD_NO_PROGRESS FALSE
911
)
1012

1113
set(BOOST_RUNTIME_LINK static)

deps/date/CMakeLists.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ FetchContent_Declare(
66
date
77
CMAKE_ARGS "-DCMAKE_BUILD_TYPE=Release" "-DCMAKE_CONFIGURATION_TYPES=\"Release;Release\"" "-DCONFIG=Release"
88
URL "https://github.com/X-R-G-B/R-Bus/releases/latest/download/date.tar"
9+
DOWNLOAD_NO_PROGRESS FALSE
910
DOWNLOAD_EXTRACT_TIMESTAMP TRUE
1011
)
1112

deps/json/CMakeLists.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,10 @@ include(FetchContent)
44

55
FetchContent_Declare(
66
json
7+
CMAKE_ARGS "-DCMAKE_BUILD_TYPE=Release" "-DCMAKE_CONFIGURATION_TYPES=\"Release;Release\"" "-DCONFIG=Release"
78
URL https://github.com/nlohmann/json/releases/download/v3.11.2/json.tar.xz
89
DOWNLOAD_EXTRACT_TIMESTAMP TRUE
10+
DOWNLOAD_NO_PROGRESS FALSE
911
)
1012
FetchContent_MakeAvailable(json)
1113

deps/raylib/CMakeLists.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ FetchContent_Declare(
66
raylib
77
CMAKE_ARGS "-DCMAKE_BUILD_TYPE=Release" "-DCMAKE_CONFIGURATION_TYPES=\"Release;Release\"" "-DCONFIG=Release"
88
URL "https://github.com/X-R-G-B/R-Bus/releases/latest/download/raylib.tar"
9+
DOWNLOAD_NO_PROGRESS FALSE
910
DOWNLOAD_EXTRACT_TIMESTAMP TRUE
1011
)
1112

deps/zstd/CMakeLists.txt

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ FetchContent_Declare(
1010
CMAKE_ARGS "-DCMAKE_BUILD_TYPE=Release" "-DCMAKE_CONFIGURATION_TYPES=\"Release;Release\"" "-DCONFIG=Release"
1111
URL "https://github.com/X-R-G-B/R-Bus/releases/latest/download/zstd.tar"
1212
DOWNLOAD_EXTRACT_TIMESTAMP TRUE
13+
DOWNLOAD_NO_PROGRESS FALSE
1314
SOURCE_SUBDIR build/cmake
1415
)
1516

@@ -21,8 +22,20 @@ target_link_libraries(
2122
libzstd_static
2223
)
2324

25+
target_include_directories(
26+
${PROJECT_NAME_CLIENT}
27+
PRIVATE
28+
${zstd_SOURCE_DIR}/lib
29+
)
30+
2431
target_link_libraries(
2532
${PROJECT_NAME_SERVER}
2633
PRIVATE
2734
libzstd_static
2835
)
36+
37+
target_include_directories(
38+
${PROJECT_NAME_SERVER}
39+
PRIVATE
40+
${zstd_SOURCE_DIR}/lib
41+
)

scripts/compil.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,4 +9,4 @@ else
99
cmake -S . -B build -DCMAKE_EXPORT_COMPILE_COMMANDS=ON -DCMAKE_BUILD_TYPE=Debug
1010
fi
1111

12-
cmake --build build
12+
cmake --build build --parallel

0 commit comments

Comments
 (0)