Commit graph

165 commits

Author SHA1 Message Date
jlam
46728682bf Don't generate wrapper scripts if we can't find the wrappee. 2004-02-09 03:05:59 +00:00
jlam
8396978738 We need the full path to the libtool that needs to be invoked when we
use LIBTOOL_OVERRIDE.  In the buildlink[23] case, that is supposed to be
the one in ${BUILDLINK_DIR}.  Create new private variables _LIBTOOL and
_SHLIBTOOL to hold these paths.
2004-02-09 01:30:59 +00:00
jlam
3f0c4ee09a * Let CC/CXX/CPP/FC always point to the compiler used in the actual
building of software.  For packages that use either buildlink2 or
  buildlink3, this would be the wrapper script in ${BUILDLINK_DIR}.

* Garbage-collect _BLNK_WRAP_SETENV.* as those are not needed after
  the above changes.  Configure and make processes will automatically
  find the right compilers in the PATH.

* PKGLIBTOOL and PKGSHLIBTOOL are no longer needed since LIBTOOL and
  SHLIBTOOL point to the correct libtools regardless of any
  USE_BUILDLINK[23] definitions.
2004-02-08 02:59:14 +00:00
jlam
d72bb0e381 Hiding the PATH from certain phases of the build only accidentally worked
due to a type on gcc.mk that causes the ${_GCC_PREFIX}/bin to always be
prepended to the PATH.  The problem that was hiding was "make" resolving
to ${TOOLS_DIR}/bin/make if the package used GNU make, which broke
building since the package Makefile is a BSD Makefile and we passed
PATH to some phases of the build.  Fix this by expanding MAKE to the
full path to ${MAKE} in bsd.prefs.mk.  We also garbage collect the now
useless checks for PHASES_AFTER_BUILDLINK that cluttered the PREPEND_PATH
code.
2004-02-06 04:37:02 +00:00
jlam
bed8d4d73e We only prepend a directory to the PATH if we haven't already done so
(by checking PREPEND_PATH) and only for those phases of the build that
care about the PATH (buildlink or later).  We also pass the PATH to
those same phases of the build so that executing ${CC} will work correctly
from custom {pre,do,post}-* targets that occur at buildlink time or
later.
2004-02-06 03:04:50 +00:00
jlam
991c843d4f Allow this to work with ccache by passing the full PATH through libtool. 2004-02-05 09:57:53 +00:00
jlam
1f190fe0f5 Use the new work log format used by buildlink3. Lines beginning with
"[*]" are the untransformed command lines, and the ones beginning with
"<.>" are the ones that are actually executed.
2004-02-05 08:27:18 +00:00
jlam
09eca416bc Instead of tedious validating every platform for full caching compliance,
just assume they do unless they're known _not_ to work.  So far, only
Darwin-5.* suffers from this problem, apparently because they use some
bizarre version of zsh for /bin/sh.
2004-02-04 01:13:04 +00:00
jlam
e9559de07c Only create wrapper scripts for compilers that we require support for as
noted in USE_LANGUAGES.
2004-02-02 10:26:42 +00:00
grant
df107af10c use sanitize-rpath for SunPro again with the new compiler framework. 2004-02-01 12:04:31 +00:00
recht
a8f44897b9 Bump the x11-links dependency to 0.20 to get the extensions/extutil.h
header.
2004-01-31 22:00:51 +00:00
rh
8c4d9ffa48 Add *RECOMMENDED variables as discussed on tech-pkg@ to allow for a more
fine-grained distinction between required versions of pre-requisites
(DEPENDS) and versions that are recommended for security or library ABI
consistency reasons (RECOMMENDED).

  The contents of ${RECOMMENDED} are added to DEPENDS unless
IGNORE_RECOMMENDED is set to YES, in which case a warning will be printed
and IGNORE_RECOMMENDED will be added to BUILD_DEFS.

  Add a corresponding BUILDLINK_RECOMMENDED.<pkg> variable for use with
buildlink2 and buildlink3.
2004-01-14 06:57:45 +00:00
gavan
fe7e08a748 Remove libraries from the output if they don't exist.
ok'd by grant.
2003-12-30 12:09:27 +00:00
veego
aacddadd1d Update for the latest x11-links 0.19. 2003-12-19 19:22:28 +00:00
erh
c092d839cc Escape any ':' characters when using ${FLAG} as a match pattern. 2003-12-12 21:37:55 +00:00
xtraeme
986e1fda57 Enable _BLNK_CACHE_ALL in FreeBSD (approved by silence in tech-pkg@). 2003-12-12 04:26:36 +00:00
salo
404fee3611 Use BUILDLINK_SHELL, do not hardcode /bin/sh.
From PR pkg/23685 by Adam C. Migus.
Addresses PR pkg/23691 by Rob Quinn.
2003-12-08 13:38:19 +00:00
erh
97e8a744ee fake-la also needs @AR@ replaced now. 2003-12-03 18:38:04 +00:00
erh
619cf5c083 Shared libraries on AIX have a ".a" extension. Handle those by either looking
for an existing libtool ".la" library, or looking inside the archive for the
.so file.
Also, fail immediately if passed a library that isn't handled.
2003-12-03 18:37:35 +00:00
tron
ef247410ff Bump minimum required version of "x11-links" package. 2003-10-18 18:24:56 +00:00
veego
4d271b3397 Update pkgtools/x11-links to 0.16.
Changes include supporting XFree86-4.3.99.14 aka XFree86-current.
Added some new library versions and some freetype2 include files.
And bump the required version number in the bsd.buildlink mk's.
2003-10-13 15:55:11 +00:00
skrll
cb019b8f9c Add a --mode== for libtool 1.5 2003-09-15 21:52:51 +00:00
jlam
4831429fd8 There's no need to preserve mode bits when copying the x11-links tree.
This fixes problems where .buildlink assumes the mode of
${LOCALBASE}/share/x11-links, which may be read-only.
2003-09-10 12:58:38 +00:00
jlam
81329481d9 Use pax(1) instead of "cp -R" so we preserve symlinks instead of following
them.
2003-09-09 09:15:02 +00:00
jlam
841b57441b Merge pkgviews-mk branch into the HEAD by running:
cd pkgsrc/mk
	cvs update -Pd -A
	cvs update -Pd -j pkgviews-mk-base -j pkgviews-mk
2003-09-02 06:59:37 +00:00
jlam
e4ba59523f bsd.buildlink2.mk says that Solaris 9 works with full caching. 2003-08-31 10:17:16 +00:00
jlam
759dd368bc Remove N/A from this file... it's much easier to read now. 2003-08-31 10:15:42 +00:00
jlam
5ed77489aa Don't allow -R* options in dependency_libs -- rpath info shouldn't be in
there.
2003-08-31 08:56:39 +00:00
jlam
c5621e9ba4 Strip bare -L${BUILDLINK_DIR}, -L${BUILDLINK_X11_DIR} and -L${WRKSRC}, as
well as stripping -L to subdirs of these directories from dependency_libs
lines in *.lai files.  This corrects the changes in revision 1.18 of this
file and restores some functionality accidentally removed in version 1.19
of this file.  Should fix the subversion buildlink/libtool problem
reported on tech-pkg@.
2003-08-31 06:07:33 +00:00
jlam
8d5649cbcd Correct the glob so that we actually match -L${BUILDLINK_DIR}/* and
-L${BUILDLINK_X11_DIR} and discard them.  (from pkgviews-mk).
2003-08-27 12:57:52 +00:00
jlam
e5462ca730 (*) Nuke the _BUILDLINK_SUBST_USE target now that subst.mk does the same
thing.

(*) Move the code to adjust Makefiles to refer to the correct
    PKGLOCALEDIR into bsd.pkg.mk and reimplement it using subst.mk so
    that it's non-USE_BUILDLINK2 packages can use it, too.

(*) Reimplement the PKGCONFIG_OVERRIDE code in bsd.pkg.mk using subst.mk.

(*) Reimplement the unbuildlink code in bsd.buildlink2.mk using subst.mk.
2003-08-27 11:29:56 +00:00
jlam
ac0258dd3c Move the hide-tools portion of bsd.buildlink2.mk into tools.mk, and
put the tools in ${WRKDIR}/.tools/bin instead of in ${BUILDLINK_DIR},
and remove the need for buildlink2 to use USE_GNU_TOOLS.  In the
modified USE_GNU_TOOLS implementation, the following implementation-
specific variables have the following meanings:

_TOOLS_REPLACE.<tool>
        means that we want ${AWK}, ${SED}, etc. symlinked into
        ${TOOLS_DIR} as awk, sed, etc.

_TOOLS_NEED_GNU.<tool>
        means that we want to use the pkgsrc version of <tool>
        symlinked info ${TOOLS_DIR} as awk, sed, etc.  If this is
        "YES", then it always trumps _TOOLS_REPLACE.<tool>.

And we want nothing to happen if we're building the pkgsrc GNU tool
itself.  The modified USE_GNU_TOOLS implementation should also
hopefully fix the circular dependency problem.

Create a new target "tools" that is run after "patch" and before
"buildlink" that populates the ${TOOLS_DIR} directory.  This ensures
that it's always run at the right time, instead of relying on
pre-buildlink or pre-configure, which may be cancelled by
NO_BUILDLINK or NO_CONFIGURE.

XXX There is some possible fallout in texinfo.mk with the MAKE_ENV and
XXX CONFIGURE_ENV settings for INSTALL_INFO and MAKEINFO.  It looks
XXX like the MAKE_ENV and CONFIGURE_ENV settings should move from
XXX tools.mk into texinfo.mk, and they no longer need to be
XXX conditional on USE_BUILDLINK2.  I'll leave it to the texinfo.mk
XXX dude (Hi, Stoned!).
2003-08-16 08:50:17 +00:00
jlam
c98b5b201d Teach the buildlink2 wrappers to respect an environment variable
BUILDLINK_WRAPPER_LOG to specify the location of the wrapper log
(which defaults to ${BUILDLINK_DIR}/.wrapper.log).
2003-08-16 06:59:54 +00:00
seb
0d0e9d3ac1 USE_NEW_TEXINFO is now ubiquitous. Remove conditionals on it.
Also remove the older texinfo.mk framework as well as the previous
handling of INFO_FILES, all this is not used anymore.
2003-08-09 10:24:54 +00:00
seb
16437cbe4c Make it possible to have a package requiring makeinfo but not install-info.
INFO_FILES is now defined by default to the empty value.
If it is not empty it means that install-info -or a suitable
replacement like pkg_install-info- is required.

USE_MAKEINFO is now defined by default to the 'no' value.
If it has any other value it means that makeinfo is required.
Note that as before simply defining USE_MAKEINFO in a package
Makefile is enough to trigger the use of makeinfo. I.e. it is not
required to be '[yY][eE][sS]'.

As a side effect when using buildlink2 always create install-info and
makeinfo wrappers in ${BUILDLINK_DIR}/bin. This could help
package maintainer to catch spurious/hidden install-info and makeinfo
usage.

Note that for now this nice feature is not really enabled as the relevant
part of bsd.buildlink2.mk is still conditional upon USE_NEW_TEXINFO.
It will really be when USE_NEW_TEXINFO will be removed from pkgsrc.
2003-07-31 13:50:11 +00:00
seb
751840e777 Sync comments with reality wrt to USE_MAKEINFO == "no". 2003-07-22 01:10:32 +00:00
salo
21b6a8eb80 Use proper compiler test.
(the former was unreliable anyway, there could be GCC installed as cc == no
*gcc* pattern in path)
2003-07-09 20:07:46 +00:00
salo
d750aba607 More support bits for native Sun compilers (on Solaris).
Sun's C++ compiler (CC) doesn't support passing arguments to ld via -Wl flag,
remove this flag from the buildlink2 environment.
2003-07-09 16:07:21 +00:00
seb
ddfc49b652 Use "$@" when it matters. 2003-07-02 21:19:09 +00:00
seb
8c50b1beff Using GNU missing script as makeinfo seemed like a good idea
when a package use the buildlink2 framework but does not define
USE_MAKEINFO. Well it was not after all.

This caused annoying messages because missing's commands emit annoying error
messages when the script is invoked with only 'makeinfo' as argument
(typically run this way by configure scripts). And more it does not
handle makeinfo's '--output=...' argument.

I first thought that it could be used as a nice way to get ride of the need
for makeinfo when it was only dubiously run during build or installation
of a package. But it also has the annoying behavior of creating empty files
because of the typical automake generated Makefile target for info file
build.

Making the buildlink2's makeinfo hiding script only logging an error
and doing 'exit 1' is actually a better tool to spot the need for makeinfo.
2003-06-25 22:48:02 +00:00
seb
5ab8be8066 Introduce a new framework to handle info files, install-info and
makeinfo commands.

The goal of the new framework is twofold:
        - reduce the number of '@exec' and '@unexec' in PLIST by
using INSTALL/DEINSTALL scripts to handle entries addition/removal
Info directory file.
        - achieve lighter dependencies by avoiding unnecessary run-time
dependency on the gtexinfo package and if needed with the help of the
standalone install-info command provided by the recently imported package
pkgtools/pkg_install-info.

A package must be sightly updated to use this new framework and
must define the variable USE_NEW_TEXINFO. This variable will
be removed from the pkgsrc tree when all package would have been
updated.

For details see section 10.24 of Packages.txt, comments in
mk/{texinfo.mk,buildlink2/bsd.buildlink2.mk} and upcoming mail to
<tech-pkg at netbsd dot org>.
2003-06-19 21:41:13 +00:00
jschauma
07aec53fd8 Apply patch by Joachim Koenig-Baltes (joachim at handshake dot de) in
followup to PR pkg/20529:

Some libraries (in this example, a given Linux's native libpthread) don't
come with a version number at all and/or are in fact symlinks.  Test for
this and act accordingly in fake-la.

This allows packages that use pthread to buildlink under various Linuxen.

Should close PR pkg/20529 and PR pkg/21854.  Thanks, Joachim.
2003-06-19 17:20:41 +00:00
jmmv
f1446ddf2b Drop trailing whitespace. Ok'ed by wiz. 2003-05-06 17:40:18 +00:00
agc
8417adcc99 Escape the wrappee name in an error message, since a user faced with an
error message of "Unable to create as wrapper script: no such file" could
get confused.
2003-05-02 08:32:26 +00:00
grant
d07d1b5eb2 typo in comment 2003-04-15 17:28:05 +00:00
grant
2f92f08298 ugh, fix logic in last. 2003-04-15 01:35:59 +00:00
grant
c4097073a3 only create the wrappers for /opt/SUNWspro/bin/{CC,CXX} if we're not
using gcc.

fixes problem on Solaris where building pkgs would use the wrong CC
(eg. CC=gcc) due to the wrappers being in the $PATH first.
2003-04-15 01:33:58 +00:00
jmc
e40703ccee Make sure wrappee is actually a file/link before considering it found.
On solaris for instance if one put /usr/lib in their path before /usr/ccs/bin
it would match /usr/lib/ld rather than /usr/ccs/bin/ld except that
/usr/lib/ld is a directory...
2003-04-11 18:13:09 +00:00
jlam
45373af245 Modify code to produce fake libtool archives to check whether the libraries
named using the shell pattern actually exist.
2003-01-25 07:57:21 +00:00
jlam
69fbe893c6 Strip bare "-L${BUILDLINK_DIR}" (note there is no trailing "/lib") from
dependency_libs definitions in *.lai files.  This should remove another
instance that can cause "buildlink2 leakage" into installed files under
${LOCALBASE}.
2003-01-24 12:09:16 +00:00