1
0
mirror of https://github.com/skeeto/w64devkit.git synced 2025-07-05 00:02:27 +03:00

Remove NASM from the distribution

It's proven less useful than I originally hoped, and it's nearly always
better to use the GNU assembler instead. NASM doesn't support DWARF with
COFF, so it cannot be debugged with GDB. It's also ~100x slower than as,
which makes a huge different for generated assembly. With the autotools
fixes, it's now easy to natively build NASM from source using w64dk.
This commit is contained in:
Christopher Wellons
2024-07-29 14:06:45 -04:00
parent 7785eb9c7d
commit ec561dae94
3 changed files with 2 additions and 20 deletions

View File

@ -14,7 +14,6 @@ ARG MAKE_VERSION=4.4.1
ARG MINGW_VERSION=12.0.0 ARG MINGW_VERSION=12.0.0
ARG MPC_VERSION=1.3.1 ARG MPC_VERSION=1.3.1
ARG MPFR_VERSION=4.2.1 ARG MPFR_VERSION=4.2.1
ARG NASM_VERSION=2.15.05
ARG PDCURSES_VERSION=3.9 ARG PDCURSES_VERSION=3.9
ARG CPPCHECK_VERSION=2.10 ARG CPPCHECK_VERSION=2.10
ARG VIM_VERSION=9.0 ARG VIM_VERSION=9.0
@ -36,7 +35,6 @@ RUN curl --insecure --location --remote-name-all --remote-header-name \
https://ftp.gnu.org/gnu/libiconv/libiconv-$LIBICONV_VERSION.tar.gz \ https://ftp.gnu.org/gnu/libiconv/libiconv-$LIBICONV_VERSION.tar.gz \
https://frippery.org/files/busybox/busybox-w32-$BUSYBOX_VERSION.tgz \ https://frippery.org/files/busybox/busybox-w32-$BUSYBOX_VERSION.tgz \
http://ftp.vim.org/pub/vim/unix/vim-$VIM_VERSION.tar.bz2 \ http://ftp.vim.org/pub/vim/unix/vim-$VIM_VERSION.tar.bz2 \
https://www.nasm.us/pub/nasm/releasebuilds/$NASM_VERSION/nasm-$NASM_VERSION.tar.xz \
https://github.com/universal-ctags/ctags/archive/refs/tags/v$CTAGS_VERSION.tar.gz \ https://github.com/universal-ctags/ctags/archive/refs/tags/v$CTAGS_VERSION.tar.gz \
https://downloads.sourceforge.net/project/mingw-w64/mingw-w64/mingw-w64-release/mingw-w64-v$MINGW_VERSION.tar.bz2 \ https://downloads.sourceforge.net/project/mingw-w64/mingw-w64/mingw-w64-release/mingw-w64-v$MINGW_VERSION.tar.bz2 \
https://downloads.sourceforge.net/project/pdcurses/pdcurses/$PDCURSES_VERSION/PDCurses-$PDCURSES_VERSION.tar.gz \ https://downloads.sourceforge.net/project/pdcurses/pdcurses/$PDCURSES_VERSION/PDCurses-$PDCURSES_VERSION.tar.gz \
@ -56,7 +54,6 @@ RUN sha256sum -c $PREFIX/src/SHA256SUMS \
&& tar xzf make-$MAKE_VERSION.tar.gz \ && tar xzf make-$MAKE_VERSION.tar.gz \
&& tar xjf mingw-w64-v$MINGW_VERSION.tar.bz2 \ && tar xjf mingw-w64-v$MINGW_VERSION.tar.bz2 \
&& tar xzf PDCurses-$PDCURSES_VERSION.tar.gz \ && tar xzf PDCurses-$PDCURSES_VERSION.tar.gz \
&& tar xJf nasm-$NASM_VERSION.tar.xz \
&& tar xjf vim-$VIM_VERSION.tar.bz2 \ && tar xjf vim-$VIM_VERSION.tar.bz2 \
&& tar xzf cppcheck-$CPPCHECK_VERSION.tar.gz && tar xzf cppcheck-$CPPCHECK_VERSION.tar.gz
COPY src/w64devkit.c src/w64devkit.ico src/libmemory.c src/libchkstk.S \ COPY src/w64devkit.c src/w64devkit.ico src/libmemory.c src/libchkstk.S \
@ -444,15 +441,6 @@ RUN ARCH= make -j$(nproc) -f Make_ming.mak \
'$VIMRUNTIME/tutor/tutor' '%TMP%/tutor%RANDOM%' \ '$VIMRUNTIME/tutor/tutor' '%TMP%/tutor%RANDOM%' \
>$PREFIX/bin/vimtutor.bat >$PREFIX/bin/vimtutor.bat
# NOTE: nasm's configure script is broken, so no out-of-source build
WORKDIR /nasm-$NASM_VERSION
RUN ./configure \
--host=$ARCH \
CFLAGS="-Os" \
LDFLAGS="-s" \
&& make -j$(nproc) \
&& cp nasm.exe ndisasm.exe $PREFIX/bin
WORKDIR /ctags-$CTAGS_VERSION WORKDIR /ctags-$CTAGS_VERSION
RUN sed -i /RT_MANIFEST/d win32/ctags.rc \ RUN sed -i /RT_MANIFEST/d win32/ctags.rc \
&& make -j$(nproc) -f mk_mingw.mak CC=gcc packcc.exe \ && make -j$(nproc) -f mk_mingw.mak CC=gcc packcc.exe \

View File

@ -12,7 +12,6 @@ Included tools:
* [busybox-w32][bb] : standard unix utilities, including sh * [busybox-w32][bb] : standard unix utilities, including sh
* [Vim][vim] : powerful text editor * [Vim][vim] : powerful text editor
* [Universal Ctags][ctags] : source navigation * [Universal Ctags][ctags] : source navigation
* [NASM][nasm] : x86 assembler
* [Cppcheck][cppcheck] : static code analysis * [Cppcheck][cppcheck] : static code analysis
The toolchain includes pthreads, C++11 threads, and OpenMP. All included The toolchain includes pthreads, C++11 threads, and OpenMP. All included
@ -124,11 +123,9 @@ w64devkit's capabilities. In rough order of importance:
* [BusyBox man pages][doc-bb] (TXT), though everything here is also * [BusyBox man pages][doc-bb] (TXT), though everything here is also
available via `-h` option inside w64devkit. available via `-h` option inside w64devkit.
* [NASM manual][doc-nasm] (PDF)
* [Intel Software Developer Manuals][doc-intel] (PDF), for referencing x86 * [Intel Software Developer Manuals][doc-intel] (PDF), for referencing x86
instructions, when either studying compiler output with `objdump`, or instructions, when either studying compiler output with `objdump` or
writing assembly with `nasm` or `as`. writing assembly.
## Library installation ## Library installation
@ -239,7 +236,6 @@ binaries.
[doc-intr]: https://software.intel.com/sites/landingpage/IntrinsicsGuide/ [doc-intr]: https://software.intel.com/sites/landingpage/IntrinsicsGuide/
[doc-ld]: https://sourceware.org/binutils/docs/ [doc-ld]: https://sourceware.org/binutils/docs/
[doc-make]: https://www.gnu.org/software/make/manual/ [doc-make]: https://www.gnu.org/software/make/manual/
[doc-nasm]: https://www.nasm.us/docs.php
[doc-std]: https://stackoverflow.com/a/83763 [doc-std]: https://stackoverflow.com/a/83763
[doc-win32]: https://web.archive.org/web/20220922051031/http://www.laurencejackson.com/win32/ [doc-win32]: https://web.archive.org/web/20220922051031/http://www.laurencejackson.com/win32/
[gdb]: https://www.gnu.org/software/gdb/ [gdb]: https://www.gnu.org/software/gdb/
@ -249,7 +245,6 @@ binaries.
[lic2]: https://sourceforge.net/p/mingw-w64/mingw-w64/ci/master/tree/mingw-w64-libraries/winpthreads/COPYING [lic2]: https://sourceforge.net/p/mingw-w64/mingw-w64/ci/master/tree/mingw-w64-libraries/winpthreads/COPYING
[make]: https://www.gnu.org/software/make/ [make]: https://www.gnu.org/software/make/
[names]: https://learn.microsoft.com/en-us/cpp/build/reference/decorated-names [names]: https://learn.microsoft.com/en-us/cpp/build/reference/decorated-names
[nasm]: https://www.nasm.us/
[quilt]: http://savannah.nongnu.org/projects/quilt [quilt]: http://savannah.nongnu.org/projects/quilt
[san]: http://mingw-w64.org/doku.php/contribute#sanitizers_asan_tsan_usan [san]: http://mingw-w64.org/doku.php/contribute#sanitizers_asan_tsan_usan
[san2]: https://groups.google.com/forum/#!topic/address-sanitizer/q0e5EBVKZT4 [san2]: https://groups.google.com/forum/#!topic/address-sanitizer/q0e5EBVKZT4

View File

@ -11,6 +11,5 @@ dd16fb1d67bfab79a72f5e8390735c49e3e8e70b4945a15ab1f81ddb78658fb3 make-4.4.1.tar
cc41898aac4b6e8dd5cffd7331b9d9515b912df4420a3a612b5ea2955bbeed2f mingw-w64-v12.0.0.tar.bz2 cc41898aac4b6e8dd5cffd7331b9d9515b912df4420a3a612b5ea2955bbeed2f mingw-w64-v12.0.0.tar.bz2
ab642492f5cf882b74aa0cb730cd410a81edcdbec895183ce930e706c1c759b8 mpc-1.3.1.tar.gz ab642492f5cf882b74aa0cb730cd410a81edcdbec895183ce930e706c1c759b8 mpc-1.3.1.tar.gz
277807353a6726978996945af13e52829e3abd7a9a5b7fb2793894e18f1fcbb2 mpfr-4.2.1.tar.xz 277807353a6726978996945af13e52829e3abd7a9a5b7fb2793894e18f1fcbb2 mpfr-4.2.1.tar.xz
3caf6729c1073bf96629b57cee31eeb54f4f8129b01902c73428836550b30a3f nasm-2.15.05.tar.xz
590dbe0f5835f66992df096d3602d0271103f90cf8557a5d124f693c2b40d7ec PDCurses-3.9.tar.gz 590dbe0f5835f66992df096d3602d0271103f90cf8557a5d124f693c2b40d7ec PDCurses-3.9.tar.gz
a6456bc154999d83d0c20d968ac7ba6e7df0d02f3cb6427fb248660bacfb336e vim-9.0.tar.bz2 a6456bc154999d83d0c20d968ac7ba6e7df0d02f3cb6427fb248660bacfb336e vim-9.0.tar.bz2