I'm assuming it should, although there's a sentence in the FAQ that
suggests this is unsupported ("Examples are the _fake_ and install
make targets."; my emphasis). Anyway, I'm doing 'make package' as
non-root by setting these variables, and it mostly works.
The diff looks wrong. Wouldn't it be better to merge
scripts/makefile.openbsd into graphics/png/Makefile ? I don't
know how to do this. For example, graphics/jpeg is doing fine
without ever mentioning <bsd.lib.mk>.
Index: Makefile
===================================================================
RCS file: /cvs/ports/graphics/png/Makefile,v
retrieving revision 1.57
diff -u -r1.57 Makefile
--- Makefile 29 Jun 2006 14:33:47 -0000 1.57
+++ Makefile 24 Oct 2006 10:33:25 -0000
@@ -19,7 +19,7 @@
FAKE_FLAGS= ${MAKE_FLAGS} DESTDIR="${WRKINST}" PREFIX="${PREFIX}"
-MAKE_ENV= CC="${CC}"
+MAKE_ENV= CC="${CC}" BINOWN="${BINOWN}" BINGRP="${BINGRP}"
SHAREOWN="${SHAREOWN}" SHAREGRP="${SHAREGRP}" MANOWN="${MANOWN}"
MANGRP="${MANGRP}"
MAKE_FILE= scripts/makefile.openbsd
MAKE_FLAGS= SHLIB_MAJOR=${LIBpng_VERSION:R} \
SHLIB_MINOR=${LIBpng_VERSION:E} \
Index: patch-scripts_makefile_openbsd
===================================================================
RCS file: /cvs/ports/graphics/png/patches/patch-scripts_makefile_openbsd,v
retrieving revision 1.16
diff -u -r1.16 patch-scripts_makefile_openbsd
--- patch-scripts_makefile_openbsd 29 Jun 2006 14:33:47 -0000 1.16
+++ patch-scripts_makefile_openbsd 24 Oct 2006 09:58:19 -0000
@@ -1,6 +1,5 @@
-$OpenBSD: patch-scripts_makefile_openbsd,v 1.16 2006/06/29 14:33:47 bernd Exp $
---- scripts/makefile.openbsd.orig Tue Jun 27 22:22:40 2006
-+++ scripts/makefile.openbsd Thu Jun 29 11:03:42 2006
+--- scripts/makefile.openbsd.orig Tue Jun 27 14:22:40 2006
++++ scripts/makefile.openbsd Tue Oct 24 03:52:35 2006
@@ -3,11 +3,12 @@
# For conditions of distribution and use, see copyright notice in png.h
@@ -16,7 +15,7 @@
LIB= png
SRCS= png.c pngerror.c pnggccrd.c pngget.c pngmem.c pngpread.c \
-@@ -17,28 +18,46 @@ SRCS= png.c pngerror.c pnggccrd.c pngget
+@@ -17,56 +18,77 @@
HDRS= png.h pngconf.h
CFLAGS+= -Wall
@@ -65,21 +64,31 @@
- if [ ! -d ${DESTDIR}${PREFIX}/include/libpng ]; then \
- ${INSTALL} -d -o root -g wheel ${DESTDIR}${PREFIX}/include/libpng; \
+ if [ ! -d ${DESTDIR}${INCDIR} ]; then \
-+ ${INSTALL} -d -o root -g wheel ${DESTDIR}${INCDIR}; \
++ ${INSTALL} -d -o ${SHAREOWN} -g ${SHAREGRP} ${DESTDIR}${INCDIR}; \
fi
if [ ! -d ${DESTDIR}${LIBDIR} ]; then \
- ${INSTALL} -d -o root -g wheel ${DESTDIR}${LIBDIR}; \
-@@ -52,21 +71,24 @@ beforeinstall:
+- ${INSTALL} -d -o root -g wheel ${DESTDIR}${LIBDIR}; \
++ ${INSTALL} -d -o ${SHAREOWN} -g ${SHAREGRP} ${DESTDIR}${LIBDIR}; \
+ fi
+ if [ ! -d ${DESTDIR}${LIBDIR}/debug ]; then \
+- ${INSTALL} -d -o root -g wheel ${DESTDIR}${LIBDIR}/debug; \
++ ${INSTALL} -d -o ${SHAREOWN} -g ${SHAREGRP}
${DESTDIR}${LIBDIR}/debug; \
+ fi
+ if [ ! -d ${DESTDIR}${MANDIR}3 ]; then \
+- ${INSTALL} -d -o root -g wheel ${DESTDIR}${MANDIR}3; \
++ ${INSTALL} -d -o ${SHAREOWN} -g ${SHAREGRP} ${DESTDIR}${MANDIR}3; \
+ fi
if [ ! -d ${DESTDIR}${MANDIR}5 ]; then \
- ${INSTALL} -d -o root -g wheel ${DESTDIR}${MANDIR}5; \
+- ${INSTALL} -d -o root -g wheel ${DESTDIR}${MANDIR}5; \
++ ${INSTALL} -d -o ${SHAREOWN} -g ${SHAREGRP} ${DESTDIR}${MANDIR}5; \
fi
- if [ ! -d ${DESTDIR}${PREFIX}/share/doc/png ]; then \
- ${INSTALL} -d -o root -g wheel ${DESTDIR}${PREFIX}/share/doc/png; \
+ if [ ! -d ${DESTDIR}${DOCDIR} ]; then \
-+ ${INSTALL} -d -o root -g wheel ${DESTDIR}${DOCDIR}; \
++ ${INSTALL} -d -o ${SHAREOWN} -g ${SHAREGRP} ${DESTDIR}${DOCDIR}; \
fi
+ if [ ! -d ${DESTDIR}${LIBDIR}/pkgconfig ]; then \
-+ ${INSTALL} -d -o root -g wheel ${DESTDIR}${LIBDIR}/pkgconfig; \
++ ${INSTALL} -d -o ${SHAREOWN} -g ${SHAREGRP}
${DESTDIR}${LIBDIR}/pkgconfig; \
+ fi
afterinstall: