Mercurial > minori
comparison scripts/win32/deploy_build.sh @ 343:1faa72660932
*: transfer back to cmake from autotools
autotools just made lots of things more complicated than
they should have and many things broke (i.e. translations)
author | Paper <paper@paper.us.eu.org> |
---|---|
date | Thu, 20 Jun 2024 05:56:06 -0400 |
parents | 8eb0cfe59992 |
children |
comparison
equal
deleted
inserted
replaced
342:adb79bdde329 | 343:1faa72660932 |
---|---|
15 | 15 |
16 GetNeededLibraries() { | 16 GetNeededLibraries() { |
17 # do not run this on untrusted executables. | 17 # do not run this on untrusted executables. |
18 # see: ldd(1) | 18 # see: ldd(1) |
19 system="$(echo "$MSYSTEM" | tr "[:upper:]" "[:lower:]")" | 19 system="$(echo "$MSYSTEM" | tr "[:upper:]" "[:lower:]")" |
20 "$LDD" --output-format ldd-like --dll-lookup-dirs "/$system/bin" -- "$1" | while IFS="" read -r dependency; do | 20 "$LDD" --output-format ldd-like --dll-lookup-dirs "/$system/bin" "$PWD" -- "$1" | while IFS="" read -r dependency; do |
21 # trim whitespace, then get the value; mingw-ldd's "ldd-like" output doesn't use tabs like regular ldd | 21 # trim whitespace, then get the value; mingw-ldd's "ldd-like" output doesn't use tabs like regular ldd |
22 lib="$(printf -- "%s" "$dependency" | sed -e 's/^[[:space:]]*//' -e 's/[[:space:]]*$//' | cut -d' ' -f3)" | 22 lib="$(printf -- "%s" "$dependency" | sed -e 's/^[[:space:]]*//' -e 's/[[:space:]]*$//' | cut -d' ' -f3)" |
23 case $lib in | 23 if test "x$lib" != "xnot"; then |
24 "/$system/"*) | 24 printf -- "$lib\n" |
25 printf -- "$lib\n" | 25 fi |
26 ;; | |
27 *) | |
28 ;; | |
29 esac | |
30 done | 26 done |
31 } | 27 } |
32 | 28 |
33 | 29 |
34 if test -d "$DIR"; then | 30 if test -d "$DIR"; then |
35 rm -r "$DIR" | 31 rm -r "$DIR" |
36 fi | 32 fi |
37 | 33 |
38 mkdir "$DIR" | 34 mkdir "$DIR" |
39 | 35 |
40 for lib in $(GetNeededLibraries ".libs/minori.exe"); do | 36 for lib in $(GetNeededLibraries "minori.exe"); do |
41 echo "copying '$lib' to $DIR" | 37 echo "copying '$lib' to $DIR" |
42 cp "$lib" "$DIR/" | 38 cp "$lib" "$DIR/" |
43 done | 39 done |
44 | 40 |
45 cp ".libs/minori.exe" "$DIR/" | 41 cp "minori.exe" "$DIR/" |
46 | 42 |
47 windeployqt "$DIR/minori.exe" | 43 windeployqt "$DIR/minori.exe" |
48 | 44 |
49 zip -r "$DIR.zip" "$DIR" | 45 zip -r "$DIR.zip" "$DIR" |