Skip to content

Commit 01a46a1

Browse files
all static
1 parent 3a32780 commit 01a46a1

7 files changed

Lines changed: 41 additions & 111 deletions

File tree

.github/workflows/job-cmakebuild-linux.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ jobs:
3434
- name: Update the list of packages after we added packages.microsoft.com
3535
run: sudo apt-get update
3636
- name: Install development library
37-
run: sudo apt-get install libasound2-dev libgl1-mesa-dev libpulse-dev libdbus-1-dev libx11-dev libxcursor-dev libxext-dev libxi-dev libxinerama-dev libxrandr-dev libxss-dev libxt-dev libxxf86vm-dev cmake apt-transport-https software-properties-common gcc g++ powershell clang-format-20 libwayland-dev libxkbcommon-dev libassimp-dev libfmt-dev libstb-dev libglfw3-dev libspdlog-dev libyaml-cpp-dev nlohmann-json3-dev libcli11-dev libspirv-cross-c-shared-dev spirv-tools glslang-dev glslang-tools dotnet-runtime-8.0 libgtest-dev
37+
run: sudo apt-get install libasound2-dev libgl1-mesa-dev libpulse-dev libdbus-1-dev libx11-dev libxcursor-dev libxext-dev libxi-dev libxinerama-dev libxrandr-dev libxss-dev libxt-dev libxxf86vm-dev cmake apt-transport-https software-properties-common gcc g++ powershell clang-format-20 libwayland-dev libxkbcommon-dev dotnet-sdk-8.0
3838

3939
- name: CMake Build
4040
run: .\Scripts\BuildEngine.ps1 -Configurations ${{inputs.configuration}}

.github/workflows/job-cmakebuild-macOS.yml

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,9 +23,6 @@ jobs:
2323
- name: Checkout repository
2424
uses: actions/checkout@v4
2525

26-
- name: Install Dependencies
27-
run: brew install vulkan-headers vulkan-loader assimp spirv-headers spirv-tools spirv-cross glslang glfw glew yaml-cpp spdlog googletest
28-
2926
- name: CMake Build
3027
run: .\Scripts\BuildEngine.ps1 -Configurations ${{inputs.configuration}} -Architecture ${{inputs.architecture}} -RunClangFormat 0
3128
shell: pwsh

.github/workflows/job-cmakebuild-windows.yml

Lines changed: 0 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -5,14 +5,6 @@ name: Windows Build Workflow
55
permissions:
66
packages: write
77

8-
env:
9-
USERNAME: mathewbensoncode
10-
VCPKG_EXE: ${{ github.workspace }}/vcpkg/vcpkg
11-
FEED_URL: https://nuget.pkg.github.com/mathewbensoncode/index.json
12-
VCPKG_BINARY_SOURCES: "clear;nuget,https://nuget.pkg.github.com/mathewbensoncode/index.json,readwrite"
13-
VCPKG_ROOT: ${{ github.workspace }}/vcpkg
14-
CMAKE_TOOLCHAIN_FILE: ${{ github.workspace }}/vcpkg/scripts/buildsystems/vcpkg.cmake
15-
168
on:
179
workflow_call:
1810
inputs:
@@ -31,28 +23,6 @@ jobs:
3123
- name: Checkout repository
3224
uses: actions/checkout@v4
3325

34-
- name: Install vcpkg
35-
shell: pwsh
36-
run: git clone --depth=1 https://github.com/Microsoft/vcpkg ${{github.workspace}}/vcpkg
37-
38-
- name: Bootstrap vcpkg
39-
shell: pwsh
40-
run: ${{ github.workspace }}/vcpkg/bootstrap-vcpkg.bat
41-
42-
- name: Add NuGet sources
43-
shell: pwsh
44-
run: |
45-
.$(${{ env.VCPKG_EXE }} fetch nuget) `
46-
sources add `
47-
-Source "${{ env.FEED_URL }}" `
48-
-StorePasswordInClearText `
49-
-Name GitHubPackages `
50-
-UserName "${{ env.USERNAME }}" `
51-
-Password "${{ secrets.GITHUB_TOKEN }}"
52-
.$(${{ env.VCPKG_EXE }} fetch nuget) `
53-
setapikey "${{ secrets.GITHUB_TOKEN }}" `
54-
-Source "${{ env.FEED_URL }}"
55-
5626
- name: CMake Build
5727
run: .\Scripts\BuildEngine.ps1 -Configurations ${{inputs.configuration}} -RunClangFormat 0
5828
shell: pwsh

CMakePresets.json

Lines changed: 19 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@
1313
"CMAKE_CXX_STANDARD": "20",
1414
"CMAKE_CXX_STANDARD_REQUIRED": "ON",
1515
"CMAKE_CXX_EXTENSIONS": "OFF",
16+
"BUILD_SHARED_LIBS": "OFF",
1617
"FETCHCONTENT_QUIET": "OFF",
1718

1819
"VULKAN_HEADERS_ENABLE_INSTALL": "ON",
@@ -52,7 +53,8 @@
5253
"GLSLANG_ENABLE_INSTALL": "ON",
5354
"ALLOW_EXTERNAL_SPIRV_TOOLS": "ON",
5455

55-
"SPIRV_CROSS_ENABLE_TESTS": "OFF"
56+
"SPIRV_CROSS_ENABLE_TESTS": "OFF",
57+
"CMAKE_POLICY_VERSION_MINIMUM": "3.5"
5658
}
5759
},
5860
{
@@ -63,6 +65,7 @@
6365
"binaryDir": "Result.Windows.x64.MultiConfig",
6466
"architecture": "x64",
6567
"cacheVariables": {
68+
"CMAKE_INSTALL_PREFIX": "Result.Windows.x64.MultiConfig",
6669
"CMAKE_CONFIGURATION_TYPES": "Debug"
6770
}
6871

@@ -84,6 +87,7 @@
8487
"generator": "Xcode",
8588
"cacheVariables": {
8689
"BUILD_FRAMEWORK": "ON",
90+
"CMAKE_INSTALL_PREFIX": "Result.Darwin.x64.Debug",
8791
"CMAKE_CONFIGURATION_TYPES": "Debug"
8892
}
8993
},
@@ -94,6 +98,7 @@
9498
"binaryDir": "Result.Darwin.x64.Release",
9599
"cacheVariables": {
96100
"CMAKE_BUILD_TYPE": "Release",
101+
"CMAKE_INSTALL_PREFIX": "Result.Darwin.x64.Release",
97102
"CMAKE_CONFIGURATION_TYPES": "Release"
98103
}
99104
},
@@ -102,22 +107,31 @@
102107
"name": "Darwin_arm64_Debug",
103108
"inherits": "Darwin_x64_Debug",
104109
"binaryDir": "Result.Darwin.arm64.Debug",
105-
"displayName": "Darwin ARM XCode Debug"
110+
"displayName": "Darwin ARM XCode Debug",
111+
"cacheVariables": {
112+
"CMAKE_INSTALL_PREFIX": "Result.Darwin.arm64.Debug"
113+
}
106114
},
107115

108116
{
109117
"name": "Darwin_arm64_Release",
110118
"inherits": "Darwin_x64_Release",
111119
"binaryDir": "Result.Darwin.arm64.Release",
112-
"displayName": "Darwin ARM XCode Release"
120+
"displayName": "Darwin ARM XCode Release",
121+
"cacheVariables": {
122+
"CMAKE_INSTALL_PREFIX": "Result.Darwin.arm64.Release"
123+
}
113124
},
114125

115126
{
116127
"name": "Linux_x64_Debug",
117128
"inherits": "BaseOptions",
118129
"displayName": "Linux Ninja Debug",
119130
"binaryDir": "Result.Linux.x64.Debug",
120-
"generator": "Ninja"
131+
"generator": "Ninja",
132+
"cacheVariables": {
133+
"CMAKE_INSTALL_PREFIX": "Result.Linux.x64.Debug"
134+
}
121135
},
122136
{
123137
"name": "Linux_x64_Release",
@@ -126,6 +140,7 @@
126140
"binaryDir": "Result.Linux.x64.Release",
127141
"generator": "Ninja",
128142
"cacheVariables": {
143+
"CMAKE_INSTALL_PREFIX": "Result.Linux.x64.Release",
129144
"CMAKE_BUILD_TYPE": "Release"
130145
}
131146
}

Obelisk/CMakeLists.txt

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,10 @@ project (Obelisk
99
set (CMAKE_CXX_STANDARD_REQUIRED ON)
1010
set (CMAKE_CXX_STANDARD 20)
1111

12+
13+
list( APPEND CMAKE_INSTALL_RPATH ${CMAKE_INSTALL_PREFIX}/lib )
14+
15+
1216
set (TARGET_NAME Obelisk)
1317

1418
if(${CMAKE_SYSTEM_NAME} STREQUAL "Windows")
@@ -42,15 +46,12 @@ target_compile_definitions(${TARGET_NAME}
4246
_UNICODE
4347
)
4448

45-
target_link_libraries(${TARGET_NAME} PRIVATE
49+
target_link_libraries(${TARGET_NAME} PUBLIC
4650
tetragrama
4751
imported::External_obeliskLibs
4852
)
4953

50-
install(DIRECTORY ../Resources/Editor DESTINATION bin)
51-
5254
install(TARGETS ${TARGET_NAME}
53-
RUNTIME DESTINATION bin/Editor
55+
DESTINATION bin/Editor
5456
)
5557

56-
install(DIRECTORY ../Resources/Shaders DESTINATION bin/Editor)

dependencies.cmake

Lines changed: 15 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,7 @@ FetchContent_Declare(
44
fmt
55
GIT_REPOSITORY https://github.com/fmtlib/fmt.git
66
GIT_SHALLOW TRUE
7-
FIND_PACKAGE_ARGS CONFIG
8-
)
7+
)
98

109
FetchContent_Declare(
1110
imgui
@@ -34,42 +33,42 @@ FetchContent_Declare(
3433
glfw3
3534
GIT_REPOSITORY https://github.com/glfw/glfw.git
3635
GIT_SHALLOW TRUE
37-
FIND_PACKAGE_ARGS CONFIG
36+
3837
)
3938

4039
FetchContent_Declare(
4140
spdlog
4241
GIT_REPOSITORY https://github.com/gabime/spdlog.git
4342
GIT_SHALLOW TRUE
44-
FIND_PACKAGE_ARGS CONFIG
43+
GIT_TAG v1.15.3
4544
)
4645

4746
FetchContent_Declare(
4847
EnTT
4948
GIT_REPOSITORY https://github.com/skypjack/entt.git
5049
GIT_SHALLOW TRUE
51-
FIND_PACKAGE_ARGS CONFIG
50+
5251
)
5352

5453
FetchContent_Declare(
5554
assimp
5655
GIT_REPOSITORY https://github.com/assimp/assimp.git
5756
GIT_SHALLOW TRUE
58-
FIND_PACKAGE_ARGS CONFIG
57+
5958
)
6059

6160
FetchContent_Declare(
6261
stduuid
6362
GIT_REPOSITORY https://github.com/mariusbancila/stduuid.git
6463
GIT_SHALLOW TRUE
65-
FIND_PACKAGE_ARGS CONFIG
64+
6665
)
6766

6867
FetchContent_Declare(
6968
yaml-cpp
7069
GIT_REPOSITORY https://github.com/jbeder/yaml-cpp
7170
GIT_SHALLOW TRUE
72-
FIND_PACKAGE_ARGS CONFIG
71+
7372
)
7473

7574

@@ -98,8 +97,9 @@ FetchContent_Declare(
9897
glslang
9998
GIT_REPOSITORY https://github.com/KhronosGroup/glslang.git
10099
GIT_SHALLOW TRUE
100+
GIT_TAG 14.3.0
101101
SOURCE_DIR "${FETCHCONTENT_BASE_DIR}/glslang"
102-
FIND_PACKAGE_ARGS CONFIG
102+
103103
)
104104

105105

@@ -115,22 +115,22 @@ Fetchcontent_Declare(
115115
GTest
116116
GIT_REPOSITORY https://github.com/google/googletest.git
117117
GIT_SHALLOW TRUE
118-
FIND_PACKAGE_ARGS CONFIG
118+
GIT_TAG main
119119
)
120120

121121
Fetchcontent_Declare(
122122
nlohmann_json
123123
GIT_REPOSITORY https://github.com/nlohmann/json.git
124124
GIT_SHALLOW TRUE
125-
FIND_PACKAGE_ARGS CONFIG
125+
126126
)
127127

128128
Fetchcontent_Declare(
129129
tlsf
130130
GIT_REPOSITORY https://github.com/mattconte/tlsf
131131
GIT_SHALLOW TRUE
132132
SOURCE_DIR ${FETCHCONTENT_BASE_DIR}/tlsf
133-
FIND_PACKAGE_ARGS CONFIG
133+
134134
)
135135

136136
Fetchcontent_Declare(
@@ -139,7 +139,7 @@ Fetchcontent_Declare(
139139
GIT_SHALLOW TRUE
140140
GIT_TAG main
141141
SOURCE_DIR ${FETCHCONTENT_BASE_DIR}/CLI11
142-
FIND_PACKAGE_ARGS CONFIG
142+
143143
)
144144

145145

@@ -148,7 +148,7 @@ Fetchcontent_Declare(
148148
GIT_REPOSITORY https://github.com/Nicoshev/rapidhash
149149
GIT_SHALLOW TRUE
150150
SOURCE_DIR ${FETCHCONTENT_BASE_DIR}/rapidhash
151-
FIND_PACKAGE_ARGS CONFIG
151+
152152
)
153153

154154
FetchContent_Declare(Vulkan-Headers
@@ -273,6 +273,7 @@ target_link_libraries(External_obeliskLibs
273273
INTERFACE
274274
CLI11::CLI11
275275
)
276+
276277
add_library(imported::External_obeliskLibs ALIAS External_obeliskLibs)
277278

278279
include(${CMAKE_CURRENT_SOURCE_DIR}/Scripts/CMake/NuGet.cmake)

vcpkg.json

Lines changed: 0 additions & 54 deletions
This file was deleted.

0 commit comments

Comments
 (0)