From a75b418a3b31c1274db716ea5bdd071a1b5929ab Mon Sep 17 00:00:00 2001 From: Tobias Peters Date: Sun, 7 Jul 2024 14:35:16 +0000 Subject: [PATCH] remove redundant name in packaging and use default project name instead --- .github/workflows/ci-nel.yml | 2 +- CMakeLists.txt | 9 ++++----- cmake/CMakePresets.nel.json | 1 - nelns/CMakeLists.txt | 2 +- nelns/CMakePackaging.txt | 11 +++++------ 5 files changed, 11 insertions(+), 14 deletions(-) diff --git a/.github/workflows/ci-nel.yml b/.github/workflows/ci-nel.yml index 43db6f3e16..93cac9d46e 100644 --- a/.github/workflows/ci-nel.yml +++ b/.github/workflows/ci-nel.yml @@ -92,5 +92,5 @@ jobs: - uses: actions/upload-artifact@v4 with: name: package-${{ needs.strings.outputs.project-name }}-${{ matrix.os }}-${{ needs.strings.outputs.build-version }} - path: ${{ needs.strings.outputs.build-output-dir }}/${{ needs.strings.outputs.project-name }}/ryzomcore-* + path: ${{ needs.strings.outputs.build-output-dir }}/${{ needs.strings.outputs.project-name }}/${{ needs.strings.outputs.project-name }}-* diff --git a/CMakeLists.txt b/CMakeLists.txt index 846d3a801a..b3baab3170 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -498,14 +498,12 @@ SET(CPACK_PACKAGE_DESCRIPTION_SUMMARY "Ryzom Core MMORPG Framework") SET(CPACK_PACKAGE_VENDOR "Ryzom Core") SET(CPACK_PACKAGE_DESCRIPTION_FILE ${CMAKE_SOURCE_DIR}/README.md) SET(CPACK_RESOURCE_FILE_LICENSE ${CMAKE_SOURCE_DIR}/COPYING) -SET(CPACK_PACKAGE_VERSION_MAJOR "${NL_VERSION_MAJOR}") -SET(CPACK_PACKAGE_VERSION_MINOR "${NL_VERSION_MINOR}") -SET(CPACK_PACKAGE_VERSION_PATCH "${NL_VERSION_PATCH}") SET(CPACK_INSTALL_CMAKE_PROJECTS "${CMAKE_BINARY_DIR};NeL;ALL;/") SET(CPACK_PACKAGE_EXECUTABLES "ryzomcore${NL_VERSION}" "ryzomcore") # NSIS Specific Packing Setup SET(CPACK_PACKAGE_INSTALL_REGISTRY_KEY "RyzomCore") +SET(CPACK_PACKAGE_VERSION ${PROJECT_VERSION}) # to include tweak part of version SET(CPACK_NSIS_MODIFY_PATH "ON") SET(CPACK_NSIS_MUI_ICON ${CMAKE_SOURCE_DIR}/nel/resources/nevraxpill.ico) SET(CPACK_NSIS_MUI_UNIICON ${CMAKE_SOURCE_DIR}/nel/resources/nevraxpill.ico) @@ -516,8 +514,9 @@ SET(CPACK_NSIS_URL_INFO_ABOUT "http:\\\\\\\\dev.ryzom.com\\\\projects\\\\nel\\\\ SET(CPACK_NSIS_CONTACT "matt.raykowski@gmail.com") ## Source Packages -SET(CPACK_PACKAGE_FILE_NAME "ryzomcore-${NL_VERSION}") -SET(CPACK_SOURCE_PACKAGE_FILE_NAME "ryzomcore-${NL_VERSION}") +# remove os part of file name +SET(CPACK_PACKAGE_FILE_NAME "${CPACK_PACKAGE_NAME}-${CPACK_PACKAGE_VERSION}") +SET(CPACK_SOURCE_PACKAGE_FILE_NAME "${CPACK_PACKAGE_NAME}-${CPACK_PACKAGE_VERSION}") IF(WIN32) #SET(CPACK_GENERATOR "NSIS") SET(CPACK_GENERATOR "NSIS;ZIP") diff --git a/cmake/CMakePresets.nel.json b/cmake/CMakePresets.nel.json index ca251061a0..3fb8471d26 100644 --- a/cmake/CMakePresets.nel.json +++ b/cmake/CMakePresets.nel.json @@ -7,7 +7,6 @@ "configurePresets": [ { "binaryDir": "${sourceDir}/build/nel", - "installDir": "${sourceDir}/build/install", "name": "nel", "cacheVariables": { "WITH_STATIC": true, diff --git a/nelns/CMakeLists.txt b/nelns/CMakeLists.txt index 8b9e670e2a..2b79a3f946 100644 --- a/nelns/CMakeLists.txt +++ b/nelns/CMakeLists.txt @@ -1,6 +1,6 @@ cmake_minimum_required(VERSION 3.27) -project(nelns VERSION ${RyzomCore_VERSION} LANGUAGES CXX) +project(NeLNS VERSION ${RyzomCore_VERSION} LANGUAGES CXX) find_package(NeL ${RyzomCore_VERSION} REQUIRED COMPONENTS misc net) diff --git a/nelns/CMakePackaging.txt b/nelns/CMakePackaging.txt index 34a766ebcf..9392eca7a2 100644 --- a/nelns/CMakePackaging.txt +++ b/nelns/CMakePackaging.txt @@ -2,9 +2,7 @@ SET(CPACK_PACKAGE_DESCRIPTION_SUMMARY "NeL MMORPG Framework - Networking Service SET(CPACK_PACKAGE_VENDOR "NeL") SET(CPACK_PACKAGE_DESCRIPTION_FILE ${CMAKE_SOURCE_DIR}/README) SET(CPACK_RESOURCE_FILE_LICENSE ${CMAKE_SOURCE_DIR}/COPYING) -SET(CPACK_PACKAGE_VERSION_MAJOR "${NL_VERSION_MAJOR}") -SET(CPACK_PACKAGE_VERSION_MINOR "${NL_VERSION_MINOR}") -SET(CPACK_PACKAGE_VERSION_PATCH "${NL_VERSION_PATCH}") +SET(CPACK_PACKAGE_VERSION ${PROJECT_VERSION}) # to include tweak part of version SET(CPACK_INSTALL_CMAKE_PROJECTS "${CMAKE_BINARY_DIR};NeLNS;ALL;/") SET(CPACK_PACKAGE_EXECUTABLES "nelns-${NL_VERSION}" "nelns") @@ -29,13 +27,14 @@ SET(CPACK_NSIS_MENU_LINKS ) ## Source Packages -SET(CPACK_PACKAGE_FILE_NAME "nelns-${NL_VERSION}") -SET(CPACK_SOURCE_PACKAGE_FILE_NAME "nelns-${NL_VERSION}") +# remove os part of file name +SET(CPACK_PACKAGE_FILE_NAME "${CPACK_PACKAGE_NAME}-${CPACK_PACKAGE_VERSION}") +SET(CPACK_SOURCE_PACKAGE_FILE_NAME "${CPACK_PACKAGE_NAME}-${CPACK_PACKAGE_VERSION}") IF(WIN32) SET(CPACK_GENERATOR "NSIS") SET(CPACK_SOURCE_GENERATOR "ZIP") ELSE() - SET(CPACK_GENERATOR "TGZ") + SET(CPACK_GENERATOR "TGZ;STGZ") SET(CPACK_SOURCE_GENERATOR "TGZ") ENDIF() set(CPACK_SOURCE_IGNORE_FILES