Add fetch-makefile to bsd.port.subdir.mk, mirror-maker to main Makefile.
Tweak fetch-makefile to take PERMIT_* into account, giving us the level of control needed.
This commit is contained in:
parent
9f73dffd75
commit
8285a069ca
13
Makefile
13
Makefile
|
@ -1,4 +1,4 @@
|
|||
# $OpenBSD: Makefile,v 1.20 2000/03/03 14:23:10 turan Exp $
|
||||
# $OpenBSD: Makefile,v 1.21 2000/03/04 18:16:02 espie Exp $
|
||||
# $FreeBSD: Makefile,v 1.36 1997/10/04 15:54:31 jkh Exp $
|
||||
#
|
||||
|
||||
|
@ -64,3 +64,14 @@ search: ${.CURDIR}/INDEX
|
|||
.else
|
||||
@grep -i ${key} ${.CURDIR}/INDEX | awk -F\| '{ printf("Port:\t%s\nPath:\t%s\nInfo:\t%s\nMaint:\t%s\nIndex:\t%s\nB-deps:\t%s\nR-deps:\t%s\nArchs:\t%s\n\n", $$1, $$2, $$4, $$6, $$7, $$8, $$9, $$10); }'
|
||||
.endif
|
||||
|
||||
|
||||
MIRROR_MK?= ${.CURDIR}/distfiles/Makefile
|
||||
|
||||
mirror-maker:
|
||||
@mkdir -p ${MIRROR_MK:H}
|
||||
@echo "default:: ftp cdrom" >${MIRROR_MK}
|
||||
@echo ".PHONY: default all ftp cdrom" >>${MIRROR_MK}
|
||||
@make fetch-makefile \
|
||||
ECHO_MSG='echo >&2' \
|
||||
FULL_PACKAGE_NAME=Yes >>${MIRROR_MK}
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
#-*- mode: Fundamental; tab-width: 4; -*-
|
||||
# ex:ts=4 sw=4 filetype=make:
|
||||
FULL_REVISION=$$OpenBSD: bsd.port.mk,v 1.219 2000/03/04 14:40:21 turan Exp $$
|
||||
FULL_REVISION=$$OpenBSD: bsd.port.mk,v 1.220 2000/03/04 18:16:02 espie Exp $$
|
||||
# $FreeBSD: bsd.port.mk,v 1.264 1996/12/25 02:27:44 imp Exp $
|
||||
# $NetBSD: bsd.port.mk,v 1.62 1998/04/09 12:47:02 hubertf Exp $
|
||||
#
|
||||
|
@ -1829,10 +1829,15 @@ _ALLFILES=${ALLFILES}
|
|||
.endif
|
||||
|
||||
fetch-makefile:
|
||||
.if ${MIRROR_DISTFILE:L} == "yes"
|
||||
@echo "all:: "`make package-name FULL_PACKAGE_NAME=${FULL_PACKAGE_NAME}`
|
||||
@cd ${.CURDIR} && make __FETCH_ALL=Yes __ARCH_OK=Yes NO_IGNORE=Yes NO_WARNINGS=Yes _fetch-makefile-helper
|
||||
@echo -n "all"
|
||||
.if defined(PERMIT_DISTFILES_FTP) && ${PERMIT_DISTFILES_FTP:L} == "yes"
|
||||
@echo -n " ftp"
|
||||
.endif
|
||||
.if defined(PERMIT_DISTFILES_CDROM) && ${PERMIT_DISTFILES_CDROM:L} == "yes"
|
||||
@echo -n " cdrom"
|
||||
.endif
|
||||
@echo ":: "`make package-name FULL_PACKAGE_NAME=${FULL_PACKAGE_NAME}`
|
||||
@cd ${.CURDIR} && make __FETCH_ALL=Yes __ARCH_OK=Yes NO_IGNORE=Yes NO_WARNINGS=Yes _fetch-makefile-helper
|
||||
|
||||
_fetch-makefile-helper:
|
||||
# write generic package dependencies
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
# from: @(#)bsd.subdir.mk 5.9 (Berkeley) 2/1/91
|
||||
# $OpenBSD: bsd.port.subdir.mk,v 1.14 1999/11/20 17:56:57 espie Exp $
|
||||
# $OpenBSD: bsd.port.subdir.mk,v 1.15 2000/03/04 18:16:02 espie Exp $
|
||||
# FreeBSD Id: bsd.port.subdir.mk,v 1.20 1997/08/22 11:16:15 asami Exp
|
||||
#
|
||||
# The include file <bsd.port.subdir.mk> contains the default targets
|
||||
|
@ -83,7 +83,7 @@ ${SUBDIR}::
|
|||
.for __target in all fetch fetch-list package extract configure \
|
||||
build clean depend describe distclean deinstall \
|
||||
reinstall tags checksum mirror-distfiles list-distfiles \
|
||||
obj
|
||||
obj fetch-makefile
|
||||
.if !target(${__target})
|
||||
${__target}: _SUBDIRUSE
|
||||
.endif
|
||||
|
|
Loading…
Reference in New Issue