aboutsummaryrefslogtreecommitdiffstats
path: root/admin/nt
diff options
context:
space:
mode:
authorPhillip Lord2021-01-14 22:51:13 +0000
committerPhillip Lord2021-01-15 21:37:25 +0000
commit667f2e097cdfdb057de0696867c83ebfd1a3e816 (patch)
treed42ea850271e901cb61034efa1f276ef5b848b4e /admin/nt
parentf95c1b32300fbdef7b8e2b36b330a1d81db949ed (diff)
downloademacs-667f2e097cdfdb057de0696867c83ebfd1a3e816.tar.gz
emacs-667f2e097cdfdb057de0696867c83ebfd1a3e816.zip
Remove support for 32 bit build
* admin/nt/dist-build/README-scripts: Update * admin/nt/dist-build/README-windows-binaries: Update * admin/nt/dist-build/build-zips.sh: Remove 32 bit and fix paths * admin/nt/dist-build/build-dep-zips.py: Remove 32 bit and update paths * admin/nt/dist-build/emacs.nsi: Remove 32 bit and fix paths
Diffstat (limited to 'admin/nt')
-rw-r--r--admin/nt/dist-build/README-scripts38
-rw-r--r--admin/nt/dist-build/README-windows-binaries49
-rwxr-xr-xadmin/nt/dist-build/build-dep-zips.py100
-rwxr-xr-xadmin/nt/dist-build/build-zips.sh84
-rw-r--r--admin/nt/dist-build/emacs.nsi31
5 files changed, 103 insertions, 199 deletions
diff --git a/admin/nt/dist-build/README-scripts b/admin/nt/dist-build/README-scripts
index 4c3554e8df5..f27bcd3bd66 100644
--- a/admin/nt/dist-build/README-scripts
+++ b/admin/nt/dist-build/README-scripts
@@ -33,26 +33,21 @@ build-zips.sh file will create this for you.
33A location for the dependencies. This needs to contain two zip files 33A location for the dependencies. This needs to contain two zip files
34with the dependencies. build-dep-zips.py will create these files for you. 34with the dependencies. build-dep-zips.py will create these files for you.
35 35
36~/emacs-build/deps/libXpm/i686 36~/emacs-build/deps/libXpm
37~/emacs-build/deps/libXpm/x86_64
38 37
39Contain libXpm-noX4.dll. This file is used to load images for the 38Contain libXpm-noX4.dll. This file is used to load images for the
40splash screen, menu items and so on. Emacs runs without it, but looks 39splash screen, menu items and so on. Emacs runs without it, but looks
41horrible. The x86_64 comes from msys2, while the i686 comes from 40horrible. The files came original from msys2, and contains no
42ezwinports because it itself has no dependencies. These have to be 41dependencies. It has to be placed manually (but probably never
43placed manually (but probably never need updating). 42need updating).
44 43
45 44~/emacs-build/build/$version
46~/emacs-build/build/$version/i686
47~/emacs-build/build/$version/x86_64
48 45
49We build Emacs out-of-source here. This directory is created by 46We build Emacs out-of-source here. This directory is created by
50build-zips.sh. This directory can be freely deleted after zips have 47build-zips.sh. This directory can be freely deleted after zips have
51been created 48been created
52 49
53 50~/emacs-build/install/$version
54~/emacs-build/install/$version/i686
55~/emacs-build/install/$version/x86_64
56 51
57We install Emacs here. This directory is created by build-zips.sh. 52We install Emacs here. This directory is created by build-zips.sh.
58This directory can and *should* be deleted after zips have been 53This directory can and *should* be deleted after zips have been
@@ -79,9 +74,9 @@ To do this:
79 74
80Update msys to the latest version with `pacman -Syu`. 75Update msys to the latest version with `pacman -Syu`.
81 76
82Then run build-dep-zips.py, in the ~/emacs-build/deps directory. Three 77Then run build-dep-zips.py, in the ~/emacs-build/deps directory. Two
83zips will be created, containing the 64bit and 32bit dependencies, as 78zips will be created, containing the dependencies, as well as the
84well as the source for these. 79source for these.
85 80
86For emacs release or pre-test version: 81For emacs release or pre-test version:
87 82
@@ -105,12 +100,12 @@ To do this:
105 100
106Update msys to the latest version with `pacman -Syu`. 101Update msys to the latest version with `pacman -Syu`.
107 102
108Then run build-dep-zips.py, in ~/emacs-build/deps directory. Three 103Then run build-dep-zips.py, in ~/emacs-build/deps directory. Two zips
109zips will be created, containing the 64bit and 32bit dependencies, as 104will be created, containing the dependencies, as well as the source
110well as the source for these. These deps files contain the date of 105for these. These deps files contain the date of creation in their
111creation in their name. The deps file can be reused as desired, or a 106name. The deps file can be reused as desired, or a new version
112new version created. Where multiple deps files exist, the most 107created. Where multiple deps files exist, the most recent will be
113recent will be used. 108used.
114 109
115Now, run `build-zips.sh -s` to build a snapshot release. 110Now, run `build-zips.sh -s` to build a snapshot release.
116 111
@@ -134,4 +129,5 @@ For snapshots from another branch
134Snapshots can be build from any other branch. There is rarely a need 129Snapshots can be build from any other branch. There is rarely a need
135to do this, except where some significant, wide-ranging feature is 130to do this, except where some significant, wide-ranging feature is
136being added on a feature branch. In this case, the branch can be 131being added on a feature branch. In this case, the branch can be
137given using `build-zips.sh -b pdumper -s` for example. 132given using `build-zips.sh -b pdumper -s` for example. Any "/"
133characters in the branch title are replaced.
diff --git a/admin/nt/dist-build/README-windows-binaries b/admin/nt/dist-build/README-windows-binaries
index 001bdd73f7b..b6f6e55d8c6 100644
--- a/admin/nt/dist-build/README-windows-binaries
+++ b/admin/nt/dist-build/README-windows-binaries
@@ -4,7 +4,7 @@ See the end of the file for license conditions.
4 Precompiled Distributions of 4 Precompiled Distributions of
5 Emacs for Windows 5 Emacs for Windows
6 6
7 Jan 1, 2020 7 Jan 14, 2021
8 8
9 This directory contains precompiled distributions for GNU Emacs on 9 This directory contains precompiled distributions for GNU Emacs on
10 Windows 10 Windows
@@ -25,51 +25,33 @@ old binaries.
25Windows Binaries 25Windows Binaries
26================ 26================
27 27
28Currently, we provide six different binary packages for Emacs, which 28Currently, we provide three different binary packages for Emacs, which
29are: 29are:
30 30
31emacs-$VERSION-x86_64-installer.exe 31emacs-$VERSION-installer.exe
32 32
33Contains a 64-bit build of Emacs with dependencies as an installer 33Contains Emacs with dependencies as an installer
34package. Mostly, this is the best one to install. 34package. Mostly, this is the best one to install.
35 35
36emacs-$VERSION-x86_64.zip 36emacs-$VERSION.zip
37 37
38Contains a 64-bit build of Emacs with dependencies. This contains the 38Contains Emacs with dependencies. This contains the same files as the
39same files as the installer but as a zip file which some users may 39installer but as a zip file which some users may prefer.
40prefer.
41 40
42emacs-$VERSION-x86_64-no-deps.zip 41emacs-$VERSION-no-deps.zip
43 42
44Contains a 64-bit build of Emacs without any dependencies. This may be 43Contains Emacs without any dependencies. This may be useful if you
45useful if you wish to install where the dependencies are already 44wish to install where the dependencies are already available, or if
46available, or if you want the small possible Emacs. 45you want the small possible Emacs.
47
48emacs-$VERSION-i686-installer.exe
49
50Contains a 32-bit build of Emacs with dependencies as an installer
51package. This is useful for running on a 32-bit machine.
52
53emacs-$VERSION-i686.zip
54
55Contains a 32-bit build of Emacs with dependencies.
56
57emacs-$VERSION-i686-no-deps.zip
58
59Contains a 32-bit build of Emacs without dependencies
60 46
61In addition, we provide the following files which will not be useful 47In addition, we provide the following files which will not be useful
62for most end-users. 48for most end-users.
63 49
64emacs-$VERSION-x86_64-deps.zip 50emacs-$VERSION-deps.zip
65 51
66The dependencies. Unzipping this file on top of 52The dependencies. Unzipping this file on top of
67emacs-$VERSION-x86_64-no-deps.zip should result in the same install as 53emacs-$VERSION-no-deps.zip should result in the same install as
68emacs-$VERSION-x86_64.zip. 54emacs-$VERSION.zip.
69
70emacs-$VERSION-i686-deps.zip
71
72The 32-bit version of the dependencies.
73 55
74emacs-$VERSION-deps-mingw-w64-src.zip 56emacs-$VERSION-deps-mingw-w64-src.zip
75 57
@@ -85,7 +67,8 @@ Snapshots
85 67
86We also distribute "snapshots" of Emacs built at points throughout the 68We also distribute "snapshots" of Emacs built at points throughout the
87development cycle, for those interested in following this cycle. They 69development cycle, for those interested in following this cycle. They
88are not recommended for normal users. 70are not recommended for normal users; however, they are useful for
71people who want to report bugs against the current master.
89 72
90The files follow the same naming convention, but also include a date 73The files follow the same naming convention, but also include a date
91(and sometimes information about their branch). The Emacs source at 74(and sometimes information about their branch). The Emacs source at
diff --git a/admin/nt/dist-build/build-dep-zips.py b/admin/nt/dist-build/build-dep-zips.py
index ec99bd606d8..19168e7ff25 100755
--- a/admin/nt/dist-build/build-dep-zips.py
+++ b/admin/nt/dist-build/build-dep-zips.py
@@ -17,7 +17,6 @@
17## You should have received a copy of the GNU General Public License 17## You should have received a copy of the GNU General Public License
18## along with GNU Emacs. If not, see <https://www.gnu.org/licenses/>. 18## along with GNU Emacs. If not, see <https://www.gnu.org/licenses/>.
19import argparse 19import argparse
20import multiprocessing as mp
21import os 20import os
22import shutil 21import shutil
23import re 22import re
@@ -64,31 +63,30 @@ def check_output_maybe(*args,**kwargs):
64 return check_output(*args,**kwargs) 63 return check_output(*args,**kwargs)
65 64
66## DLL Capture 65## DLL Capture
67def gather_deps(arch, directory): 66def gather_deps():
68 os.mkdir(arch)
69 os.chdir(arch)
70 67
71 for dep in full_dll_dependency(directory): 68 os.mkdir("x86_64")
72 check_output_maybe(["cp /{}/bin/{}*.dll .".format(directory, dep)], 69 os.chdir("x86_64")
70
71 for dep in full_dll_dependency():
72 check_output_maybe(["cp /mingw64/bin/{}*.dll .".format(dep)],
73 shell=True) 73 shell=True)
74 74
75 ## And package them up 75 print("Zipping")
76 ## os.chdir(arch) 76 check_output_maybe("zip -9r ../emacs-{}-{}deps.zip *"
77 print("Zipping: {}".format(arch)) 77 .format(EMACS_MAJOR_VERSION, DATE),
78 check_output_maybe("zip -9r ../emacs-{}-{}{}-deps.zip *"
79 .format(EMACS_MAJOR_VERSION, DATE, arch),
80 shell=True) 78 shell=True)
81 os.chdir("../") 79 os.chdir("../")
82 80
83## Return all Emacs dependencies 81## Return all Emacs dependencies
84def full_dll_dependency(directory): 82def full_dll_dependency():
85 deps = [dll_dependency(dep, directory) for dep in DLL_REQ] 83 deps = [dll_dependency(dep) for dep in DLL_REQ]
86 return set(sum(deps, []) + DLL_REQ) 84 return set(sum(deps, []) + DLL_REQ)
87 85
88## Dependencies for a given DLL 86## Dependencies for a given DLL
89def dll_dependency(dll, directory): 87def dll_dependency(dll):
90 output = check_output(["/mingw64/bin/ntldd", "--recursive", 88 output = check_output(["/mingw64/bin/ntldd", "--recursive",
91 "/{}/bin/{}*.dll".format(directory, dll)]).decode("utf-8") 89 "/mingw64/bin/{}*.dll".format(dll)]).decode("utf-8")
92 ## munge output 90 ## munge output
93 return ntldd_munge(output) 91 return ntldd_munge(output)
94 92
@@ -114,14 +112,11 @@ def ntldd_munge(out):
114## Packages to fiddle with 112## Packages to fiddle with
115## Source for gcc-libs is part of gcc 113## Source for gcc-libs is part of gcc
116SKIP_SRC_PKGS=["mingw-w64-gcc-libs"] 114SKIP_SRC_PKGS=["mingw-w64-gcc-libs"]
117SKIP_DEP_PKGS=["mingw-w64-x86_64-glib2"] 115SKIP_DEP_PKGS=["mingw-w64-glib2"]
118MUNGE_SRC_PKGS={"mingw-w64-libwinpthread-git":"mingw-w64-winpthreads-git"} 116MUNGE_SRC_PKGS={"mingw-w64-libwinpthread-git":"mingw-w64-winpthreads-git"}
119MUNGE_DEP_PKGS={ 117MUNGE_DEP_PKGS={
120 "mingw-w64-i686-libwinpthread":"mingw-w64-i686-libwinpthread-git",
121 "mingw-w64-x86_64-libwinpthread":"mingw-w64-x86_64-libwinpthread-git", 118 "mingw-w64-x86_64-libwinpthread":"mingw-w64-x86_64-libwinpthread-git",
122
123 "mingw-w64-x86_64-libtre": "mingw-w64-x86_64-libtre-git", 119 "mingw-w64-x86_64-libtre": "mingw-w64-x86_64-libtre-git",
124 "mingw-w64-i686-libtre": "mingw-w64-i686-libtre-git"
125} 120}
126 121
127## Currently no packages seem to require this! 122## Currently no packages seem to require this!
@@ -155,13 +150,11 @@ def extract_deps():
155 150
156 # Get a list of all dependencies needed for packages mentioned above. 151 # Get a list of all dependencies needed for packages mentioned above.
157 pkgs = PKG_REQ[:] 152 pkgs = PKG_REQ[:]
158 print("Initial pkgs", pkgs)
159 n = 0 153 n = 0
160 while n < len(pkgs): 154 while n < len(pkgs):
161 subdeps = immediate_deps(pkgs[n]) 155 subdeps = immediate_deps(pkgs[n])
162 for p in subdeps: 156 for p in subdeps:
163 if not (p in pkgs or p in SKIP_DEP_PKGS): 157 if not (p in pkgs or p in SKIP_DEP_PKGS):
164 print("adding", p)
165 pkgs.append(p) 158 pkgs.append(p)
166 n = n + 1 159 n = n + 1
167 160
@@ -171,33 +164,29 @@ def extract_deps():
171def download_source(tarball): 164def download_source(tarball):
172 print("Acquiring {}...".format(tarball)) 165 print("Acquiring {}...".format(tarball))
173 166
174 if os.path.exists("../emacs-src-cache/{}".format(tarball)): 167 if not os.path.exists("../emacs-src-cache/{}".format(tarball)):
175 print("Copying {} from local".format(tarball))
176 shutil.copyfile("../emacs-src-cache/{}".format(tarball),
177 "{}".format(tarball))
178 else:
179 print("Downloading {}...".format(tarball)) 168 print("Downloading {}...".format(tarball))
180 check_output_maybe( 169 check_output_maybe(
181 "wget -a ../download.log -O {} {}/{}/download" 170 "wget -a ../download.log -O ../emacs-src-cache/{} {}/{}/download"
182 .format(tarball, SRC_REPO, tarball), 171 .format(tarball, SRC_REPO, tarball),
183 shell=True 172 shell=True
184 ) 173 )
185 print("Downloading {}... done".format(tarball)) 174 print("Downloading {}... done".format(tarball))
186 175
176 print("Copying {} from local".format(tarball))
177 shutil.copyfile("../emacs-src-cache/{}".format(tarball),
178 "{}".format(tarball))
179
180
187## Fetch all the source code 181## Fetch all the source code
188def gather_source(deps): 182def gather_source(deps):
189 183
184 if not os.path.exists("emacs-src-cache"):
185 os.mkdir("emacs-src-cache")
190 186
191 ## Source for gcc-libs is part of gcc
192 ## Source for libwinpthread is in libwinpthreads
193 ## mpc, termcap, xpm -- has x86_64, and i686 versions
194
195 ## This needs to have been run first at the same time as the
196 ## system was updated.
197 os.mkdir("emacs-src") 187 os.mkdir("emacs-src")
198 os.chdir("emacs-src") 188 os.chdir("emacs-src")
199 189
200 to_download = []
201 for pkg in deps: 190 for pkg in deps:
202 pkg_name_and_version= \ 191 pkg_name_and_version= \
203 check_output(["pacman","-Q", pkg]).decode("utf-8").strip() 192 check_output(["pacman","-Q", pkg]).decode("utf-8").strip()
@@ -208,31 +197,18 @@ def gather_source(deps):
208 pkg_name=pkg_name_components[0] 197 pkg_name=pkg_name_components[0]
209 pkg_version=pkg_name_components[1] 198 pkg_version=pkg_name_components[1]
210 199
211 ## make a simple name to make lookup easier 200 ## source pkgs don't have an architecture in them
212 simple_pkg_name = re.sub(r"x86_64-","",pkg_name) 201 pkg_name = re.sub(r"x86_64-","",pkg_name)
213 202
214 if(simple_pkg_name in SKIP_SRC_PKGS): 203 if(pkg_name in SKIP_SRC_PKGS):
215 continue 204 continue
216 205
217 ## Some packages have different source files for different 206 ## Switch names if necessary
218 ## architectures. For these we need two downloads. 207 pkg_name = MUNGE_SRC_PKGS.get(pkg_name,pkg_name)
219 if(simple_pkg_name in ARCH_PKGS):
220 downloads = [pkg_name,
221 re.sub(r"x86_64","i686",pkg_name)]
222 else:
223 downloads = [simple_pkg_name]
224 208
225 for d in downloads: 209 tarball = "{}-{}.src.tar.gz".format(pkg_name,pkg_version)
226 ## Switch names if necessary
227 d = MUNGE_SRC_PKGS.get(d,d)
228 210
229 tarball = "{}-{}.src.tar.gz".format(d,pkg_version) 211 download_source(tarball)
230
231 to_download.append(tarball)
232
233 ## Download in parallel or it is just too slow
234 p = mp.Pool(1)
235 p.map(download_source,to_download)
236 212
237 print("Zipping") 213 print("Zipping")
238 check_output_maybe("zip -9 ../emacs-{}-{}deps-mingw-w64-src.zip *" 214 check_output_maybe("zip -9 ../emacs-{}-{}deps-mingw-w64-src.zip *"
@@ -245,7 +221,6 @@ def gather_source(deps):
245def clean(): 221def clean():
246 print("Cleaning") 222 print("Cleaning")
247 os.path.isdir("emacs-src") and shutil.rmtree("emacs-src") 223 os.path.isdir("emacs-src") and shutil.rmtree("emacs-src")
248 os.path.isdir("i686") and shutil.rmtree("i686")
249 os.path.isdir("x86_64") and shutil.rmtree("x86_64") 224 os.path.isdir("x86_64") and shutil.rmtree("x86_64")
250 os.path.isfile("download.log") and os.remove("download.log") 225 os.path.isfile("download.log") and os.remove("download.log")
251 226
@@ -259,12 +234,6 @@ parser = argparse.ArgumentParser()
259parser.add_argument("-s", help="snapshot build", 234parser.add_argument("-s", help="snapshot build",
260 action="store_true") 235 action="store_true")
261 236
262parser.add_argument("-t", help="32 bit deps only",
263 action="store_true")
264
265parser.add_argument("-f", help="64 bit deps only",
266 action="store_true")
267
268parser.add_argument("-r", help="source code only", 237parser.add_argument("-r", help="source code only",
269 action="store_true") 238 action="store_true")
270 239
@@ -278,7 +247,7 @@ parser.add_argument("-l", help="list dependencies only",
278 action="store_true") 247 action="store_true")
279 248
280args = parser.parse_args() 249args = parser.parse_args()
281do_all=not (args.c or args.r or args.f or args.t) 250do_all=not (args.c or args.r)
282 251
283 252
284 253
@@ -294,11 +263,8 @@ if args.s:
294else: 263else:
295 DATE="" 264 DATE=""
296 265
297if( do_all or args.t ): 266if( do_all):
298 gather_deps("i686","mingw32") 267 gather_deps()
299
300if( do_all or args.f ):
301 gather_deps("x86_64","mingw64")
302 268
303if( do_all or args.r ): 269if( do_all or args.r ):
304 deps=extract_deps() 270 deps=extract_deps()
diff --git a/admin/nt/dist-build/build-zips.sh b/admin/nt/dist-build/build-zips.sh
index fbb98895384..7bc6ea6a9e5 100755
--- a/admin/nt/dist-build/build-zips.sh
+++ b/admin/nt/dist-build/build-zips.sh
@@ -29,70 +29,62 @@ function git_up {
29} 29}
30 30
31function build_zip { 31function build_zip {
32 32 echo [build] Building Emacs-$VERSION
33 ARCH=$1
34 PKG=$2
35 HOST=$3
36
37 echo [build] Building Emacs-$VERSION for $ARCH
38 if [ $ARCH == "i686" ]
39 then
40 PATH=/mingw32/bin:$PATH
41 MSYSTEM=MINGW32
42 fi
43 33
44 ## Clean the install location because we use it twice 34 ## Clean the install location because we use it twice
45 rm -rf $HOME/emacs-build/install/emacs-$VERSION/$ARCH 35 rm -rf $HOME/emacs-build/install/emacs-$VERSION
46 mkdir --parents $HOME/emacs-build/build/emacs-$VERSION/$ARCH 36 mkdir --parents $HOME/emacs-build/build/emacs-$VERSION
47 cd $HOME/emacs-build/build/emacs-$VERSION/$ARCH 37 cd $HOME/emacs-build/build/emacs-$VERSION
38
39 ## Do we need this or is it the default?
40 export PKG_CONFIG_PATH=/mingw64/lib/pkgconfig
48 41
49 export PKG_CONFIG_PATH=$PKG
50 42
51 ## Running configure forces a rebuild of the C core which takes 43 ## Running configure forces a rebuild of the C core which takes
52 ## time that is not always needed, so do not do it unless we have 44 ## time that is not always needed, so do not do it unless we have
53 ## to. 45 ## to.
54 if [ ! -f Makefile ] || (($CONFIG)) 46 if [ ! -f Makefile ] || (($CONFIG))
55 then 47 then
56 echo [build] Configuring Emacs $ARCH 48 echo [build] Configuring Emacs
57 $REPO_DIR/$BRANCH/configure \ 49 $REPO_DIR/$BRANCH/configure \
58 --without-dbus \ 50 --without-dbus \
59 --host=$HOST --without-compress-install \ 51 --without-compress-install \
60 $CACHE \ 52 $CACHE \
61 CFLAGS="$CFLAGS" 53 CFLAGS="$CFLAGS"
62 fi 54 fi
63 55
64 make -j 4 $INSTALL_TARGET \ 56 make -j 4 $INSTALL_TARGET \
65 prefix=$HOME/emacs-build/install/emacs-$VERSION/$ARCH 57 prefix=$HOME/emacs-build/install/emacs-$VERSION
66 cd $HOME/emacs-build/install/emacs-$VERSION/$ARCH 58 cd $HOME/emacs-build/install/emacs-$VERSION
67 zip -r -9 emacs-$OF_VERSION-$ARCH-no-deps.zip * 59 zip -r -9 emacs-$OF_VERSION-no-deps.zip *
68 mv emacs-$OF_VERSION-$ARCH-no-deps.zip $HOME/emacs-upload 60 mv emacs-$OF_VERSION-no-deps.zip $HOME/emacs-upload
69 61
70 if [ -z $SNAPSHOT ]; 62 if [ -z $SNAPSHOT ];
71 then 63 then
72 DEPS_FILE=$HOME/emacs-build/deps/emacs-$MAJOR_VERSION-$ARCH-deps.zip 64 DEPS_FILE=$HOME/emacs-build/deps/emacs-$MAJOR_VERSION-deps.zip
73 else 65 else
74 ## Pick the most recent snapshot whatever that is 66 ## Pick the most recent snapshot whatever that is
75 DEPS_FILE=`ls $HOME/emacs-build/deps/emacs-$MAJOR_VERSION-*-$ARCH-deps.zip | tail -n 1` 67 DEPS_FILE=`ls $HOME/emacs-build/deps/emacs-$MAJOR_VERSION-*-deps.zip | tail -n 1`
76 fi 68 fi
77 69
78 echo [build] Using $DEPS_FILE 70 echo [build] Using $DEPS_FILE
79 unzip -d bin $DEPS_FILE 71 unzip -d bin $DEPS_FILE
80 72
81 zip -r -9 emacs-$OF_VERSION-$ARCH.zip * 73 zip -r -9 emacs-$OF_VERSION.zip *
82 mv emacs-$OF_VERSION-$ARCH.zip ~/emacs-upload 74 mv emacs-$OF_VERSION.zip ~/emacs-upload
83} 75}
84 76
85function build_installer { 77function build_installer {
86 ARCH=$1 78 cd $HOME/emacs-build/install/
87 cd $HOME/emacs-build/install/emacs-$VERSION
88 echo [build] Calling makensis in `pwd` 79 echo [build] Calling makensis in `pwd`
89 cp $REPO_DIR/$BRANCH/admin/nt/dist-build/emacs.nsi . 80 cp $REPO_DIR/$BRANCH/admin/nt/dist-build/emacs.nsi .
90 81
91 makensis -v4 \ 82 makensis -v4 \
92 -DARCH=$ARCH -DEMACS_VERSION=$ACTUAL_VERSION \ 83 -DEMACS_VERSION=$ACTUAL_VERSION \
84 -DVERSION_BRANCH=$VERSION \
93 -DOUT_VERSION=$OF_VERSION emacs.nsi 85 -DOUT_VERSION=$OF_VERSION emacs.nsi
94 rm emacs.nsi 86 rm emacs.nsi
95 mv emacs-$OF_VERSION-$ARCH-installer.exe ~/emacs-upload 87 mv emacs-$OF_VERSION-installer.exe ~/emacs-upload
96} 88}
97 89
98set -o errexit 90set -o errexit
@@ -101,7 +93,6 @@ SNAPSHOT=
101CACHE= 93CACHE=
102 94
103BUILD=1 95BUILD=1
104BUILD_32=1
105BUILD_64=1 96BUILD_64=1
106GIT_UP=0 97GIT_UP=0
107CONFIG=1 98CONFIG=1
@@ -112,19 +103,8 @@ INSTALL_TARGET="install-strip"
112REPO_DIR=$HOME/emacs-build/git/ 103REPO_DIR=$HOME/emacs-build/git/
113 104
114 105
115while getopts "36gb:hnsiV:" opt; do 106while getopts "gb:hnsiV:" opt; do
116 case $opt in 107 case $opt in
117 3)
118 BUILD_32=1
119 BUILD_64=0
120 GIT_UP=0
121 ;;
122 6)
123 BUILD_32=0
124 BUILD_64=1
125 GIT_UP=0
126 ;;
127
128 g) 108 g)
129 BUILD_32=0 109 BUILD_32=0
130 BUILD_64=0 110 BUILD_64=0
@@ -150,10 +130,11 @@ while getopts "36gb:hnsiV:" opt; do
150 ;; 130 ;;
151 h) 131 h)
152 echo "build-zips.sh" 132 echo "build-zips.sh"
153 echo " -3 32 bit build only" 133 echo " -b args -- build args branch"
154 echo " -6 64 bit build only"
155 echo " -g git update and worktree only" 134 echo " -g git update and worktree only"
156 echo " -i build installer only" 135 echo " -i build installer only"
136 echo " -n do not configure"
137 echo " -s snaphot build"
157 exit 0 138 exit 0
158 ;; 139 ;;
159 \?) 140 \?)
@@ -223,18 +204,7 @@ if (($BUILD_64))
223then 204then
224 if (($BUILD)) 205 if (($BUILD))
225 then 206 then
226 build_zip x86_64 /mingw64/lib/pkgconfig x86_64-w64-mingw32 207 build_zip
227 fi
228 build_installer x86_64
229fi
230
231## Do the 64 bit build first, because we reset some environment
232## variables during the 32 bit which will break the build.
233if (($BUILD_32))
234then
235 if (($BUILD))
236 then
237 build_zip i686 /mingw32/lib/pkgconfig i686-w64-mingw32
238 fi 208 fi
239 build_installer i686 209 build_installer
240fi 210fi
diff --git a/admin/nt/dist-build/emacs.nsi b/admin/nt/dist-build/emacs.nsi
index dce8f3db4a3..557bb106dde 100644
--- a/admin/nt/dist-build/emacs.nsi
+++ b/admin/nt/dist-build/emacs.nsi
@@ -2,7 +2,7 @@
2!include LogicLib.nsh 2!include LogicLib.nsh
3!include x64.nsh 3!include x64.nsh
4 4
5Outfile "emacs-${OUT_VERSION}-${ARCH}-installer.exe" 5Outfile "emacs-${OUT_VERSION}-installer.exe"
6 6
7 7
8SetCompressor /solid lzma 8SetCompressor /solid lzma
@@ -14,15 +14,15 @@ Var StartMenuFolder
14!define MUI_WELCOMEPAGE_TITLE_3LINES 14!define MUI_WELCOMEPAGE_TITLE_3LINES
15!define MUI_WELCOMEPAGE_TEXT "Welcome to Emacs -- the editor of a lifetime." 15!define MUI_WELCOMEPAGE_TEXT "Welcome to Emacs -- the editor of a lifetime."
16 16
17!define MUI_WELCOMEFINISHPAGE_BITMAP "${ARCH}\share\emacs\${EMACS_VERSION}\etc\images\splash.bmp" 17!define MUI_WELCOMEFINISHPAGE_BITMAP "emacs-${VERSION_BRANCH}\share\emacs\${EMACS_VERSION}\etc\images\splash.bmp"
18!define MUI_ICON "${ARCH}\share\emacs\${EMACS_VERSION}\etc\images\icons\hicolor\scalable\apps\emacs.ico" 18!define MUI_ICON "emacs-${VERSION_BRANCH}\share\emacs\${EMACS_VERSION}\etc\images\icons\hicolor\scalable\apps\emacs.ico"
19!define MUI_UNICON "${ARCH}\share\emacs\${EMACS_VERSION}\etc\images\icons\hicolor\scalable\apps\emacs.ico" 19!define MUI_UNICON "emacs-${VERSION_BRANCH}\share\emacs\${EMACS_VERSION}\etc\images\icons\hicolor\scalable\apps\emacs.ico"
20 20
21!insertmacro MUI_PAGE_WELCOME 21!insertmacro MUI_PAGE_WELCOME
22 22
23 23
24!define MUI_LICENSEPAGE_TEXT_TOP "The GNU General Public License" 24!define MUI_LICENSEPAGE_TEXT_TOP "The GNU General Public License"
25!insertmacro MUI_PAGE_LICENSE "${ARCH}\share\emacs\${EMACS_VERSION}\lisp\COPYING" 25!insertmacro MUI_PAGE_LICENSE "emacs-${VERSION_BRANCH}\share\emacs\${EMACS_VERSION}\lisp\COPYING"
26 26
27!insertmacro MUI_PAGE_DIRECTORY 27!insertmacro MUI_PAGE_DIRECTORY
28!insertmacro MUI_PAGE_INSTFILES 28!insertmacro MUI_PAGE_INSTFILES
@@ -36,19 +36,7 @@ Var StartMenuFolder
36Name Emacs-${EMACS_VERSION} 36Name Emacs-${EMACS_VERSION}
37 37
38function .onInit 38function .onInit
39 ${If} ${RunningX64} 39 StrCpy $INSTDIR "$PROGRAMFILES64\Emacs"
40 ${If} ${ARCH} == "x86_64"
41 StrCpy $INSTDIR "$PROGRAMFILES64\Emacs"
42 ${Else}
43 StrCpy $INSTDIR "$PROGRAMFILES32\Emacs"
44 ${Endif}
45 ${Else}
46 ${If} ${ARCH} == "x86_64"
47 Quit
48 ${Else}
49 StrCpy $INSTDIR "$PROGRAMFILES\Emacs"
50 ${Endif}
51 ${EndIf}
52functionend 40functionend
53 41
54 42
@@ -56,7 +44,8 @@ Section
56 44
57 SetOutPath $INSTDIR 45 SetOutPath $INSTDIR
58 46
59 File /r ${ARCH} 47 File /r emacs-${VERSION_BRANCH}
48
60 # define uninstaller name 49 # define uninstaller name
61 WriteUninstaller $INSTDIR\Uninstall.exe 50 WriteUninstaller $INSTDIR\Uninstall.exe
62 51
@@ -66,7 +55,7 @@ Section
66 CreateShortcut "$SMPROGRAMS\$StartMenuFolder\Uninstall.lnk" "$INSTDIR\Uninstall.exe" 55 CreateShortcut "$SMPROGRAMS\$StartMenuFolder\Uninstall.lnk" "$INSTDIR\Uninstall.exe"
67 56
68 !insertmacro MUI_STARTMENU_WRITE_END 57 !insertmacro MUI_STARTMENU_WRITE_END
69 CreateShortCut "$SMPROGRAMS\$StartMenuFolder\Emacs.lnk" "$INSTDIR\${ARCH}\bin\runemacs.exe" 58 CreateShortCut "$SMPROGRAMS\$StartMenuFolder\Emacs.lnk" "$INSTDIR\emacs-${VERSION_BRANCH}\bin\runemacs.exe"
70SectionEnd 59SectionEnd
71 60
72 61
@@ -78,7 +67,7 @@ Section "Uninstall"
78 Delete "$INSTDIR\Uninstall.exe" 67 Delete "$INSTDIR\Uninstall.exe"
79 68
80 # now delete installed directory 69 # now delete installed directory
81 RMDir /r "$INSTDIR\${ARCH}" 70 RMDir /r "$INSTDIR"
82 RMDir "$INSTDIR" 71 RMDir "$INSTDIR"
83 72
84 !insertmacro MUI_STARTMENU_GETFOLDER Application $StartMenuFolder 73 !insertmacro MUI_STARTMENU_GETFOLDER Application $StartMenuFolder