]> git.armaanb.net Git - asd-repo.git/blobdiff - extra/flex/build
m4, flex: replace with obsd implementations
[asd-repo.git] / extra / flex / build
index 2a1bda0af3e742f93e5f77fa5170cf841eb73553..22732edecf8bc396459f21414fdff9ab2fcc541d 100755 (executable)
@@ -1,11 +1,15 @@
-#!/bin/sh -e
+#!/usr/bin/sh -e
 
-./configure \
-    --prefix=/usr \
-    ac_cv_func_malloc_0_nonnull=yes \
-    ac_cv_func_realloc_0_nonnull=yes
+for i in libopenbsd libz yacc mv lex; do
+    make PREFIX=/usr -C "$i"
+done
 
-make
-make DESTDIR="$1" install
+cd lex
+install -Dm644 FlexLexer.h "$1/usr/include/FlexLexer.h"
+install -Dm755 lex         "$1/usr/bin/flex"
+install -Dm644 flex.1      "$1/usr/share/man/man1/flex.1"
+
+ln -s /usr/bin/flex            "$1/usr/bin/lex"
+ln -s /usr/bin/flex            "$1/usr/bin/flex++"
+ln -s /usr/share/man/man1/flex "$1/usr/share/man/man1/lex"
 
-ln -s flex "$1/usr/bin/lex"