$NetBSD: patch-ai,v 1.25 2009/05/13 10:33:23 martti Exp $ Make this pkgsrc friendly. Add support for NetBSD 5.x and DragonFly BSD. --- makedefs.orig 2009-05-12 00:26:46.000000000 +0300 +++ makedefs 2009-05-13 12:26:34.000000000 +0300 @@ -144,6 +144,8 @@ ;; FreeBSD.7*) SYSTYPE=FREEBSD7 ;; + DragonFly.*) SYSTYPE=DRAGONFLY + ;; OpenBSD.2*) SYSTYPE=OPENBSD2 ;; OpenBSD.3*) SYSTYPE=OPENBSD3 @@ -160,6 +162,8 @@ ;; NetBSD.4*) SYSTYPE=NETBSD4 ;; + NetBSD.5*) SYSTYPE=NETBSD5 + ;; BSD/OS.2*) SYSTYPE=BSDI2 ;; BSD/OS.3*) SYSTYPE=BSDI3 @@ -212,13 +216,6 @@ esac ;; ULTRIX.4*) SYSTYPE=ULTRIX4 - if [ -f /usr/local/lib/libdb.a ]; then - SYSLIBS="$SYSLIBS -ldb" - CCARGS="$CCARGS -DHAS_DB" - if [ -d /usr/local/include/db ]; then - CCARGS="$CCARGS -I/usr/local/include/db" - fi - fi for l in syslog resolv; do if [ -f /usr/local/lib/lib$l.a ]; then SYSLIBS="$SYSLIBS -l$l" @@ -250,25 +247,8 @@ esac;; # Tested with RedHat 3.03 on 20020729. Linux.1*) SYSTYPE=LINUX1 - SYSLIBS="-ldb" ;; Linux.2*) SYSTYPE=LINUX2 - # Postfix no longer needs DB 1.85 compatibility - if [ -f /usr/include/db.h ] - then - : we are all set - elif [ -f /usr/include/db/db.h ] - then - CCARGS="$CCARGS -I/usr/include/db" - else - # No, we're not going to try db1 db2 db3 etc. - # On a properly installed system, Postfix builds - # by including and by linking with -ldb - echo "No include file found." 1>&2 - echo "Install the appropriate db*-devel package first." 1>&2 - echo "See the RELEASE_NOTES file for more information." 1>&2 - exit 1 - fi # GDBM locks the DBM .pag file after open. This breaks postmap. # if [ -f /usr/include/gdbm-ndbm.h ] # then @@ -279,7 +259,6 @@ # CCARGS="$CCARGS -DHAS_DBM -DPATH_NDBM_H=''" # GDBM_LIBS=gdbm # fi - SYSLIBS="-ldb" for name in nsl resolv $GDBM_LIBS do for lib in /usr/lib64 /lib64 /usr/lib /lib @@ -372,25 +351,13 @@ HP-UX.A.09.*) SYSTYPE=HPUX9 SYSLIBS=-ldbm CCARGS="$CCARGS -DMISSING_USLEEP" - if [ -f /usr/lib/libdb.a ]; then - CCARGS="$CCARGS -DHAS_DB" - SYSLIBS="$SYSLIBS -ldb" - fi ;; HP-UX.B.10.*) SYSTYPE=HPUX10 CCARGS="$CCARGS `nm /usr/lib/libc.a 2>/dev/null | (grep usleep >/dev/null || echo '-DMISSING_USLEEP')`" - if [ -f /usr/lib/libdb.a ]; then - CCARGS="$CCARGS -DHAS_DB" - SYSLIBS=-ldb - fi ;; HP-UX.B.11.*) SYSTYPE=HPUX11 SYSLIBS=-lnsl - if [ -f /usr/lib/libdb.a ]; then - CCARGS="$CCARGS -DHAS_DB" - SYSLIBS="$SYSLIBS -ldb" - fi ;; ReliantUNIX-?.5.43) SYSTYPE=ReliantUnix543 RANLIB=echo