diff options
| author | ptitSeb <sebastien.chev@gmail.com> | 2023-03-26 10:13:45 +0200 |
|---|---|---|
| committer | ptitSeb <sebastien.chev@gmail.com> | 2023-03-26 10:13:45 +0200 |
| commit | 6ff68849f88cbec622fe7a485e301111319ab8d6 (patch) | |
| tree | ffc2e5a645b6334c073dcf47b78d2e4caefc42c7 | |
| parent | 2ea036e02c3fe1374d32c23f795879623773a5ef (diff) | |
| download | box64-6ff68849f88cbec622fe7a485e301111319ab8d6.tar.gz box64-6ff68849f88cbec622fe7a485e301111319ab8d6.zip | |
|CMAKE] Added NO_LIB_INSTALL to not install x86_64 libs (they will probably need to be installed by some other mean)
| -rwxr-xr-x | CMakeLists.txt | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 4b131d09..433c29ed 100755 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -75,6 +75,7 @@ option(PAGE8K "Set to ON if host device have PageSize of 8K (instead of 4K)" ${P option(PAGE16K "Set to ON if host device have PageSize of 16K (instead of 4K)" ${PAGE16K}) option(PAGE64K "Set to ON if host device have PageSize of 64K (instead of 4K)" ${PAGE64K}) option(STATICBUILD "Set to ON to have a static build (Warning, not working)" ${STATICBUILD}) +option(NO_LIB_INSTALL "Set ON to not install a few x86_64 libs that are used by many program" ${NO_LIB_INSTALL}) if(${CMAKE_VERSION} VERSION_LESS "3.12.2") find_package(PythonInterp 3) @@ -716,6 +717,7 @@ endif() string(COMPARE EQUAL "${CMAKE_HOST_SYSTEM_PROCESSOR}" "i686" _x86) string(COMPARE EQUAL "${CMAKE_HOST_SYSTEM_PROCESSOR}" "x86_64" _x86_64) string(COMPARE EQUAL "${CMAKE_HOST_SYSTEM_PROCESSOR}" "aarch64" _aarch64) +string(COMPARE EQUAL "${CMAKE_HOST_SYSTEM_PROCESSOR}" "riscv64" _riscv64) if(_x86_64 OR _aarch64) add_definitions(-DCONFIG_64BIT) @@ -726,10 +728,12 @@ if(NOT _x86 AND NOT _x86_64) RUNTIME DESTINATION bin) configure_file(system/box64.conf.cmake system/box64.conf) install(FILES ${CMAKE_BINARY_DIR}/system/box64.conf DESTINATION /etc/binfmt.d/) - install(FILES ${CMAKE_SOURCE_DIR}/x64lib/libstdc++.so.5 DESTINATION /usr/lib/x86_64-linux-gnu/) - install(FILES ${CMAKE_SOURCE_DIR}/x64lib/libstdc++.so.6 DESTINATION /usr/lib/x86_64-linux-gnu/) - install(FILES ${CMAKE_SOURCE_DIR}/x64lib/libgcc_s.so.1 DESTINATION /usr/lib/x86_64-linux-gnu/) - install(FILES ${CMAKE_SOURCE_DIR}/x64lib/libpng12.so.0 DESTINATION /usr/lib/x86_64-linux-gnu/) + if(NOT NO_LIB_INSTALL) + install(FILES ${CMAKE_SOURCE_DIR}/x64lib/libstdc++.so.5 DESTINATION /usr/lib/x86_64-linux-gnu/) + install(FILES ${CMAKE_SOURCE_DIR}/x64lib/libstdc++.so.6 DESTINATION /usr/lib/x86_64-linux-gnu/) + install(FILES ${CMAKE_SOURCE_DIR}/x64lib/libgcc_s.so.1 DESTINATION /usr/lib/x86_64-linux-gnu/) + install(FILES ${CMAKE_SOURCE_DIR}/x64lib/libpng12.so.0 DESTINATION /usr/lib/x86_64-linux-gnu/) + endif() install(FILES ${CMAKE_SOURCE_DIR}/system/box64.box64rc DESTINATION /etc/) endif() @@ -764,6 +768,8 @@ set(CPACK_PACKAGE_VERSION_PATCH ${BOX64_REVISION}) set(CPACK_DEBIAN_PACKAGE_CONTROL_EXTRA "${CMAKE_CURRENT_SOURCE_DIR}/postinst") if(_aarch64) set(CPACK_DEBIAN_PACKAGE_ARCHITECTURE "arm64") +elseif(__riscv64) + set(CPACK_DEBIAN_PACKAGE_ARCHITECTURE "riscv64") elseif(_x86_64) set(CPACK_DEBIAN_PACKAGE_ARCHITECTURE "x86_64") else() |