Date: Fri, 21 May 2004 00:48:50 +0000 From: Andy Smith <andy@freebsdwiki.org> To: freebsd-questions@freebsd.org Subject: Re: defining knobs in pkgtools.conf question Message-ID: <20040521004850.GA457@cashmere.blitzed.org> In-Reply-To: <40ABA587.7020604@ctzen.com> References: <40ABA587.7020604@ctzen.com>
next in thread | previous in thread | raw e-mail | index | archive | help
--9teSV9pdwBI9hpI9 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Wed, May 19, 2004 at 02:20:55PM -0400, Chiang Seng Chang wrote: > =3D=3D=3D quote =3D=3D=3D >=20 > OPTIONS=3D THREADS "Enable thread support" on \ > HUGE_STACK_SIZE "Use a larger thread stack" off \ > UCS2 "Use UCS2 instead of UCS4 for unicode support" off \ > PYMALLOC "Uses python's internal malloc" on >=20 > .include <bsd.port.pre.mk> >=20 > .if defined(WITH_THREADS) > CONFIGURE_ARGS+=3D --with-threads > CFLAGS+=3D ${PTHREAD_CFLAGS} > .if defined(WITHOUT_HUGE_STACK_SIZE) > CFLAGS+=3D -DTHREAD_STACK_SIZE=3D0x20000 > .else > CFLAGS+=3D -DTHREAD_STACK_SIZE=3D0x100000 > .endif # defined(WITHOUT_HUGE_STACK_SIZE) > CONFIGURE_ENV+=3D LDFLAGS=3D"${PTHREAD_LIBS} ${LDFLAGS}" > .else > CONFIGURE_ARGS+=3D --without-threads > .if defined(LDFLAGS) > CONFIGURE_ENV+=3D LDFLAGS=3D"${LDFLAGS}" > .endif # defined(LDFLAGS) > .endif # defined(WITH_THREADS) >=20 > .if defined(WITHOUT_UCS2) > CONFIGURE_ARGS+=3D --enable-unicode=3Ducs4 > .endif >=20 > .if defined(WITHOUT_PYMALLOC) > CONFIGURE_ARGS+=3D --without-pymalloc > .endif >=20 > =3D=3D=3D end quote =3D=3D=3D >=20 > So if I wish to put the knobs into pkgtools.conf so that it can build it= =20 > batch mode, do I: >=20 > WITH_THREADS=3D1 > WITHOUT_HUGE_STACK_SIZE=3D1 I think that you only need to match the variables used in the Makefile. So the above would be correct, and the following two should just be omitted: > WITH_UCS2=3D1 > WITH_PYMALLOC=3D1 Don't forget you'll need to set BATCH as well. > I guess my question is how to decide wheather to use WITH_XXX=3D1 or=20 > WITHOUT_XXX=3D0 ? Set the exact same variables as the Makefile is testing. > does WITH_XXX=3D0 result in #defined(WITH_XXX) returning false ? I believe not, as "defined()" only tests if that name is defined, not what its value is. --=20 http://freebsdwiki.org/ - Encrypted mail welcome - keyid 0xBF15490B --9teSV9pdwBI9hpI9 Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.4 (FreeBSD) iD8DBQFArVHyIJm2TL8VSQsRAh2gAKDmsnBOP4x45dDMsqhJL8NHznDWbgCfa+a6 8I1pHYBUyhh1A0UiGA/JI0U= =JSQ+ -----END PGP SIGNATURE----- --9teSV9pdwBI9hpI9--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20040521004850.GA457>