diff options
author | Ron Yorston <rmy@pobox.com> | 2023-07-27 12:20:18 +0100 |
---|---|---|
committer | Ron Yorston <rmy@pobox.com> | 2023-07-27 12:20:18 +0100 |
commit | 9e2c3594ccbd3ef45beab57cba6796f97f06906c (patch) | |
tree | 64f6b0aa7bcdfa8b18c374a701cb09f60564f1b2 /examples | |
parent | df560c7c017c1084a180d922922358ed600faeb5 (diff) | |
download | busybox-w32-9e2c3594ccbd3ef45beab57cba6796f97f06906c.tar.gz busybox-w32-9e2c3594ccbd3ef45beab57cba6796f97f06906c.tar.bz2 busybox-w32-9e2c3594ccbd3ef45beab57cba6796f97f06906c.zip |
win32: fail early if UTF8 isn't supported
When the UTF8 manifest is included in the binary and ACP isn't UTF8
fail at once. This avoids raising false hopes if the binary is run
on Window 7/8. On Windows XP it won't even run.
When the busybox applet is run without arguments always report the
build-time configuration of globbing and the UTF8 manifest.
Diffstat (limited to 'examples')
-rwxr-xr-x | examples/mswin-build/mkprerelease | 16 | ||||
-rwxr-xr-x | examples/mswin-build/mkrelease | 34 |
2 files changed, 30 insertions, 20 deletions
diff --git a/examples/mswin-build/mkprerelease b/examples/mswin-build/mkprerelease index 45f64fa72..1cace46a3 100755 --- a/examples/mswin-build/mkprerelease +++ b/examples/mswin-build/mkprerelease | |||
@@ -29,13 +29,13 @@ for i in $TARGETS | |||
29 | do | 29 | do |
30 | if [ $i = "build_pre_64" ] | 30 | if [ $i = "build_pre_64" ] |
31 | then | 31 | then |
32 | CONFIG=mingw64_defconfig; | 32 | CONFIG=mingw64_defconfig |
33 | elif [ $i = "build_pre_64u" ] | 33 | elif [ $i = "build_pre_64u" ] |
34 | then | 34 | then |
35 | CONFIG=mingw64u_defconfig; | 35 | CONFIG=mingw64u_defconfig |
36 | elif [ $i = "build_pre_32" ] | 36 | elif [ $i = "build_pre_32" ] |
37 | then | 37 | then |
38 | CONFIG=mingw32_defconfig; | 38 | CONFIG=mingw32_defconfig |
39 | fi | 39 | fi |
40 | 40 | ||
41 | (cd $i; git checkout master; make ${CONFIG}) | 41 | (cd $i; git checkout master; make ${CONFIG}) |
@@ -44,8 +44,16 @@ done | |||
44 | # perform build | 44 | # perform build |
45 | for i in $TARGETS | 45 | for i in $TARGETS |
46 | do | 46 | do |
47 | BITS=64 | ||
48 | if [ $i = "build_pre_32" ] | ||
49 | then | ||
50 | BITS=32; | ||
51 | fi | ||
52 | |||
47 | ( | 53 | ( |
48 | cd $i | 54 | cd $i |
49 | make -j $(nproc) EXTRAVERSION="-$(git describe --match=FRP | sed 's/FRP/PRE/')" | 55 | GCCV=$(rpm -q --qf '%{name} %{version}-%{release}\n' mingw${BITS}-gcc) |
56 | CRTV=$(rpm -q --qf '%{name} %{version}-%{release}\n' mingw${BITS}-crt) | ||
57 | make -j $(nproc) EXTRAVERSION="-$(git describe --match=FRP | sed 's/FRP/PRE/')" MINGW_VER="$GCCV; $CRTV" | ||
50 | ) | 58 | ) |
51 | done | 59 | done |
diff --git a/examples/mswin-build/mkrelease b/examples/mswin-build/mkrelease index 7ce9094f6..956cba0c1 100755 --- a/examples/mswin-build/mkrelease +++ b/examples/mswin-build/mkrelease | |||
@@ -2,7 +2,7 @@ | |||
2 | # | 2 | # |
3 | # Build 32- and 64-bit busybox binaries for release | 3 | # Build 32- and 64-bit busybox binaries for release |
4 | # | 4 | # |
5 | TARGETS="build_32 build_64" | 5 | TARGETS="build_32 build_64 build_64u" |
6 | 6 | ||
7 | if [ ! -d busybox-w32 ] | 7 | if [ ! -d busybox-w32 ] |
8 | then | 8 | then |
@@ -20,15 +20,23 @@ done | |||
20 | # apply default configuration | 20 | # apply default configuration |
21 | for i in $TARGETS | 21 | for i in $TARGETS |
22 | do | 22 | do |
23 | BITS=32 | ||
24 | if [ $i = "build_64" ] | 23 | if [ $i = "build_64" ] |
25 | then | 24 | then |
26 | BITS=64; | 25 | CONFIG=mingw64_defconfig |
26 | BITS=64 | ||
27 | elif [ $i = "build_64u" ] | ||
28 | then | ||
29 | CONFIG=mingw64u_defconfig | ||
30 | BITS=64 | ||
31 | elif [ $i = "build_32" ] | ||
32 | then | ||
33 | CONFIG=mingw32_defconfig | ||
34 | BITS=32 | ||
27 | fi | 35 | fi |
28 | 36 | ||
29 | ( | 37 | ( |
30 | cd $i | 38 | cd $i |
31 | make mingw${BITS}_defconfig | 39 | make ${CONFIG} |
32 | # link time optimisation, fortify, stack protection | 40 | # link time optimisation, fortify, stack protection |
33 | sed -e 's/^CONFIG_EXTRA_CFLAGS="\(.*\)"$/CONFIG_EXTRA_CFLAGS="\1 -flto -fstack-protector --param=ssp-buffer-size=4"/' \ | 41 | sed -e 's/^CONFIG_EXTRA_CFLAGS="\(.*\)"$/CONFIG_EXTRA_CFLAGS="\1 -flto -fstack-protector --param=ssp-buffer-size=4"/' \ |
34 | -e 's/^CONFIG_EXTRA_CFLAGS=" /CONFIG_EXTRA_CFLAGS="/' \ | 42 | -e 's/^CONFIG_EXTRA_CFLAGS=" /CONFIG_EXTRA_CFLAGS="/' \ |
@@ -49,22 +57,16 @@ done | |||
49 | # perform build | 57 | # perform build |
50 | for i in $TARGETS | 58 | for i in $TARGETS |
51 | do | 59 | do |
52 | BITS=32 | 60 | BITS=64 |
53 | if [ $i = "build_64" ] | 61 | if [ $i = "build_32" ] |
54 | then | 62 | then |
55 | BITS=64; | 63 | BITS=32 |
56 | fi | 64 | fi |
57 | 65 | ||
58 | ( | 66 | ( |
59 | cd $i | 67 | cd $i |
60 | GCCV=`rpm -q --qf '%{name} %{version}-%{release}\n' mingw${BITS}-gcc` | 68 | GCCV=$(rpm -q --qf '%{name} %{version}-%{release}\n' mingw${BITS}-gcc) |
61 | CRTV=`rpm -q --qf '%{name} %{version}-%{release}\n' mingw${BITS}-crt` | 69 | CRTV=$(rpm -q --qf '%{name} %{version}-%{release}\n' mingw${BITS}-crt) |
62 | GLOB="; noglob" | 70 | make -j $(nproc) EXTRAVERSION="-`git describe --match=FRP`" MINGW_VER="$GCCV; $CRTV" |
63 | if grep -q ^CONFIG_GLOBBING=y .config | ||
64 | then | ||
65 | GLOB="; glob" | ||
66 | fi | ||
67 | VER="($GCCV; $CRTV$GLOB)" | ||
68 | make -j $(nproc) EXTRAVERSION="-`git describe --match=FRP`" MINGW_VER="$VER" | ||
69 | ) | 71 | ) |
70 | done | 72 | done |