From owner-freebsd-questions@FreeBSD.ORG Thu May 20 17:48:52 2004 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 1E3D816A4CF for ; Thu, 20 May 2004 17:48:52 -0700 (PDT) Received: from cashmere.blitzed.org (cashmere.blitzed.org [82.195.232.22]) by mx1.FreeBSD.org (Postfix) with ESMTP id C4CC343D48 for ; Thu, 20 May 2004 17:48:51 -0700 (PDT) (envelope-from andy@freebsdwiki.org) Received: by cashmere.blitzed.org (Postfix, from userid 10000) id 88D20111C74; Fri, 21 May 2004 00:48:50 +0000 (GMT) Date: Fri, 21 May 2004 00:48:50 +0000 From: Andy Smith To: freebsd-questions@freebsd.org Message-ID: <20040521004850.GA457@cashmere.blitzed.org> Mail-Followup-To: freebsd-questions@freebsd.org References: <40ABA587.7020604@ctzen.com> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="9teSV9pdwBI9hpI9" Content-Disposition: inline In-Reply-To: <40ABA587.7020604@ctzen.com> X-Uptime: 11 days X-URL: http://freebsdwiki.org/User:Andy User-Agent: Mutt/1.5.6i Subject: Re: defining knobs in pkgtools.conf question X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 21 May 2004 00:48:52 -0000 --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 >=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--