From ef5eeaba20b3a9473fe2955dea75de0e42c88f70 Mon Sep 17 00:00:00 2001 From: secretfoxtail Date: Sat, 7 Sep 2024 07:41:12 -0600 Subject: OpenSUSE Tumbleweed package requirements Add openSUSE Tumbleweed package requirements --- indra/newview/CMakeLists.txt | 3 +++ 1 file changed, 3 insertions(+) diff --git a/indra/newview/CMakeLists.txt b/indra/newview/CMakeLists.txt index 2a3e49c6f9..25da7612a0 100644 --- a/indra/newview/CMakeLists.txt +++ b/indra/newview/CMakeLists.txt @@ -2112,6 +2112,9 @@ if (LINUX) "apr-util, boost-fiber, boost-program-options, boost-regex, boost-thread, collada-dom, expat, fltk, mesa-libGLU, hunspell, libnghttp2, openjpeg2, SDL2, uriparser, vlc-libs, vlc-plugins-base, libvorbis, xmlrpc-epi" CACHE STRING "RPM package requirements.") elseif (${LINUX_DISTRO} MATCHES opensuse-tumbleweed) + set(CPACK_RPM_PACKAGE_REQUIRES + "libapr-util1-0, libboost_fiber1_85_0, libboost_regex1_85_0, libboost_regex1_85_0, libboost_thread1_85_0, libcollada-dom2_5-dp0, expat, libfltk1_3, libGLU1, libhunspell-1_7-0, libjsoncpp25, libnghttp2-14, openjpeg2, libSDL2-2_0-0, liburiparser1, libvlc5, vlc-codecs, libvorbis0" + CACHE STRING "RPM package requirements.") endif (${LINUX_DISTRO} MATCHES fedora) endif (${LINUX_DISTRO} MATCHES debian OR ${LINUX_DISTRO} MATCHES ubuntu) endif (PACKAGE) -- cgit v1.2.3 From 5d75d75aa7535244d831e8e919ac499fbe8d7672 Mon Sep 17 00:00:00 2001 From: secretfoxtail Date: Sat, 7 Sep 2024 08:02:27 -0600 Subject: Remove extra regex in opensuse & colladadom Now using LLs colladadom --- indra/newview/CMakeLists.txt | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/indra/newview/CMakeLists.txt b/indra/newview/CMakeLists.txt index 25da7612a0..dfcf12139d 100644 --- a/indra/newview/CMakeLists.txt +++ b/indra/newview/CMakeLists.txt @@ -2084,11 +2084,11 @@ if (LINUX) CACHE STRING "Debian package section.") if (${LINUX_DISTRO} MATCHES debian) set(CPACK_DEBIAN_PACKAGE_DEPENDS - "libalut0, libaprutil1, libboost-fiber1.81.0, libboost-filesystem1.81.0, libboost-program-options1.81.0, libboost-regex1.81.0, libboost-thread1.81.0, libcollada-dom2.5-dp0, libexpat1, libfltk1.3, libglu1-mesa, libhunspell-1.7-0, libmeshoptimizer2d (>= 0.18), libnghttp2-14, libsdl2-2.0-0, liburiparser1, libvlc5, libvorbisenc2, libvorbisfile3, libxmlrpc-epi0, vlc-plugin-base" + "libalut0, libaprutil1, libboost-fiber1.81.0, libboost-filesystem1.81.0, libboost-program-options1.81.0, libboost-regex1.81.0, libboost-thread1.81.0, libexpat1, libfltk1.3, libglu1-mesa, libhunspell-1.7-0, libmeshoptimizer2d (>= 0.18), libnghttp2-14, libsdl2-2.0-0, liburiparser1, libvlc5, libvorbisenc2, libvorbisfile3, libxmlrpc-epi0, vlc-plugin-base" CACHE STRING "Debian package dependencies.") elseif (${LINUX_DISTRO} MATCHES ubuntu) set(CPACK_DEBIAN_PACKAGE_DEPENDS - "libaprutil1t64, libboost-fiber1.83.0, libboost-filesystem1.83.0, libboost-program-options1.83.0, libboost-regex1.83.0, libboost-thread1.83.0, libcollada-dom2.5-dp0, libexpat1, libfltk1.3t64, libglu1-mesa, libhunspell-1.7-0, libmeshoptimizer2d, libnghttp2-14, libsdl2-2.0-0, liburiparser1, libvlc5, libvorbisenc2, libvorbisfile3, libxmlrpc-epi0t64, vlc-plugin-base" + "libaprutil1t64, libboost-fiber1.83.0, libboost-filesystem1.83.0, libboost-program-options1.83.0, libboost-regex1.83.0, libboost-thread1.83.0, libexpat1, libfltk1.3t64, libglu1-mesa, libhunspell-1.7-0, libmeshoptimizer2d, libnghttp2-14, libsdl2-2.0-0, liburiparser1, libvlc5, libvorbisenc2, libvorbisfile3, libxmlrpc-epi0t64, vlc-plugin-base" CACHE STRING "Debian package dependencies.") endif (${LINUX_DISTRO} MATCHES debian) elseif (${LINUX_DISTRO} MATCHES fedora OR (${LINUX_DISTRO} MATCHES opensuse-tumbleweed)) @@ -2109,11 +2109,11 @@ if (LINUX) CACHE STRING "RPM package description.") if (${LINUX_DISTRO} MATCHES fedora) set(CPACK_RPM_PACKAGE_REQUIRES - "apr-util, boost-fiber, boost-program-options, boost-regex, boost-thread, collada-dom, expat, fltk, mesa-libGLU, hunspell, libnghttp2, openjpeg2, SDL2, uriparser, vlc-libs, vlc-plugins-base, libvorbis, xmlrpc-epi" + "apr-util, boost-fiber, boost-program-options, boost-regex, boost-thread, expat, fltk, mesa-libGLU, hunspell, libnghttp2, openjpeg2, SDL2, uriparser, vlc-libs, vlc-plugins-base, libvorbis, xmlrpc-epi" CACHE STRING "RPM package requirements.") elseif (${LINUX_DISTRO} MATCHES opensuse-tumbleweed) set(CPACK_RPM_PACKAGE_REQUIRES - "libapr-util1-0, libboost_fiber1_85_0, libboost_regex1_85_0, libboost_regex1_85_0, libboost_thread1_85_0, libcollada-dom2_5-dp0, expat, libfltk1_3, libGLU1, libhunspell-1_7-0, libjsoncpp25, libnghttp2-14, openjpeg2, libSDL2-2_0-0, liburiparser1, libvlc5, vlc-codecs, libvorbis0" + "libapr-util1-0, libboost_fiber1_85_0, libboost_regex1_85_0, libboost_thread1_85_0, expat, libfltk1_3, libGLU1, libhunspell-1_7-0, libnghttp2-14, openjpeg2, libSDL2-2_0-0, liburiparser1, libvlc5, vlc-codecs, libvorbis0" CACHE STRING "RPM package requirements.") endif (${LINUX_DISTRO} MATCHES fedora) endif (${LINUX_DISTRO} MATCHES debian OR ${LINUX_DISTRO} MATCHES ubuntu) -- cgit v1.2.3 From a1df355dde31a899163c87f53365592730e2335d Mon Sep 17 00:00:00 2001 From: secretfoxtail Date: Sat, 7 Sep 2024 08:08:00 -0600 Subject: Tumbleweed: add libboost_program_options1_85_0 Add libboost_program_options1_85_0 to tumbleweed package requires --- indra/newview/CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/indra/newview/CMakeLists.txt b/indra/newview/CMakeLists.txt index dfcf12139d..efa541d4cc 100644 --- a/indra/newview/CMakeLists.txt +++ b/indra/newview/CMakeLists.txt @@ -2113,7 +2113,7 @@ if (LINUX) CACHE STRING "RPM package requirements.") elseif (${LINUX_DISTRO} MATCHES opensuse-tumbleweed) set(CPACK_RPM_PACKAGE_REQUIRES - "libapr-util1-0, libboost_fiber1_85_0, libboost_regex1_85_0, libboost_thread1_85_0, expat, libfltk1_3, libGLU1, libhunspell-1_7-0, libnghttp2-14, openjpeg2, libSDL2-2_0-0, liburiparser1, libvlc5, vlc-codecs, libvorbis0" + "libapr-util1-0, libboost_fiber1_85_0, libboost_regex1_85_0, libboost_thread1_85_0, libboost_program_options1_85_0, expat, libfltk1_3, libGLU1, libhunspell-1_7-0, libnghttp2-14, openjpeg2, libSDL2-2_0-0, liburiparser1, libvlc5, vlc-codecs, libvorbis0" CACHE STRING "RPM package requirements.") endif (${LINUX_DISTRO} MATCHES fedora) endif (${LINUX_DISTRO} MATCHES debian OR ${LINUX_DISTRO} MATCHES ubuntu) -- cgit v1.2.3 From 5727755041d9afaeaa25f98927ca549481b6ffe4 Mon Sep 17 00:00:00 2001 From: secretfoxtail Date: Sat, 7 Sep 2024 08:11:15 -0600 Subject: OpenSUSE Tumbleweed instructions Add OpenSUSE Tumbleweed build instructions to readme.md --- README.md | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index b0173ca2fd..f14129cb93 100644 --- a/README.md +++ b/README.md @@ -49,7 +49,7 @@ $ open newview/Megapahit.app ### Debian ``` -$ sudo apt install cmake pkg-config libxml2-utils libalut-dev libaprutil1-dev libboost-fiber1.81-dev libboost-json1.81-dev libboost-program-options1.81-dev libboost-regex1.81-dev libcollada-dom-dev libexpat1-dev libfltk1.3-dev libfontconfig-dev libfreetype-dev libglu1-mesa-dev libhunspell-dev libjpeg-dev libmeshoptimizer-dev libminizip-dev libnghttp2-dev libpcre3-dev libpipewire-0.3-dev libpng-dev libsdl2-dev liburiparser-dev libvlc-dev libvlccore-dev libvorbis-dev libxft-dev libxml2-dev libxmlrpc-epi-dev libxxhash-dev +$ sudo apt install cmake pkg-config libxml2-utils libalut-dev libaprutil1-dev libboost-fiber1.81-dev libboost-json1.81-dev libboost-program-options1.81-dev libboost-regex1.81-dev libexpat1-dev libfltk1.3-dev libfontconfig-dev libfreetype-dev libglu1-mesa-dev libhunspell-dev libjpeg-dev libmeshoptimizer-dev libminizip-dev libnghttp2-dev libpcre3-dev libpipewire-0.3-dev libpng-dev libsdl2-dev liburiparser-dev libvlc-dev libvlccore-dev libvorbis-dev libxft-dev libxml2-dev libxmlrpc-epi-dev libxxhash-dev $ export LL_BUILD="-O3 -std=c++17 -fPIC -DLL_LINUX=1" $ cmake -DCMAKE_BUILD_TYPE:STRING=Release -DADDRESS_SIZE:INTERNAL=64 -DUSESYSTEMLIBS:BOOL=ON -DUSE_OPENAL:BOOL=ON -DUSE_FMODSTUDIO:BOOL=OFF -DLL_TESTS:BOOL=OFF -DNDOF:BOOL=ON -DROOT_PROJECT_NAME:STRING=Megapahit -DVIEWER_CHANNEL:STRING=Megapahit -DVIEWER_BINARY_NAME:STRING=megapahit -DBUILD_SHARED_LIBS:BOOL=OFF -DINSTALL:BOOL=ON -DPACKAGE:BOOL=ON ../indra $ make -j`nproc` @@ -61,7 +61,7 @@ $ megapahit ### Ubuntu ``` -$ sudo apt install cmake pkg-config libxml2-utils libaprutil1-dev libboost-fiber-dev libboost-json-dev libboost-program-options-dev libboost-regex-dev libcollada-dom-dev libexpat1-dev libfltk1.3-dev libfontconfig-dev libfreetype-dev libglu1-mesa-dev libhunspell-dev libjpeg-dev libmeshoptimizer-dev libminizip-dev libnanosvg-dev libnghttp2-dev libpcre3-dev libpipewire-0.3-dev libpng-dev libsdl2-dev liburiparser-dev libvlc-dev libvlccore-dev libvorbis-dev libxft-dev libxml2-dev libxmlrpc-epi-dev libxxhash-dev +$ sudo apt install cmake pkg-config libxml2-utils libaprutil1-dev libboost-fiber-dev libboost-json-dev libboost-program-options-dev libboost-regex-dev libexpat1-dev libfltk1.3-dev libfontconfig-dev libfreetype-dev libglu1-mesa-dev libhunspell-dev libjpeg-dev libmeshoptimizer-dev libminizip-dev libnanosvg-dev libnghttp2-dev libpcre3-dev libpipewire-0.3-dev libpng-dev libsdl2-dev liburiparser-dev libvlc-dev libvlccore-dev libvorbis-dev libxft-dev libxml2-dev libxmlrpc-epi-dev libxxhash-dev $ export LL_BUILD="-O3 -std=c++17 -fPIC -DLL_LINUX=1" $ cmake -DCMAKE_BUILD_TYPE:STRING=Release -DADDRESS_SIZE:INTERNAL=64 -DUSESYSTEMLIBS:BOOL=ON -DUSE_OPENAL:BOOL=OFF -DUSE_FMODSTUDIO:BOOL=ON -DLL_TESTS:BOOL=OFF -DNDOF:BOOL=ON -DROOT_PROJECT_NAME:STRING=Megapahit -DVIEWER_CHANNEL:STRING=Megapahit -DVIEWER_BINARY_NAME:STRING=megapahit -DBUILD_SHARED_LIBS:BOOL=OFF -DINSTALL:BOOL=ON -DPACKAGE:BOOL=ON ../indra $ make -j`nproc` @@ -73,7 +73,7 @@ $ megapahit ### Fedora ``` -$ sudo dnf install cmake gcc-c++ patchelf apr-util-devel boost-devel collada-dom-devel expat-devel fltk-devel mesa-libGLU-devel hunspell-devel minizip-ng-compat-devel libnghttp2-devel nanosvg-devel openjpeg-devel pipewire-devel pulseaudio-libs-devel SDL2-devel uriparser-devel vlc-devel libvorbis-devel xmlrpc-epi-devel xxhash-devel +$ sudo dnf install cmake gcc-c++ patchelf apr-util-devel boost-devel expat-devel fltk-devel mesa-libGLU-devel hunspell-devel minizip-ng-compat-devel libnghttp2-devel nanosvg-devel openjpeg-devel pipewire-devel pulseaudio-libs-devel SDL2-devel uriparser-devel vlc-devel libvorbis-devel xmlrpc-epi-devel xxhash-devel $ export LL_BUILD="-O3 -std=c++17 -fPIC -DLL_LINUX=1" $ cmake -DCMAKE_BUILD_TYPE:STRING=Release -DADDRESS_SIZE:INTERNAL=64 -DUSESYSTEMLIBS:BOOL=ON -DUSE_OPENAL:BOOL=OFF -DUSE_FMODSTUDIO:BOOL=ON -DLL_TESTS:BOOL=OFF -DNDOF:BOOL=ON -DROOT_PROJECT_NAME:STRING=Megapahit -DVIEWER_CHANNEL:STRING=Megapahit -DVIEWER_BINARY_NAME:STRING=megapahit -DBUILD_SHARED_LIBS:BOOL=OFF -DINSTALL:BOOL=ON -DPACKAGE:BOOL=ON ../indra $ make -j`nproc` @@ -81,9 +81,19 @@ $ cpack -G RPM $ sudo rpm -i megapahit-`cat newview/viewer_version.txt`-Linux.rpm $ megapahit ``` +### OpenSUSE Tumbleweed +``` +$ sudo zypper install gcc-c++ patchelf apr-util-devel boost-devel libboost_url1_85_0-devel expat-devel fltk-devel glu-devel hunspell-devel libnghttp2-devel nanosvg-devel openjpeg2-devel pipewire-devel libpulse-devel SDL2-devel uriparser-devel vlc-devel libvorbis-devel xxhash-devel minizip-ng-devel zlib-ng-devel +$ export LL_BUILD="-O3 -std=c++17 -fPIC -DLL_LINUX=1" +$ cmake -DCMAKE_BUILD_TYPE:STRING=Release -DADDRESS_SIZE:INTERNAL=64 -DUSESYSTEMLIBS:BOOL=ON -DUSE_OPENAL:BOOL=ON -DLL_TESTS:BOOL=OFF -DNDOF:BOOL=ON -DROOT_PROJECT_NAME:STRING=Megapahit -DVIEWER_CHANNEL:STRING=Megapahit -DVIEWER_BINARY_NAME:STRING=megapahit -DBUILD_SHARED_LIBS:BOOL=OFF -DINSTALL:BOOL=ON -DPACKAGE:BOOL=ON ../indra +$ make -j`nproc` +$ cpack -G RPM +$ rpm --addsign megapahit-`cat newview/viewer_version.txt`-Linux.rpm (Set up pgp public key first) +$ sudo rpm -i megapahit-`cat newview/viewer_version.txt`-Linux.rpm +$ megapahit +``` ### FreeBSD - ``` $ setenv LL_BUILD "-O3 -std=c++17 -fPIC" $ sudo su - -- cgit v1.2.3 From d2b65074ac9b2b296ec72c6bf4dd546ce4666bb7 Mon Sep 17 00:00:00 2001 From: Hiroo Ono Date: Thu, 5 Sep 2024 02:51:18 +0900 Subject: Revert "Comment out 'install' lines in collada-dom' CMakeLists.txt, because" This reverts commit faf303b4100ac2f3143e7c1f72130c3ff569a8c7. --- patches/collada-dom-v2.3-r7.patch | 34 ++++++++++++++++------------------ 1 file changed, 16 insertions(+), 18 deletions(-) diff --git a/patches/collada-dom-v2.3-r7.patch b/patches/collada-dom-v2.3-r7.patch index f80a42580e..e964a0c5a1 100644 --- a/patches/collada-dom-v2.3-r7.patch +++ b/patches/collada-dom-v2.3-r7.patch @@ -1,13 +1,14 @@ diff --git a/CMakeLists.txt b/CMakeLists.txt -index b1c1993..cdcba63 100644 +index b1c1993..d9787be 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt -@@ -1,14 +1,25 @@ +@@ -1,14 +1,37 @@ -include_directories(${CMAKE_CURRENT_SOURCE_DIR}/include) -set(COLLADA14_INCLUDE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/include/1.4) -set(COLLADA15_INCLUDE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/include/1.5) +project(colladadom) +cmake_minimum_required(VERSION 3.17) ++cmake_policy(SET CMP0167 NEW) + +include(FindPkgConfig) + @@ -18,6 +19,17 @@ index b1c1993..cdcba63 100644 + +set(COLLADA_DOM_SOVERSION "0") +set(COLLADA_DOM_VERSION "2.3") ++set(COLLADA_DOM_INCLUDE_INSTALL_DIR ++ ${CMAKE_BINARY_DIR}/packages/include/collada ++) ++set(COLLADA_DOM_LIBS_INSTALL_DIR ++ ${CMAKE_BINARY_DIR}/packages/lib ++) ++file(MAKE_DIRECTORY ++ ${COLLADA_DOM_INCLUDE_INSTALL_DIR}/1.4 ++ ${COLLADA_DOM_INCLUDE_INSTALL_DIR}/1.5 ++ ${COLLADA_DOM_LIBS_INSTALL_DIR} ++) + file(GLOB dae_files ${CMAKE_CURRENT_SOURCE_DIR}/src/dae/*.cpp) file(GLOB libxmlplugin_files ${CMAKE_CURRENT_SOURCE_DIR}/src/modules/LIBXMLPlugin/*.cpp) @@ -33,22 +45,8 @@ index b1c1993..cdcba63 100644 if( OPT_COLLADA15 ) add_subdirectory(src/1.5) -@@ -17,8 +28,8 @@ if( OPT_COLLADA14 ) - add_subdirectory(src/1.4) - endif() - --install(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/include/1.4 DESTINATION ${COLLADA_DOM_INCLUDE_INSTALL_DIR} PATTERN ".svn" EXCLUDE PATTERN ".~" EXCLUDE) --install(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/include/1.5 DESTINATION ${COLLADA_DOM_INCLUDE_INSTALL_DIR} PATTERN ".svn" EXCLUDE PATTERN ".~" EXCLUDE) --install(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/include/dae DESTINATION ${COLLADA_DOM_INCLUDE_INSTALL_DIR} PATTERN ".svn" EXCLUDE PATTERN ".~" EXCLUDE) --install(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/include/modules DESTINATION ${COLLADA_DOM_INCLUDE_INSTALL_DIR} PATTERN ".svn" EXCLUDE PATTERN ".~" EXCLUDE) --install(FILES ${CMAKE_CURRENT_SOURCE_DIR}/include/dae.h ${CMAKE_CURRENT_SOURCE_DIR}/include/dae.h DESTINATION ${COLLADA_DOM_INCLUDE_INSTALL_DIR}) -+# install(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/include/1.4 DESTINATION ${COLLADA_DOM_INCLUDE_INSTALL_DIR} PATTERN ".svn" EXCLUDE PATTERN ".~" EXCLUDE) -+# install(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/include/1.5 DESTINATION ${COLLADA_DOM_INCLUDE_INSTALL_DIR} PATTERN ".svn" EXCLUDE PATTERN ".~" EXCLUDE) -+# install(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/include/dae DESTINATION ${COLLADA_DOM_INCLUDE_INSTALL_DIR} PATTERN ".svn" EXCLUDE PATTERN ".~" EXCLUDE) -+# install(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/include/modules DESTINATION ${COLLADA_DOM_INCLUDE_INSTALL_DIR} PATTERN ".svn" EXCLUDE PATTERN ".~" EXCLUDE) -+# install(FILES ${CMAKE_CURRENT_SOURCE_DIR}/include/dae.h ${CMAKE_CURRENT_SOURCE_DIR}/include/dae.h DESTINATION ${COLLADA_DOM_INCLUDE_INSTALL_DIR}) diff --git a/src/1.4/CMakeLists.txt b/src/1.4/CMakeLists.txt -index 17fbaea..93b8256 100644 +index 17fbaea..8df5462 100644 --- a/src/1.4/CMakeLists.txt +++ b/src/1.4/CMakeLists.txt @@ -1,10 +1,26 @@ @@ -80,7 +78,7 @@ index 17fbaea..93b8256 100644 SOVERSION ${COLLADA_DOM_SOVERSION} VERSION ${COLLADA_DOM_VERSION}) -install(TARGETS collada14dom DESTINATION lib${LIB_SUFFIX}) -+# install(TARGETS collada14dom DESTINATION ${COLLADA_DOM_LIBS_INSTALL_DIR}) ++install(TARGETS collada14dom DESTINATION ${COLLADA_DOM_LIBS_INSTALL_DIR}) diff --git a/src/1.5/CMakeLists.txt b/src/1.5/CMakeLists.txt index e061a01..fb73a70 100644 --- a/src/1.5/CMakeLists.txt -- cgit v1.2.3 From 17aaab3d851e533930bc7eb553caa35700b48452 Mon Sep 17 00:00:00 2001 From: Hiroo Ono Date: Sun, 8 Sep 2024 02:25:00 +0900 Subject: In the build of Collada-DOM, Check CMAKE_CXX_COMPILER_ID to set different options according to compiler. --- patches/collada-dom-v2.3-r7.patch | 46 +++++++++++++++++++++++---------------- 1 file changed, 27 insertions(+), 19 deletions(-) diff --git a/patches/collada-dom-v2.3-r7.patch b/patches/collada-dom-v2.3-r7.patch index e964a0c5a1..c500de957d 100644 --- a/patches/collada-dom-v2.3-r7.patch +++ b/patches/collada-dom-v2.3-r7.patch @@ -1,14 +1,13 @@ diff --git a/CMakeLists.txt b/CMakeLists.txt -index b1c1993..d9787be 100644 +index b1c1993..cdcba63 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt -@@ -1,14 +1,37 @@ +@@ -1,14 +1,25 @@ -include_directories(${CMAKE_CURRENT_SOURCE_DIR}/include) -set(COLLADA14_INCLUDE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/include/1.4) -set(COLLADA15_INCLUDE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/include/1.5) +project(colladadom) +cmake_minimum_required(VERSION 3.17) -+cmake_policy(SET CMP0167 NEW) + +include(FindPkgConfig) + @@ -19,17 +18,6 @@ index b1c1993..d9787be 100644 + +set(COLLADA_DOM_SOVERSION "0") +set(COLLADA_DOM_VERSION "2.3") -+set(COLLADA_DOM_INCLUDE_INSTALL_DIR -+ ${CMAKE_BINARY_DIR}/packages/include/collada -+) -+set(COLLADA_DOM_LIBS_INSTALL_DIR -+ ${CMAKE_BINARY_DIR}/packages/lib -+) -+file(MAKE_DIRECTORY -+ ${COLLADA_DOM_INCLUDE_INSTALL_DIR}/1.4 -+ ${COLLADA_DOM_INCLUDE_INSTALL_DIR}/1.5 -+ ${COLLADA_DOM_LIBS_INSTALL_DIR} -+) + file(GLOB dae_files ${CMAKE_CURRENT_SOURCE_DIR}/src/dae/*.cpp) file(GLOB libxmlplugin_files ${CMAKE_CURRENT_SOURCE_DIR}/src/modules/LIBXMLPlugin/*.cpp) @@ -45,18 +33,38 @@ index b1c1993..d9787be 100644 if( OPT_COLLADA15 ) add_subdirectory(src/1.5) +@@ -17,8 +28,8 @@ if( OPT_COLLADA14 ) + add_subdirectory(src/1.4) + endif() + +-install(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/include/1.4 DESTINATION ${COLLADA_DOM_INCLUDE_INSTALL_DIR} PATTERN ".svn" EXCLUDE PATTERN ".~" EXCLUDE) +-install(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/include/1.5 DESTINATION ${COLLADA_DOM_INCLUDE_INSTALL_DIR} PATTERN ".svn" EXCLUDE PATTERN ".~" EXCLUDE) +-install(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/include/dae DESTINATION ${COLLADA_DOM_INCLUDE_INSTALL_DIR} PATTERN ".svn" EXCLUDE PATTERN ".~" EXCLUDE) +-install(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/include/modules DESTINATION ${COLLADA_DOM_INCLUDE_INSTALL_DIR} PATTERN ".svn" EXCLUDE PATTERN ".~" EXCLUDE) +-install(FILES ${CMAKE_CURRENT_SOURCE_DIR}/include/dae.h ${CMAKE_CURRENT_SOURCE_DIR}/include/dae.h DESTINATION ${COLLADA_DOM_INCLUDE_INSTALL_DIR}) ++# install(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/include/1.4 DESTINATION ${COLLADA_DOM_INCLUDE_INSTALL_DIR} PATTERN ".svn" EXCLUDE PATTERN ".~" EXCLUDE) ++# install(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/include/1.5 DESTINATION ${COLLADA_DOM_INCLUDE_INSTALL_DIR} PATTERN ".svn" EXCLUDE PATTERN ".~" EXCLUDE) ++# install(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/include/dae DESTINATION ${COLLADA_DOM_INCLUDE_INSTALL_DIR} PATTERN ".svn" EXCLUDE PATTERN ".~" EXCLUDE) ++# install(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/include/modules DESTINATION ${COLLADA_DOM_INCLUDE_INSTALL_DIR} PATTERN ".svn" EXCLUDE PATTERN ".~" EXCLUDE) ++# install(FILES ${CMAKE_CURRENT_SOURCE_DIR}/include/dae.h ${CMAKE_CURRENT_SOURCE_DIR}/include/dae.h DESTINATION ${COLLADA_DOM_INCLUDE_INSTALL_DIR}) diff --git a/src/1.4/CMakeLists.txt b/src/1.4/CMakeLists.txt -index 17fbaea..8df5462 100644 +index 17fbaea..07d341f 100644 --- a/src/1.4/CMakeLists.txt +++ b/src/1.4/CMakeLists.txt -@@ -1,10 +1,26 @@ +@@ -1,10 +1,32 @@ file(GLOB dom_files ${CMAKE_CURRENT_SOURCE_DIR}/dom/*.cpp) -include_directories(${COLLADA14_INCLUDE_DIR}) -add_library(collada14dom SHARED ${COLLADA_BASE_SOURCES} ${dom_files}) +add_library(collada14dom STATIC ${COLLADA_BASE_SOURCES} ${dom_files}) -+target_compile_options(collada14dom PRIVATE ++if(CMAKE_CXX_COMPILER_ID STREQUAL "GNU") ++ target_compile_options(collada14dom PRIVATE + "-Wno-error=unused-result" "-Wno-cast-user-defined" "-Wno-nonnull" -+) ++ ) ++elseif(CMAKE_CXX_COMPILER_ID STREQUAL "clang") ++ target_compile_options(collada14dom PRIVATE ++ "-Wno-error=unused-result" ++ ) ++endif() +target_include_directories(collada14dom PRIVATE + ${colladadom_SOURCE_DIR}/include + ${colladadom_SOURCE_DIR}/include/1.4 @@ -78,7 +86,7 @@ index 17fbaea..8df5462 100644 SOVERSION ${COLLADA_DOM_SOVERSION} VERSION ${COLLADA_DOM_VERSION}) -install(TARGETS collada14dom DESTINATION lib${LIB_SUFFIX}) -+install(TARGETS collada14dom DESTINATION ${COLLADA_DOM_LIBS_INSTALL_DIR}) ++# install(TARGETS collada14dom DESTINATION ${COLLADA_DOM_LIBS_INSTALL_DIR}) diff --git a/src/1.5/CMakeLists.txt b/src/1.5/CMakeLists.txt index e061a01..fb73a70 100644 --- a/src/1.5/CMakeLists.txt -- cgit v1.2.3 From 478520e7d8ae5c45d35e12e679f65ff6c92dad64 Mon Sep 17 00:00:00 2001 From: Hiroo Ono Date: Sun, 8 Sep 2024 02:35:02 +0900 Subject: 'Clang' is capitalized. Correct it. cf. https://cmake.org/cmake/help/v3.28/variable/CMAKE_LANG_COMPILER_ID.html --- patches/collada-dom-v2.3-r7.patch | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/patches/collada-dom-v2.3-r7.patch b/patches/collada-dom-v2.3-r7.patch index c500de957d..c2da9d04ed 100644 --- a/patches/collada-dom-v2.3-r7.patch +++ b/patches/collada-dom-v2.3-r7.patch @@ -48,7 +48,7 @@ index b1c1993..cdcba63 100644 +# install(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/include/modules DESTINATION ${COLLADA_DOM_INCLUDE_INSTALL_DIR} PATTERN ".svn" EXCLUDE PATTERN ".~" EXCLUDE) +# install(FILES ${CMAKE_CURRENT_SOURCE_DIR}/include/dae.h ${CMAKE_CURRENT_SOURCE_DIR}/include/dae.h DESTINATION ${COLLADA_DOM_INCLUDE_INSTALL_DIR}) diff --git a/src/1.4/CMakeLists.txt b/src/1.4/CMakeLists.txt -index 17fbaea..07d341f 100644 +index 17fbaea..86d2d1d 100644 --- a/src/1.4/CMakeLists.txt +++ b/src/1.4/CMakeLists.txt @@ -1,10 +1,32 @@ @@ -60,7 +60,7 @@ index 17fbaea..07d341f 100644 + target_compile_options(collada14dom PRIVATE + "-Wno-error=unused-result" "-Wno-cast-user-defined" "-Wno-nonnull" + ) -+elseif(CMAKE_CXX_COMPILER_ID STREQUAL "clang") ++elseif(CMAKE_CXX_COMPILER_ID STREQUAL "Clang") + target_compile_options(collada14dom PRIVATE + "-Wno-error=unused-result" + ) -- cgit v1.2.3