I tested the update with the default linker and with -fuse-ld=lld. Both
build and the assembler generates working executables and objects.

fasm can generate directly OpenBSD ELF executables but the source code
provided by upstream requires the compiler to link with libc.

OK?.


Index: Makefile
===================================================================
RCS file: /cvs/ports/devel/fasm/Makefile,v
retrieving revision 1.6
diff -u -p -r1.6 Makefile
--- Makefile    9 Nov 2014 01:05:36 -0000       1.6
+++ Makefile    25 Nov 2018 21:02:14 -0000
@@ -3,7 +3,7 @@
 ONLY_FOR_ARCHS =       i386
 
 COMMENT =              flat assembler
-DISTNAME =             fasm-1.71.22
+DISTNAME =             fasm-1.73.04
 CATEGORIES =           devel lang
 HOMEPAGE =             http://flatassembler.net/
 MAINTAINER =           Dmitri Alenichev <mi...@rockers.su>
@@ -19,11 +19,18 @@ NO_TEST =           Yes
 WRKSRC =               ${WRKDIR}/fasm
 
 do-build:
-       cd ${WRKSRC} && ${CC} ${CFLAGS} fasm.o -o fasm
+       cd ${WRKSRC} && \
+               ${CC} ${CFLAGS} -Wl,-znotext fasm.o -o fasm && \
+               rm fasm.o && ./fasm source/libc/fasm.asm fasm.o && rm fasm && \
+               ${CC} ${CFLAGS} -Wl,-znotext fasm.o -o fasm
 
 do-install:
        ${INSTALL_PROGRAM} ${WRKSRC}/fasm ${PREFIX}/bin
        ${INSTALL_DATA_DIR} ${PREFIX}/share/doc/fasm
+       ${INSTALL_DATA_DIR} ${PREFIX}/share/doc/fasm/libcdemo
        ${INSTALL_DATA} ${WRKSRC}/*.txt ${PREFIX}/share/doc/fasm
+       ${INSTALL_DATA} ${WRKSRC}/examples/libcdemo/*.asm \
+               ${WRKSRC}/examples/libcdemo/*.inc \
+               ${PREFIX}/share/doc/fasm/libcdemo
 
 .include <bsd.port.mk>
Index: distinfo
===================================================================
RCS file: /cvs/ports/devel/fasm/distinfo,v
retrieving revision 1.2
diff -u -p -r1.2 distinfo
--- distinfo    9 Nov 2014 01:05:36 -0000       1.2
+++ distinfo    25 Nov 2018 21:02:14 -0000
@@ -1,2 +1,2 @@
-SHA256 (fasm-1.71.22.tar.gz) = D8U/zOuGOupn2w2ncOqqn4xvLUodA6/AHYIYWD7y+vc=
-SIZE (fasm-1.71.22.tar.gz) = 250218
+SHA256 (fasm-1.73.04.tar.gz) = NxIIcPDcBJnxulYAfPTrIhpO/NBKcqxsf8D1NozUysI=
+SIZE (fasm-1.73.04.tar.gz) = 274732
Index: pkg/PLIST
===================================================================
RCS file: /cvs/ports/devel/fasm/pkg/PLIST,v
retrieving revision 1.1.1.1
diff -u -p -r1.1.1.1 PLIST
--- pkg/PLIST   11 Jan 2009 18:23:25 -0000      1.1.1.1
+++ pkg/PLIST   25 Nov 2018 21:02:14 -0000
@@ -2,6 +2,9 @@
 @bin bin/fasm
 share/doc/fasm/
 share/doc/fasm/fasm.txt
+share/doc/fasm/libcdemo/
+share/doc/fasm/libcdemo/ccall.inc
+share/doc/fasm/libcdemo/libcdemo.asm
 share/doc/fasm/license.txt
 share/doc/fasm/readme.txt
 share/doc/fasm/whatsnew.txt

Reply via email to