problems with options in pkg cluster builds.
Jose M Rodriguez
josemi at freebsd.jazztel.es
Wed Apr 27 02:39:19 PDT 2005
El Martes, 26 de Abril de 2005 22:27, Jose M Rodriguez escribió:
> El Martes, 26 de Abril de 2005 21:56, Kris Kennaway escribió:
> > On Tue, Apr 26, 2005 at 09:35:46PM +0200, Jose M Rodriguez wrote:
> > > El Martes, 26 de Abril de 2005 21:25, Kris Kennaway escribi?:
> > > > On Tue, Apr 26, 2005 at 09:16:10AM +0200, Jose M Rodriguez
wrote:
> > > > > Hi,
> > > > >
> > > > > I'm having problems with pkg cluster builds after latest
> > > > > changes to options code.
> > > > >
> > > > > I want force the way packages must be build from make.conf
> > > > > and pkgtools.conf, but seems that default config is chase due
> > > > > to options code.
> > > > >
> > > > > This is an automated build in a fresh chroot with
> > > > > PACKAGE_BUILDING and BATCH defined that used to work before.
> > > > >
> > > > > Any know method to disabled options code?
> > > > >
> > > > > Any hope that this change may be reverted and options
> > > > > processing is supressed when PACKAGE_BUILDING is defined?
> > > >
> > > > No, this was a deliberate change, so your port needs to
> > > > accomodate it.
> > >
> > > There aren't my ports. I hate local patches.
> > >
> > > I Know this is deliberate. But it's not so simple to workaround
> > > as I spect.
> > >
> > > I'm using local patches. And thinking in do the config and them
> > > populate /var/db/ports from tarball in the beggin of the cluster
> > > scripting.
> > >
> > > but this is really odd.
> >
> > You'll have to explain what problem you're seeing.
>
> I can't be able to make pktools.conf and make.conf supersede ports
> default options from a fresh chroot cage without and /var/db/ports
> dir
>
> Maybe my fault, but ... any clues?
>
> --
> josemi
>
> > Kris
Apart the gs thing, maybe this NO_OPTIONS env aceptable for FreeBSD.
If so, I'll test this, polite and send-pr.
--
josemi
--- patch-no_options begins here ---
Index: bsd.port.mk
===================================================================
RCS file: /home/cvs/freebsd/ports/Mk/bsd.port.mk,v
retrieving revision 1.511
diff -u -r1.511 bsd.port.mk
--- bsd.port.mk 17 Mar 2005 23:22:07 -0000 1.511
+++ bsd.port.mk 27 Apr 2005 09:31:07 -0000
@@ -1085,10 +1085,12 @@
.endif
OPTIONSFILE?= ${PORT_DBDIR}/${UNIQUENAME}/options
_OPTIONSFILE!= ${ECHO_CMD} "${OPTIONSFILE}"
-.if defined(OPTIONS)
+.if !defined(NO_OPTIONS) && defined(OPTIONS)
. if defined(PACKAGE_BUILDING) || (defined(BATCH)
&& !exists(${_OPTIONSFILE}))
WITHOUT:=
WITH:=
+# redundant? see +4
+# I don't understand this piece of code from +3
. if defined(OPTIONS)
REALOPTIONS=${OPTIONS:C/".*"//g}
. for O in ${REALOPTIONS}
@@ -1101,6 +1103,7 @@
. endif
OPT:=${RO}
. endfor
+# redundant?
. endif
. for W in ${WITH}
WITH_${W}:= true
@@ -1786,23 +1789,19 @@
# compatible functionality.
.if !defined(WITHOUT_X11)
.if defined(WITH_GHOSTSCRIPT_AFPL)
-.if ${WITH_GHOSTSCRIPT_AFPL} == yes
GHOSTSCRIPT_PORT?= print/ghostscript-afpl
-.else
+.elif defined(WITH_GHOSTSCRIPT_GNU)
GHOSTSCRIPT_PORT?= print/ghostscript-gnu
-.endif
.else
-GHOSTSCRIPT_PORT?= print/ghostscript-gnu
+GHOSTSCRIPT_PORT?= print/ghostscript-gpl
.endif
.else
.if defined(WITH_GHOSTSCRIPT_AFPL)
-.if ${WITH_GHOSTSCRIPT_AFPL} == yes
GHOSTSCRIPT_PORT?= print/ghostscript-afpl-nox11
-.else
+.elif defined(WITH_GHOSTSCRIPT_GNU)
GHOSTSCRIPT_PORT?= print/ghostscript-gnu-nox11
-.endif
.else
-GHOSTSCRIPT_PORT?= print/ghostscript-gnu-nox11
+GHOSTSCRIPT_PORT?= print/ghostscript-gpl-nox11
.endif
.endif
@@ -2898,6 +2897,7 @@
################################################################
.if (!defined(OPTIONS) || defined(CONFIG_DONE) || \
defined(PACKAGE_BUILDING) || defined(BATCH) || \
+ defined(NO_OPTIONS) || \
exists(${_OPTIONSFILE}) || exists(${_OPTIONSFILE}.local))
_OPTIONS_OK=yes
.endif
@@ -4991,7 +4991,7 @@
.if !target(config)
config:
-.if !defined(OPTIONS)
+.if defined(NO_OPTIONS) || !defined(OPTIONS)
@${ECHO_MSG} "===> No options to configure"
.else
.if ${OPTIONSFILE} != ${_OPTIONSFILE}
@@ -5078,14 +5078,14 @@
.if !target(config-conditional)
config-conditional:
-.if defined(OPTIONS) && !exists(${_OPTIONSFILE})
+.if !defined(NO_OPTIONS) && defined(OPTIONS)
&& !exists(${_OPTIONSFILE})
cd ${.CURDIR} && ${MAKE} config;
.endif
.endif
.if !target(showconfig)
showconfig:
-.if defined(OPTIONS) && exists(${_OPTIONSFILE})
+.if !defined(NO_OPTIONS) && defined(OPTIONS) && exists(${_OPTIONSFILE})
@${ECHO_MSG} "===> The following configuration options are set for
${PKGNAME}:"
- at if [ -e ${_OPTIONSFILE} ]; then \
. ${_OPTIONSFILE}; \
@@ -5117,7 +5117,7 @@
.if !target(rmconfig)
rmconfig:
-.if defined(OPTIONS) && exists(${_OPTIONSFILE})
+.if !defined(NO_OPTIONS) && defined(OPTIONS) && exists(${_OPTIONSFILE})
-@${ECHO_MSG} "===> Removing user-configured options for ${PKGNAME}";
\
if [ `${ID} -u` != 0 -a "x${INSTALL_AS_USER}" = "x" ]; then \
${ECHO_MSG} "===> Switching to root credentials to remove
${_OPTIONSFILE} and `${DIRNAME} ${_OPTIONSFILE}`"; \
--- patch-no_options ends here ---
More information about the freebsd-ports
mailing list