Annotation of src/share/mk/bsd.port.mk, revision 1.17

1.1       dillon      1: # $FreeBSD: src/share/mk/bsd.port.mk,v 1.303.2.2 2002/07/17 19:08:23 ru Exp $
1.10      joerg       2: # $DragonFly$
1.1       dillon      3: 
                      4: PORTSDIR?=     /usr/ports
1.4       dillon      5: DFPORTSDIR?=   /usr/dfports
1.3       dillon      6: PORTPATH!=     /usr/bin/relpath ${PORTSDIR} ${.CURDIR}
1.1       dillon      7: 
1.17    ! joerg       8: .if !defined(DFOSVERSION)
        !             9: DFOSVERSION!=  /sbin/sysctl -n kern.osreldate
        !            10: .endif
        !            11: 
1.7       dillon     12: # Temporary Hack
                     13: #
                     14: OSVERSION ?= 480102
                     15: UNAME_s?= FreeBSD
                     16: UNAME_v?=FreeBSD 4.8-CURRENT
                     17: UNAME_r?=4.8-CURRENT
                     18: 
                     19: .makeenv UNAME_s
                     20: .makeenv UNAME_v
                     21: .makeenv UNAME_r
                     22: .makeenv OSVERSION
                     23: 
1.9       joerg      24: .if !exists(${DFPORTSDIR}/${PORTPATH}/Makefile)
                     25: 
1.13      joerg      26: .if defined(USE_RC_SUBR)
                     27: .undef USE_RC_SUBR
                     28: RC_SUBR=       /etc/rc.subr
                     29: .endif
                     30: 
1.5       dillon     31: # If the port does not exist in /usr/dfports/<portpath> use the original
                     32: # FreeBSD port.  Also process as per normal if BEFOREPORTMK is set so
                     33: # any expected variables are set.
1.3       dillon     34: #
1.1       dillon     35: .include <bsd.own.mk>
                     36: .include "${PORTSDIR}/Mk/bsd.port.mk"
1.3       dillon     37: 
                     38: .else
                     39: 
1.5       dillon     40: .undef BEFOREPORTMK
                     41: .undef AFTERPORTMK
                     42: 
1.3       dillon     43: # Otherwise retarget to the DragonFly override port.
                     44: #
                     45: 
                     46: TARGETS+=      all
                     47: TARGETS+=      build
                     48: TARGETS+=      checksum
                     49: TARGETS+=      clean
                     50: TARGETS+=      clean-for-cdrom
                     51: TARGETS+=      clean-for-cdrom-list
                     52: TARGETS+=      clean-restricted
                     53: TARGETS+=      clean-restricted-list
                     54: TARGETS+=      configure
                     55: TARGETS+=      deinstall
                     56: TARGETS+=      depend
                     57: TARGETS+=      depends
                     58: TARGETS+=      describe
                     59: TARGETS+=      distclean
                     60: TARGETS+=      extract
                     61: TARGETS+=      fetch
                     62: TARGETS+=      fetch-list
                     63: TARGETS+=      ignorelist
                     64: TARGETS+=      makesum
                     65: TARGETS+=      maintainer
                     66: TARGETS+=      package
                     67: TARGETS+=      realinstall
                     68: TARGETS+=      reinstall
                     69: TARGETS+=      install
                     70: TARGETS+=      tags
                     71: 
1.6       dillon     72: .undef PORTSDIR
1.14      cpressey   73: .if !make(package-depends-list) && !make(all-depends-list) && \
                     74:     !make(run-depends-list) && !make(build-depends-list)
1.5       dillon     75: .BEGIN:
1.4       dillon     76:        @echo "WARNING, USING DRAGONFLY OVERRIDE ${DFPORTSDIR}/${PORTPATH}"
1.5       dillon     77:        cd ${DFPORTSDIR}/${PORTPATH} && ${MAKE} -B ${.TARGETS}
1.9       joerg      78: .endif
1.3       dillon     79: 
1.12      joerg      80: .if !empty(.TARGETS)
1.8       joerg      81: ${.TARGETS}:
1.12      joerg      82: .else
                     83: all:
                     84: .MAIN: all
                     85: .endif
1.8       joerg      86: 
1.11      joerg      87: # Hack to get Makefiles with conditional statements working
                     88: XFREE86_VERSION?=      4
                     89: ARCH?=                 i386
                     90: MACHINE_ARCH?=         i386
                     91: HAVE_GNOME?=
1.16      joerg      92: FILESDIR?=             ${.CURDIR}/files
1.11      joerg      93: 
1.15      hmp        94: # WORKAROUND to get portupgrade working
                     95: # Taken from: ${PORTSDIR}/Mk/bsd.port.mk
                     96: .if !defined(PKGNAME)
                     97: PKGNAME=       ${PKGNAMEPREFIX}${PORTNAME}${PKGNAMESUFFIX}-${PORTVERSION:C/[-_,]/./g}${_SUF1}${_SUF2}
                     98: .endif
                     99:  
1.3       dillon    100: .endif
                    101: