[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
with the patch... Re: package vs. MTREE, bsd.port.mk patch, request for comments
- To: ports_(_at_)_openbsd_(_dot_)_org
- Subject: with the patch... Re: package vs. MTREE, bsd.port.mk patch, request for comments
- From: Marc Espie <Marc_(_dot_)_Espie_(_at_)_liafa_(_dot_)_jussieu_(_dot_)_fr>
- Date: Tue, 26 Oct 1999 18:48:58 +0200
On Tue, Oct 26, 1999 at 05:22:27PM +0200, Marc Espie wrote:
> This adds checks to bsd.port.mk to make sure that we use the right version
> of /etc/mtree.
>
> Yes, this means that each time the ports tree tracks a new snapshot,
> someone (turans@, most probably) will have to update MTREE_VERSION,
> but this is better than allowing people to build package with the wrong
> mtree files.
>
> Of course, getting smarter about mtree handling would also solve this...
It's better with the actual patch, of course...
Index: bsd.port.mk
===================================================================
RCS file: /cvs/ports/infrastructure/mk/bsd.port.mk,v
retrieving revision 1.130
diff -u -r1.130 bsd.port.mk
--- bsd.port.mk 1999/10/08 11:38:05 1.130
+++ bsd.port.mk 1999/10/26 15:20:08
@@ -663,8 +663,10 @@
.if !defined(MTREE_FILE)
.if defined(USE_IMAKE) || defined(USE_X11)
MTREE_FILE= /etc/mtree/BSD.x11.dist
+MTREE_VERSION = 1.3
.else
MTREE_FILE= /etc/mtree/BSD.local.dist
+MTREE_VERSION = 1.5
.endif
.endif
MTREE_CMD?= /usr/sbin/mtree
@@ -1551,6 +1553,12 @@
.if !target(do-package)
do-package:
+.if !defined(NO_MTREE)
+ @if ! fgrep OpenBSD ${MTREE_FILE}|fgrep ' ${MTREE_VERSION} '>/dev/null; then \
+ echo "Error: bad version of ${MTREE_FILE}"; \
+ exit 1; \
+ fi
+.endif
@if [ -e ${PLIST} ]; then \
${ECHO_MSG} "===> Building package for ${PKGNAME}"; \
if [ -d ${PACKAGES} ]; then \
--
Marc Espie
|anime, sf, juggling, unicycle, acrobatics, comics...
|AmigaOS, OpenBSD, C++, perl, Icon, PostScript...
| `real programmers don't die, they just get out of beta'
Visit your host, monkey.org