Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 29 Nov 2012 11:43:47 +0200
From:      Peter Pentchev <roam@ringlet.net>
To:        Paul Schmehl <pschmehl_lists@tx.rr.com>
Cc:        FreeBSD Ports List <freebsd-ports@freebsd.org>
Subject:   Re: How to descend into the extract to build in a subdir
Message-ID:  <20121129094347.GB5519@straylight.m.ringlet.net>
In-Reply-To: <CB70CE7ED03D19FD8766CF79@utd71538.campus.ad.utdallas.edu>
References:  <4B522159C9F77F81D968E64D@utd71538.campus.ad.utdallas.edu> <CB70CE7ED03D19FD8766CF79@utd71538.campus.ad.utdallas.edu>

next in thread | previous in thread | raw e-mail | index | archive | help

--7iMSBzlTiPOCCT2k
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On Tue, Nov 27, 2012 at 02:45:54PM -0600, Paul Schmehl wrote:
> --On November 27, 2012 2:24:12 PM -0600 Paul Schmehl
> <pschmehl_lists@tx.rr.com> wrote:
>=20
> >I'm working on a port that requires a separate ./configure and ./make to
> >build libraries before you build the main source.  How is this done in
> >ports?
> >
> >I figure you have to do something in pre-build:, but I'm not sure exactly
> >what.
> >(cd ${WRKSRC}/subdir && ${MAKE}) causes make to fail entirely.  I'm
> >having trouble finding a comparable example in ports and there doesn't
> >seem to be anything about it in the porters handbook (that I have found.)
>=20
> Never mind.  I figured it outl
>=20
> .if ${PORT_OPTIONS:MBROCCOLI}
> pre-configure:
>        (cd ${WRKSRC}/aux/broccoli && ./configure)
> pre-build:
>        (cd ${WRKSRC}/aux/broccoli && ${MAKE})
> .endif

I know I'm a bit late to this party, but still - if this is a GNU
configure script, you might want to pass a couple more options to it.
Take a look at how bsd.port.mk (around line 3735) does it - it basically
runs
${SETENV} ... ${CONFIGURE_ENV} ./${CONFIGURE_SCRIPT} ${CONFIGURE_ARGS}
with a couple more environment variables defined (compiler, linker,
paths, etc).  If your port does not do at least something similar to
this, it might end up compiling different parts of the source with
different settings (e.g. CC, CFLAGS, CPPFLAGS for -D... and -I... and so
on).

And the same goes for the ${MAKE} invocation - take a look at the
do-build target in bsd.port.mk (just a couple of lines below the
configure one) - at least ${SETENV} ${MAKE_ENV} ${MAKE}, if not a couple
more MAKE_FLAGS and MAKE_ARGS, maybe MAKE_JOBS for parallel building.

G'luck,
Peter

--=20
Peter Pentchev	roam@ringlet.net roam@FreeBSD.org p.penchev@storpool.com
PGP key:	http://people.FreeBSD.org/~roam/roam.key.asc
Key fingerprint 2EE7 A7A5 17FC 124C F115  C354 651E EFB0 2527 DF13
What would this sentence be like if pi were 3?

--7iMSBzlTiPOCCT2k
Content-Type: application/pgp-signature; name="signature.asc"
Content-Description: Digital signature

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.12 (GNU/Linux)

iQIcBAEBCAAGBQJQty5OAAoJEGUe77AlJ98TSV8P/jHsZDXTmyfKBYKgK8en4nYu
kMjfFEjC0J22FQu5vu9zxdsY/aDb5FABEsz4HCJKv2DXsCflIjnvonJamJj5fygO
XFGeBWoTgXRv9n4N6S5aJ9z216UPyOkWSHtAHnwYLsr7xT64lu6ukRDv6fP0pim/
9xYl4IxvrwXgbPSiVg2WiALnRbobHmnhnDkwtiqID0SSHpsLbwVmks2xrQTLg52X
/NMNuTAM/fpN6KgWxS+kCfx0STVbdWhhy6GqkIuOGx9T5FeK408vNSDoM6tmgsFC
CfZlSEcPD9ZfNuvhUaUPFfPWxowr+1Fq8U2yd+cfFRiBx/R17DLPeYS+esCnj/zE
2S2Fu4NsYZR5iWHNgeAS+GNZ0cgPA4KdCv+5yYUOoBuhVyLRE0H0bdH8OWA9KDkF
PAeP8j88D7FT4bge6yrmqH2/1bip91cGdduyeKknPnIRxumSkJ+aRHVUWXCljGu4
KHUtbjw1WK9/Yfww/osBcJYZqUNCIqQKp0xaIvrz5XSc70EJzOpt2Q0W3mUx3YBM
WEH1xXOt1VvllOoEvEcb4HhddO0t8A80zq62gT1UoHUgPJOgp+zX4co91t6hkCMx
zecBk/WOvcZkj+t4js7QAkX3dw4Y+Xli7B3pSKbnEvc18uyBFtaBHqIPlGwkBD/z
BftF3xmaYlWrWq8qvdFO
=rO3v
-----END PGP SIGNATURE-----

--7iMSBzlTiPOCCT2k--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20121129094347.GB5519>