]> git.rm.cloudns.org Git - xonotic/netradiant.git/commitdiff
library-bundler: improve FreeBSD library bundling
authorThomas Debesse <dev@illwieckz.net>
Tue, 28 Jun 2022 12:13:09 +0000 (14:13 +0200)
committerThomas Debesse <dev@illwieckz.net>
Wed, 29 Jun 2022 14:28:53 +0000 (16:28 +0200)
library-bundler

index 54056c41fe527b803fc399d9ab42898931bcf1ee..e9a7ccddf12d1eef487ed2cb93015a2ea0eb7310 100755 (executable)
@@ -105,7 +105,7 @@ Multi::excludeLdd () {
                                        Common::noOp
                                # FreeBSD specific
                                elif echo "${ldd_line}" \
-                                       | egrep -q '/libc++|/libgxxrt'
+                                       | egrep -q '/libc\+\+|/libgxxrt'
                                then
                                        Common::noOp
                                else
@@ -176,17 +176,17 @@ Multi::getRootPrefix () {
        local lib_file="${1}"
 
        case "${system_name}" in
-               'linux'|'freebsd')
-                       echo "${lib_file}" \
-                       | cut -f2 -d'/'
+               'linux')
+                       echo 'usr'
+                       ;;
+               'freebsd'|'macos')
+                       echo 'usr/local'
                        ;;
                'windows')
                        basename "${lib_file}" \
                        | xargs -n1 -P1 which \
                        | cut -f2 -d'/'
                        ;;
-               'macos')
-                       echo 'usr/local'
        esac
 }