diff options
| author | Eli Zaretskii <eliz@gnu.org> | 2026-05-16 07:24:17 -0400 |
|---|---|---|
| committer | Eli Zaretskii <eliz@gnu.org> | 2026-05-16 07:24:17 -0400 |
| commit | 407b5ce7ab29ecb2e2c2150d1b4f8d4c1c51c92b (patch) | |
| tree | b5e468c3bd22898638c20793c0dbea51147c2861 /admin | |
| parent | 21cda148c7918df35f344823724099f2c5128411 (diff) | |
| parent | cf96e9cb5a5a03fc17f3d11c80c9dc482a58107d (diff) | |
Merge from origin/emacs-31
cf96e9cb5a5 ; Fix byte-compilation warnings in non-Tree-Sitter builds
23575adc7be ; * doc/lispref/variables.texi (Local Variables): Fix typ...
8b6fb2f6465 ; * doc/lispref/variables.texi (Local Variables): Fix 'na...
d3c72b83890 ; * src/xdisp.c (display_line): Fix commentary (bug#80693).
a981517b72e Fill margins with 'margin' face on truncated screen lines
8e374990357 ; * doc/lispref/os.texi (Init File): Fix markup (bug#81049).
f4c326c378a ; * src/sfnt.c (sfnt_read_cmap_format_12): Assert there's...
bf89ee6d078 ; * etc/PROBLEMS: Cursor not shown on Windows with system...
20500d62006 ; htmlfontify: Handle 'reset' face attribute value (bug#8...
d0d657fa902 ; Minor Tramp cleanup
93ea0d7d289 ; Improve documentation of VC commands in Dired
318084829c5 Eglot: adjust reference to completion frontends in manual
2a166c2dbdb Eldoc: display documentation in visual-line-mode
aba60ad0c5b Eglot: prefer markdown-ts-view-mode for markup rendering ...
689c3bd5088 Use 'read-multiple-choice' in 'markdown-ts-mode' (bug#81027)
71809ee5df5 Fix 'markdown-ts-code-span' face (bug#81026)
286833e401d Add read-only 'markdown-ts-view-mode' (bug#81023)
b39c123490b Fix strikethrough in 'markdown-ts-mode' (bug#80991)
0be998d4bc0 Fix code-span in headings in 'markdown-ts-mode' (bug#80979)
a00beb3a31b Make 'markdown-ts-inline-images' buffer local and test fo...
a0c05029fd1 * etc/NEWS: Mention new user option tramp-propagate-emacs...
2e71d2c709f Propagate EMACSCLIENT_TRAMP to remote hosts with Tramp
ff96db93f23 keyboard-tests.el: Try and fix the failure on EMBA
ce3098752cf doc: Remove long obsolete references to `package-initialize`
9bc04b001ac vc-next-action: Call vc-delete-file on FILESET-ONLY-FILES
13039e3442b ; touch-up last commit: copyright and comments
c2a24dcec8b ; update msys2 build helper for Emacs 31 & UCRT
3630baae720 hideshow: Support new 'margin' face for margin indicators...
20d17df3f4f Use the new 'margin' face in Flymake (bug#80693)
07f2bbc905d vc-dir-resynch-file: Pass down non-truename'd FILE
Diffstat (limited to 'admin')
| -rwxr-xr-x | admin/nt/dist-build/build-dep-zips.py | 144 |
1 files changed, 41 insertions, 103 deletions
diff --git a/admin/nt/dist-build/build-dep-zips.py b/admin/nt/dist-build/build-dep-zips.py index 5c760fb21ce..493e7616fa9 100755 --- a/admin/nt/dist-build/build-dep-zips.py +++ b/admin/nt/dist-build/build-dep-zips.py @@ -25,12 +25,12 @@ import subprocess from subprocess import check_output ## Constants -EMACS_MAJOR_VERSION= os.getenv('EMACS_MAJOR_VERSION') or "30" +EMACS_MAJOR_VERSION= os.getenv('EMACS_MAJOR_VERSION') or "31" # Base URI for the package sources mapped in PKG_REQ SRC_REPO="https://repo.msys2.org/mingw/sources" -# Map items in `dynamic-library-alist' to source packages +# Map items in `dynamic-library-alist' to source pakages PKG_REQ='''mingw-w64-x86_64-giflib mingw-w64-x86_64-gnutls mingw-w64-x86_64-harfbuzz @@ -47,29 +47,15 @@ mingw-w64-x86_64-xpm-nox mingw-w64-x86_64-tree-sitter mingw-w64-x86_64-sqlite3'''.split() -# Emacs style path to dependency DLLs on build system -DLL_SRC="c:/msys64/mingw64/bin" +# Emacs style path to dependancy DLLs on build system +DLL_SRC="mingw64" +OUT_TAG="" # libraries we never include DLL_SKIP=["libgccjit-0.dll"] -# Report first existing file for entries in dynamic-library-alist -# ELISP_PROG=""" -# (message "%s" (mapconcat 'identity (remove nil -# (mapcar (lambda(lib) -# (seq-find -# (lambda(file) -# (file-exists-p -# (file-name-concat "{}" -# file))) -# (cdr lib))) -# dynamic-library-alist) -# ) "\\n")) -# """.format(DLL_SRC) - ## Options DRY_RUN=False -# NEW_EMACS="bin/emacs.exe" def check_output_maybe(*args,**kwargs): if(DRY_RUN): @@ -82,7 +68,6 @@ def check_output_maybe(*args,**kwargs): # entry point def gather_deps(): - os.mkdir("x86_64") os.chdir("x86_64") @@ -95,12 +80,12 @@ def gather_deps(): if dep not in DLL_SKIP: if args.l != True: print("Adding dep", dep) - check_output_maybe(["cp /mingw64/bin/{} .".format(dep)], shell=True) + check_output_maybe(["cp /{}/bin/{} .".format(DLL_SRC,dep)], shell=True) else: if args.l != True: print("Skipping dep", dep) - zipfile="../emacs-{}-{}deps.zip".format(EMACS_MAJOR_VERSION, DATE) + zipfile="../emacs-{}{}-{}deps.zip".format(EMACS_MAJOR_VERSION, OUT_TAG, DATE) tmpfile="{}.tmp".format(zipfile) print("Zipping deps in", os.getcwd(), "as", tmpfile) check_output_maybe("zip -9vr {} *.dll".format(tmpfile), shell=True) @@ -110,7 +95,7 @@ def gather_deps(): print("Deps updated in", os.getcwd(), "as", zipfile) os.chdir("../") -# Return dependencies listed in Emacs +# Return dependancies listed in Emacs def init_deps(): return '''libXpm-nox4.dll libpng16-16.dll @@ -125,23 +110,17 @@ libglib-2.0-0.dll libgio-2.0-0.dll libgobject-2.0-0.dll libgnutls-30.dll -libxml2-2.dll +libxml2-16.dll zlib1.dll liblcms2-2.dll libgccjit-0.dll -libtree-sitter.dll'''.split() - # job_args=[NEW_EMACS, "--batch", "--eval", ELISP_PROG] - # #print("args: ", job_args) - # return subprocess.check_output(job_args, stderr=subprocess.STDOUT - # ).decode('utf-8').splitlines() +libtree-sitter-0.26.dll'''.split() # Return all second order dependencies def full_dll_dependency(dlls): deps = [dll_dependency(dep) for dep in dlls] return set(sum(deps, []) + dlls) -#xs = filter(lambda x: x.attribute == value, xs) - # Dependencies for a given DLL def dll_dependency(dll): output = check_output(["/mingw64/bin/ntldd", "--recursive", @@ -171,80 +150,29 @@ def ntldd_munge(out): ## Packages to fiddle with ## Source for gcc-libs is part of gcc SKIP_SRC_PKGS=["mingw-w64-gcc-libs"] -SKIP_DEP_PKGS=["mingw-w64-glib2", "mingw-w64-ca-certificates-20211016-3"] +SKIP_DEP_PKGS=["mingw-w64-glib2", "mingw-w64-x86_64-cc-libs", "mingw-w64-ca-certificates-20211016-3"] + +## A few source packages don't follow typical naming conventions. +## Handle transformation from formulaic name to actual name MUNGE_SRC_PKGS={ - "mingw-w64-libwinpthread-git":"mingw-w64-winpthreads-git", + "mingw-w64-libwinpthread":"mingw-w64-winpthreads", "mingw-w64-gettext-runtime":"mingw-w64-gettext" } + +## As above, but for source packages of second order deps +## Empty as of 30.0.50 (May, 2026), last used for Emacs 30.2 MUNGE_DEP_PKGS={ - "mingw-w64-x86_64-libwinpthread":"mingw-w64-x86_64-libwinpthread-git", - "mingw-w64-x86_64-libtre": "mingw-w64-x86_64-libtre-git", + #"mingw-w64-x86_64-libwinpthread":"mingw-w64-x86_64-libwinpthread-git", + #"mingw-w64-x86_64-libtre": "mingw-w64-x86_64-libtre-git", } + +# usual source ext is now tar.zst; this overrides that.. SRC_EXT={ - "mingw-w64-freetype": ".src.tar.zst", - "mingw-w64-fribidi": ".src.tar.zst", - "mingw-w64-glib2": ".src.tar.zst", - "mingw-w64-harfbuzz": ".src.tar.zst", - "mingw-w64-libunistring": ".src.tar.zst", - "mingw-w64-winpthreads-git": ".src.tar.zst", - "mingw-w64-ca-certificates": ".src.tar.zst", - "mingw-w64-libxml2": ".src.tar.zst", - "mingw-w64-ncurses": ".src.tar.zst", - "mingw-w64-openssl": ".src.tar.zst", - "mingw-w64-pango": ".src.tar.zst", - "mingw-w64-python": ".src.tar.zst", - "mingw-w64-sqlite3": ".src.tar.zst", - "mingw-w64-xpm-nox": ".src.tar.zst", - "mingw-w64-xz": ".src.tar.zst", - "mingw-w64-bzip2": ".src.tar.zst", - "mingw-w64-cairo": ".src.tar.zst", - "mingw-w64-expat": ".src.tar.zst", - "mingw-w64-fontconfig": ".src.tar.zst", - "mingw-w64-gdk-pixbuf2": ".src.tar.zst", - "mingw-w64-giflib": ".src.tar.zst", - "mingw-w64-gmp": ".src.tar.zst", - "mingw-w64-gnutls": ".src.tar.zst", - "mingw-w64-graphite2": ".src.tar.zst", - "mingw-w64-jbigkit": ".src.tar.zst", - "mingw-w64-lcms2": ".src.tar.zst", - "mingw-w64-lerc": ".src.tar.zst", - "mingw-w64-libdatrie": ".src.tar.zst", - "mingw-w64-libffi": ".src.tar.zst", - "mingw-w64-libiconv": ".src.tar.zst", - "mingw-w64-libiconv": ".src.tar.zst", - "mingw-w64-libpng": ".src.tar.zst", - "mingw-w64-librsvg": ".src.tar.zst", - "mingw-w64-libsystre": ".src.tar.zst", - "mingw-w64-libtasn": ".src.tar.zst", - "mingw-w64-libthai": ".src.tar.zst", - "mingw-w64-libtiff": ".src.tar.zst", - "mingw-w64-libtre-git": ".src.tar.zst", - "mingw-w64-libwebp": ".src.tar.zst", - "mingw-w64-mpdecimal": ".src.tar.zst", - "mingw-w64-nettle": ".src.tar.zst", - "mingw-w64-p11-kit": ".src.tar.zst", - "mingw-w64-pcre": ".src.tar.zst", - "mingw-w64-pixman": ".src.tar.zst", - "mingw-w64-python-packaging": ".src.tar.zst", - "mingw-w64-readline": ".src.tar.zst", - "mingw-w64-tcl": ".src.tar.zst", - "mingw-w64-termcap": ".src.tar.zst", - "mingw-w64-tk": ".src.tar.zst", - "mingw-w64-tree-sitter": ".src.tar.zst", - "mingw-w64-tzdata": ".src.tar.zst", - "mingw-w64-wineditline": ".src.tar.zst", - "mingw-w64-zlib": ".src.tar.zst", - "mingw-w64-zstd": ".src.tar.zst", - "mingw-w64-brotli": ".src.tar.zst", - "mingw-w64-gettext": ".src.tar.zst", - "mingw-w64-libdeflate": ".src.tar.zst", - "mingw-w64-libidn2": ".src.tar.zst", - "mingw-w64-libjpeg-turbo": ".src.tar.zst", - "mingw-w64-libtasn1": ".src.tar.zst", - "mingw-w64-pcre2": ".src.tar.zst", +# "mingw-w64-brotli": ".src.tar.gz", } -## Currently no packages seem to require this! +## Pick up packages only when building for a given architecture +## Currently no packages seem to require this! Unused since Emacs 26 ARCH_PKGS=[] def immediate_deps(pkg): @@ -296,7 +224,7 @@ def download_source(tarball): ) print("Downloading {}... done".format(tarball)) - print("Copying {} from local".format(tarball)) + #print("Copying {} from local".format(tarball)) shutil.copyfile("../emacs-src-cache/{}".format(tarball), "{}".format(tarball)) @@ -311,6 +239,7 @@ def gather_source(deps): os.chdir("emacs-src") for pkg in deps: + #print("Parsing pkg name and version from {}".format(pkg)) pkg_name_and_version= \ check_output(["pacman","-Q", pkg]).decode("utf-8").strip() @@ -321,7 +250,7 @@ def gather_source(deps): pkg_version=pkg_name_components[1] ## source pkgs don't have an architecture in them - pkg_name = re.sub(r"x86_64-","",pkg_name) + pkg_name = re.sub(r"(ucrt-)?x86_64-","",pkg_name) if(pkg_name in SKIP_SRC_PKGS): continue @@ -329,17 +258,18 @@ def gather_source(deps): ## Switch names if necessary pkg_name = MUNGE_SRC_PKGS.get(pkg_name,pkg_name) - ## src archive is usually a .tar.gz + ## src archive is usually a .tar.zst if pkg_name in SRC_EXT.keys(): src_ext = SRC_EXT[pkg_name] else: - src_ext = ".src.tar.gz" + src_ext = ".src.tar.zst" tarball = "{}-{}{}".format(pkg_name,pkg_version,src_ext) download_source(tarball) - srczip="../emacs-{}-{}deps-mingw-w64-src.zip".format(EMACS_MAJOR_VERSION,DATE) + srczip="../emacs-{}{}-{}deps-mingw-w64-src.zip".format( + EMACS_MAJOR_VERSION,OUT_TAG, DATE) tmpzip="{}.tmp".format(srczip) print("Zipping Dsrc in", os.getcwd(), "as", tmpzip) check_output_maybe("zip -9 {} *".format(tmpzip), shell=True) @@ -367,6 +297,9 @@ parser = argparse.ArgumentParser() #parser.add_argument("emacs", help="emacs executable") +parser.add_argument("-u", help="UCRT64 build", + action="store_true") + parser.add_argument("-s", help="snapshot build", action="store_true") @@ -382,16 +315,21 @@ parser.add_argument("-d", help="dry run", parser.add_argument("-l", help="list dependencies", action="store_true") -parser.add_argument("-e", help="extract direct dependencies", +parser.add_argument("-e", help="extract direct dependancies", action="store_true") args = parser.parse_args() do_all=not (args.c or args.r) + #NEW_EMACS=args.emacs DRY_RUN=args.d +if( args.u ): + DLL_SRC="ucrt64" + OUT_TAG="-ucrt" + if( args.e ): print("\n".join(init_deps())) |
