-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #53 from YGNI-RType/feat/libdev-3d
Multiple players moving in the appartment with third person camera
- Loading branch information
Showing
77 changed files
with
1,751 additions
and
39 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
/build/* | ||
!/build/.gitkeep | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,65 @@ | ||
cmake_minimum_required(VERSION 3.10) | ||
|
||
project(R-Type) | ||
|
||
set(CMAKE_CXX_STANDARD 20) | ||
set(CMAKE_CXX_STANDARD_REQUIRED YES) | ||
set(CMAKE_CXX_EXTENSIONS NO) | ||
set(CMAKE_DEBUG_POSTFIX d) | ||
|
||
|
||
# set(VCPKG_SHOULD_NOT_UPDATE 1) | ||
include(../../cmake/automate-vcpkg.cmake) | ||
vcpkg_bootstrap() | ||
vcpkg_install_packages(raylib stduuid nlohmann-json) | ||
|
||
if(CMAKE_BUILD_TYPE STREQUAL "Debug") | ||
if (MSVC) | ||
add_compile_options(/D_ITERATOR_DEBUG_LEVEL=0) | ||
endif() | ||
# The static permits to enter the functions, avoid settings the path to a .dll etc... | ||
find_library(GEngine_LIB NAMES GEngine-sd PATHS ../../build/Debug ../../build) | ||
# find_library(GEngine_LIB NAMES GEngined PATHS ../../build/Debug ../../build) | ||
else() | ||
find_library(GEngine_LIB NAMES GEngine-sd PATHS ../../build/Release ../../build) | ||
endif() | ||
|
||
file(GLOB_RECURSE SOURCES source/*.cpp) | ||
file(GLOB_RECURSE HEADERS include/*.h) | ||
|
||
find_package(raylib CONFIG REQUIRED) | ||
find_package(glfw3 CONFIG REQUIRED) | ||
|
||
include_directories(include) | ||
include_directories(../../include) | ||
|
||
add_executable(r-type_client ${SOURCES} ${HEADERS}) | ||
add_executable(r-type_server ${SOURCES} ${HEADERS}) | ||
|
||
if(WIN32) | ||
target_link_libraries(r-type_client PRIVATE ${GEngine_LIB} raylib wsock32 ws2_32) | ||
target_link_libraries(r-type_server PRIVATE ${GEngine_LIB} raylib wsock32 ws2_32) | ||
else() | ||
target_link_libraries(r-type_client PRIVATE ${GEngine_LIB} raylib glfw) | ||
target_link_libraries(r-type_server PRIVATE ${GEngine_LIB} raylib glfw) | ||
endif() | ||
|
||
set_target_properties(r-type_client PROPERTIES | ||
CXX_STANDARD 20 | ||
CXX_STANDARD_REQUIRED YES | ||
CXX_EXTENSIONS NO | ||
DEBUG_POSTFIX ${CMAKE_DEBUG_POSTFIX} | ||
) | ||
set_target_properties(r-type_server PROPERTIES | ||
CXX_STANDARD 20 | ||
CXX_STANDARD_REQUIRED YES | ||
CXX_EXTENSIONS NO | ||
DEBUG_POSTFIX ${CMAKE_DEBUG_POSTFIX} | ||
) | ||
|
||
install(TARGETS r-type_client r-type_server | ||
RUNTIME DESTINATION bin | ||
) | ||
|
||
target_compile_definitions(r-type_server PRIVATE GEngine_Server) | ||
target_compile_definitions(r-type_client PRIVATE GEngine_Client) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
.trash |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
{ | ||
"playerdeath": { "frames": [0, 1, 2, 3, 4, 5], "looping": false }, | ||
"shoot": { "frames": [0, 1], "looping": false }, | ||
"charging": { "frames": [0, 1, 2, 3, 4, 5, 6, 7], "looping": true }, | ||
"beam": { "frames": [0, 1], "looping": true } | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
{ | ||
"enemy": { "frames": [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12] } | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
{ | ||
"spaceship": { "frames": [0, 1, 2, 3, 4], "idleFrameIdx": 2, "looping": false } | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
{ | ||
"small": { "frames": [0, 1, 2, 3, 4, 5], "looping": false } | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
{ | ||
"red_enemy": { "frames": [0, 1, 2, 3, 4, 5, 6, 7] } | ||
} |
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,96 @@ | ||
cmake_minimum_required (VERSION 3.12) | ||
|
||
if(WIN32) | ||
set(VCPKG_FALLBACK_ROOT ${CMAKE_CURRENT_BINARY_DIR}/vcpkg CACHE STRING "vcpkg configuration directory to use if vcpkg was not installed on the system before") | ||
else() | ||
set(VCPKG_FALLBACK_ROOT ${CMAKE_CURRENT_BINARY_DIR}/.vcpkg CACHE STRING "vcpkg configuration directory to use if vcpkg was not installed on the system before") | ||
endif() | ||
|
||
# On Windows, Vcpkg defaults to x86, even on x64 systems. If we're | ||
# doing a 64-bit build, we need to fix that. | ||
if (WIN32) | ||
# Since the compiler checks haven't run yet, we need to figure | ||
# out the value of CMAKE_SIZEOF_VOID_P ourselfs | ||
|
||
include(CheckTypeSize) | ||
enable_language(C) | ||
check_type_size("void*" SIZEOF_VOID_P BUILTIN_TYPES_ONLY) | ||
|
||
if (SIZEOF_VOID_P EQUAL 8) | ||
message(STATUS "Using Vcpkg triplet 'x64-windows'") | ||
set(VCPKG_TRIPLET x64-windows) | ||
endif() | ||
endif() | ||
|
||
if(NOT DEFINED VCPKG_ROOT) | ||
if(NOT DEFINED ENV{VCPKG_ROOT}) | ||
set(VCPKG_ROOT ${VCPKG_FALLBACK_ROOT}) | ||
else() | ||
set(VCPKG_ROOT $ENV{VCPKG_ROOT}) | ||
endif() | ||
endif() | ||
|
||
# Installs a new copy of Vcpkg or updates an existing one | ||
macro(vcpkg_bootstrap) | ||
if(NOT VCPKG_SHOULD_NOT_UPDATE) | ||
_install_or_update_vcpkg() | ||
endif() | ||
|
||
# We know this wasn't set before so we need point the toolchain file to the newly found VCPKG_ROOT | ||
set(CMAKE_TOOLCHAIN_FILE ${VCPKG_ROOT}/scripts/buildsystems/vcpkg.cmake CACHE STRING "") | ||
|
||
# Just setting vcpkg.cmake as toolchain file does not seem to actually pull in the code | ||
include(${VCPKG_ROOT}/scripts/buildsystems/vcpkg.cmake) | ||
|
||
set(AUTOMATE_VCPKG_USE_SYSTEM_VCPKG OFF) | ||
|
||
message(STATUS "Automate VCPKG status:") | ||
message(STATUS " VCPKG_ROOT.....: ${VCPKG_ROOT}") | ||
message(STATUS " VCPKG_EXEC.....: ${VCPKG_EXEC}") | ||
message(STATUS " VCPKG_BOOTSTRAP: ${VCPKG_BOOTSTRAP}") | ||
endmacro() | ||
|
||
macro(_install_or_update_vcpkg) | ||
if(NOT EXISTS ${VCPKG_ROOT}) | ||
message(STATUS "Cloning vcpkg in ${VCPKG_ROOT}") | ||
execute_process(COMMAND git clone https://github.com/Microsoft/vcpkg.git ${VCPKG_ROOT}) | ||
else() | ||
message(STATUS "Auto-updating vcpkg in ${VCPKG_ROOT}") | ||
execute_process(COMMAND git pull WORKING_DIRECTORY ${VCPKG_ROOT}) | ||
endif() | ||
|
||
if(NOT EXISTS ${VCPKG_ROOT}/README.md) | ||
message(FATAL_ERROR "***** FATAL ERROR: Could not clone vcpkg *****") | ||
endif() | ||
|
||
if(WIN32) | ||
set(VCPKG_EXEC ${VCPKG_ROOT}/vcpkg.exe) | ||
set(VCPKG_BOOTSTRAP ${VCPKG_ROOT}/bootstrap-vcpkg.bat) | ||
else() | ||
set(VCPKG_EXEC ${VCPKG_ROOT}/vcpkg) | ||
set(VCPKG_BOOTSTRAP ${VCPKG_ROOT}/bootstrap-vcpkg.sh) | ||
endif() | ||
|
||
if(NOT EXISTS ${VCPKG_EXEC}) | ||
message("Bootstrapping vcpkg in ${VCPKG_ROOT}") | ||
execute_process(COMMAND ${VCPKG_BOOTSTRAP} WORKING_DIRECTORY ${VCPKG_ROOT}) | ||
endif() | ||
|
||
if(NOT EXISTS ${VCPKG_EXEC}) | ||
message(FATAL_ERROR "***** FATAL ERROR: Could not bootstrap vcpkg *****") | ||
endif() | ||
endmacro() | ||
|
||
# Installs the list of packages given as parameters using Vcpkg | ||
macro(vcpkg_install_packages) | ||
message(STATUS "Installing/Updating the following vcpkg-packages: ${PACKAGES_LIST_STR}") | ||
|
||
if (VCPKG_TRIPLET) | ||
set(ENV{VCPKG_DEFAULT_TRIPLET} "${VCPKG_TRIPLET}") | ||
endif() | ||
|
||
execute_process( | ||
COMMAND ${VCPKG_EXEC} install ${ARGN} --allow-unsupported | ||
WORKING_DIRECTORY ${VCPKG_ROOT} | ||
) | ||
endmacro() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
# Set the system name | ||
set(CMAKE_SYSTEM_NAME Darwin) | ||
|
||
# Set the C and C++ compilers | ||
set(CMAKE_C_COMPILER /usr/bin/clang) | ||
set(CMAKE_CXX_COMPILER /usr/bin/clang++) | ||
|
||
# Set the target architecture | ||
set(CMAKE_OSX_ARCHITECTURES "arm64") | ||
|
||
# Set the sysroot (if needed) | ||
# set(CMAKE_SYSROOT /path/to/sysroot) | ||
|
||
# Set the C and C++ flags | ||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -arch ${CMAKE_OSX_ARCHITECTURES}") | ||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -arch ${CMAKE_OSX_ARCHITECTURES}") | ||
|
||
# Set the linker flags | ||
set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -arch ${CMAKE_OSX_ARCHITECTURES}") | ||
set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} -arch ${CMAKE_OSX_ARCHITECTURES}") | ||
set(CMAKE_MODULE_LINKER_FLAGS "${CMAKE_MODULE_LINKER_FLAGS} -arch ${CMAKE_OSX_ARCHITECTURES}") | ||
|
||
# Set the find root path | ||
# set(CMAKE_FIND_ROOT_PATH /path/to/find/root) | ||
# set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER) | ||
|
||
# Set the search paths for libraries and includes | ||
# set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY BOTH) | ||
# set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE BOTH) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
# Set the system name | ||
set(CMAKE_SYSTEM_NAME Darwin) | ||
|
||
# Set the C and C++ compilers | ||
set(CMAKE_C_COMPILER /usr/bin/clang) | ||
set(CMAKE_CXX_COMPILER /usr/bin/clang++) | ||
|
||
# Set the target architecture | ||
set(CMAKE_OSX_ARCHITECTURES "x86_64") | ||
|
||
# Set the sysroot (if needed) | ||
# set(CMAKE_SYSROOT /path/to/sysroot) | ||
|
||
# Set the C and C++ flags | ||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -arch ${CMAKE_OSX_ARCHITECTURES}") | ||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -arch ${CMAKE_OSX_ARCHITECTURES}") | ||
|
||
# Set the linker flags | ||
set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -arch ${CMAKE_OSX_ARCHITECTURES}") | ||
set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} -arch ${CMAKE_OSX_ARCHITECTURES}") | ||
set(CMAKE_MODULE_LINKER_FLAGS "${CMAKE_MODULE_LINKER_FLAGS} -arch ${CMAKE_OSX_ARCHITECTURES}") | ||
|
||
# Set the find root path | ||
# set(CMAKE_FIND_ROOT_PATH /path/to/find/root) | ||
|
||
# Set the search paths for libraries and includes | ||
# set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY BOTH) | ||
# set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
set(CMAKE_SYSTEM_NAME Linux) | ||
set(CMAKE_SYSTEM_PROCESSOR arm) | ||
|
||
set(CMAKE_C_COMPILER "arm-linux-gnueabihf-gcc") | ||
set(CMAKE_CXX_COMPILER "arm-linux-gnueabihf-g++") | ||
|
||
set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER) | ||
set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY BOTH) | ||
set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY) | ||
set(CMAKE_FIND_ROOT_PATH_MODE_PACKAGE ONLY) | ||
|
||
set(CMAKE_C_FLAGS "-march=armv7-a -mfloat-abi=hard -mfpu=neon") | ||
set(CMAKE_CXX_FLAGS "-march=armv7-a -mfloat-abi=hard -mfpu=neon") | ||
|
||
# cache flags | ||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS}" CACHE STRING "c flags") | ||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS}" CACHE STRING "c++ flags") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
# Set the system name and processor | ||
set(CMAKE_SYSTEM_NAME Linux) | ||
set(CMAKE_SYSTEM_PROCESSOR aarch64) | ||
set(CMAKE_CROSSCOMPILING TRUE) | ||
|
||
# Specify the cross compiler | ||
set(CMAKE_C_COMPILER aarch64-linux-gnu-gcc) | ||
set(CMAKE_CXX_COMPILER aarch64-linux-gnu-g++) | ||
|
||
# Where is the target environment | ||
set(CMAKE_FIND_ROOT_PATH /usr/aarch64-linux-gnu) | ||
set(CMAKE_INCLUDE_PATH /usr/include/aarch64-linux-gnu) | ||
set(CMAKE_LIBRARY_PATH /usr/lib/aarch64-linux-gnu) | ||
set(CMAKE_PROGRAM_PATH /usr/bin/aarch64-linux-gnu) | ||
|
||
# Search for programs in the build host directories | ||
set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER) | ||
|
||
# For libraries and headers in the target directories | ||
set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY BOTH) | ||
set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
# Specify the C and C++ compilers | ||
set(CMAKE_SYSTEM_NAME Linux) | ||
set(CMAKE_SYSTEM_PROCESSOR i386) | ||
set(CMAKE_CROSSCOMPILING TRUE) | ||
|
||
set(CMAKE_C_COMPILER gcc) | ||
set(CMAKE_CXX_COMPILER g++) | ||
|
||
# Add the -m32 flag to compile for 32-bit | ||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -m32") | ||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -m32") | ||
|
||
set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -m32") | ||
set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} -m32") | ||
set(CMAKE_MODULE_LINKER_FLAGS "${CMAKE_MODULE_LINKER_FLAGS} -m32") | ||
|
||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS}" CACHE STRING "c flags") | ||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS}" CACHE STRING "c++ flags") | ||
|
||
# Ensure the find_XXX() commands search for 32-bit libraries | ||
set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER) | ||
set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY BOTH) | ||
set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
set(CMAKE_SYSTEM_NAME Windows) | ||
|
||
# Specify the target architecture | ||
set(CMAKE_SYSTEM_PROCESSOR ARM) | ||
|
||
# Set the C and C++ compilers to use MSVC | ||
set(CMAKE_C_COMPILER "cl.exe") | ||
set(CMAKE_CXX_COMPILER "cl.exe") | ||
|
||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} /arch:ARMv7") | ||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /arch:ARMv7") | ||
|
||
# Set the platform to ARM | ||
set(CMAKE_GENERATOR_PLATFORM "ARM" CACHE STRING "CMake generator platform" FORCE) | ||
|
||
# Set the CMake find root path mode to only search in the specified directories | ||
set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER) | ||
set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY BOTH) | ||
set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY) | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
set(CMAKE_SYSTEM_NAME Windows) | ||
|
||
# Specify the target architecture | ||
set(CMAKE_SYSTEM_PROCESSOR ARM) | ||
|
||
# Set the C and C++ compilers to use MSVC | ||
set(CMAKE_C_COMPILER "cl.exe") | ||
set(CMAKE_CXX_COMPILER "cl.exe") | ||
|
||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} /arch:ARM64") | ||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /arch:ARM64") | ||
|
||
# Set the platform to ARM | ||
set(CMAKE_GENERATOR_PLATFORM "ARM" CACHE STRING "CMake generator platform" FORCE) | ||
|
||
# Set the CMake find root path mode to only search in the specified directories | ||
set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER) | ||
set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY BOTH) | ||
set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
set(CMAKE_SYSTEM_NAME Windows) | ||
|
||
# Specify the target architecture | ||
set(CMAKE_SYSTEM_PROCESSOR x86) | ||
|
||
# Set the C and C++ compilers to use MSVC | ||
set(CMAKE_C_COMPILER "cl.exe") | ||
set(CMAKE_CXX_COMPILER "cl.exe") | ||
|
||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} /arch:IA32") | ||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /arch:IA32") | ||
|
||
# Set the platform to x86 | ||
set(CMAKE_GENERATOR_PLATFORM "Win32" CACHE STRING "CMake generator platform" FORCE) | ||
|
||
# Set the CMake find root path mode to only search in the specified directories | ||
set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER) | ||
set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY BOTH) | ||
set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY) |
Oops, something went wrong.