diff options
author | Jörg Frings-Fürst <debian@jff-webhosting.net> | 2024-07-03 10:19:36 +0200 |
---|---|---|
committer | Jörg Frings-Fürst <debian@jff-webhosting.net> | 2024-07-03 10:19:36 +0200 |
commit | b6bd52cd7330a90fc0e44dbe6022551a8dd768a1 (patch) | |
tree | 9804282102f8c40d27407b9c94119b35eeb5013c /distribution/posix | |
parent | c9d0740841fbe0539e42e66d3865672bfcd3ac02 (diff) | |
parent | a14a7a0ccc9de76aeab0b2e4bbf58f1a79deedc2 (diff) |
Update upstream source from tag 'upstream/5.3.0GA'
Update to upstream version '5.3.0GA'
with Debian dir dfd14d63b0238e276ade6f54dd9100325df5b2f9
Diffstat (limited to 'distribution/posix')
-rw-r--r-- | distribution/posix/CMakeLists.txt | 12 | ||||
-rwxr-xr-x | distribution/posix/postinst | 9 | ||||
-rwxr-xr-x | distribution/posix/prerm | 9 |
3 files changed, 7 insertions, 23 deletions
diff --git a/distribution/posix/CMakeLists.txt b/distribution/posix/CMakeLists.txt index 6e44581..f202791 100644 --- a/distribution/posix/CMakeLists.txt +++ b/distribution/posix/CMakeLists.txt @@ -8,10 +8,11 @@ set(CPACK_RPM_PACKAGE_GROUP "Applications/Engineering") set(CPACK_PACKAGE_DESCRIPTION_FILE "${CMAKE_CURRENT_SOURCE_DIR}////xtrkcad-desc.txt") set(CPACK_PACKAGE_FILE_NAME "xtrkcad-setup-${XTRKCAD_VERSION}-${CPACK_PACKAGE_RELEASE}.${CMAKE_SYSTEM_PROCESSOR}") -if(XTRKCAD_PACKAGE_GA_RELEASE) - set(CPACK_INSTALL_PREFIX "/usr" ) -else() +if(XTRKCAD_BETA MATCHES "-beta") set(CPACK_INSTALL_PREFIX "/usr/local" ) +else() + set(CPACK_INSTALL_PREFIX "/usr" ) + set(CPACK_DEBIAN_PACKAGE_CONTROL_EXTRA "${CMAKE_CURRENT_SOURCE_DIR}/postinst;${CMAKE_CURRENT_SOURCE_DIR}/prerm") endif() set(CPACK_PACKAGING_INSTALL_PREFIX ${CPACK_INSTALL_PREFIX}) @@ -59,7 +60,7 @@ set(CPACK_RPM_CHANGELOG_FILE "${CMAKE_CURRENT_SOURCE_DIR}////changelog.txt") set(CPACK_DEBIAN_PACKAGE_SHLIBDEPS ON) -set(CPACK_DEBIAN_PACKAGE_NAME "XTrkCad") +set(CPACK_DEBIAN_PACKAGE_NAME "XTrkCad${XTRKCAD_BETA}") set(CPACK_DEBIAN_PACKAGE_VERSION "1:${XTRKCAD_VERSION}") @@ -95,7 +96,4 @@ set(CPACK_PACKAGE_EXECUTABLES "xtrkcad;XTrkCad-5.2.1-Beta") set(CPACK_CREATE_DESKTOP_LINKS "xtrkcad") -set(CPACK_DEBIAN_PACKAGE_CONTROL_EXTRA "${CMAKE_CURRENT_SOURCE_DIR}/postinst;${CMAKE_CURRENT_SOURCE_DIR}/prerm") - include(CPack) - diff --git a/distribution/posix/postinst b/distribution/posix/postinst index 914534d..969aa7e 100755 --- a/distribution/posix/postinst +++ b/distribution/posix/postinst @@ -7,14 +7,7 @@ else LOGF=/dev/null fi -if [ -d /usr/local/share/xtrkcad ] ; then - INSTALLDIR=/usr/local/share/xtrkcad -elif [ -d /usr/share/xtrkcad ] ; then - INSTALLDIR=/usr/share/xtrkcad -else - echo No existing XTrkCad install >> ${LOGF} - exit 1 -fi +INSTALLDIR=/usr/share/xtrkcad ( su -c "sh ${INSTALLDIR}/xtrkcad-setup install ${INSTALLDIR}" -l $SUDO_USER ) >> ${LOGF} 2>&1 diff --git a/distribution/posix/prerm b/distribution/posix/prerm index 3c5db28..b5ae917 100755 --- a/distribution/posix/prerm +++ b/distribution/posix/prerm @@ -7,14 +7,7 @@ else LOGF=/dev/null fi -if [ -d /usr/local/share/xtrkcad ] ; then - INSTALLDIR=/usr/local/share/xtrkcad -elif [ -d /usr/share/xtrkcad ] ; then - INSTALLDIR=/usr/share/xtrkcad -else - echo No existing XTrkCad install >> ${LOGF} - exit 1 -fi +INSTALLDIR=/usr/share/xtrkcad ( su -c "sh ${INSTALLDIR}/xtrkcad-setup remove ${INSTALLDIR}" -l $SUDO_USER ) >> ${LOGF} 2>&1 |