Commit graph

369 commits

Author SHA1 Message Date
jlam
fd7633a630 Remove PKG_PHASEs that no longer exist from the various *_PHASE_* lists. 2006-06-06 06:44:01 +00:00
joerg
ef19a5e7db Band-aid for dependency handling due to the stricter rules from the
dependency cookie. We now want all dependencies in the default phase,
since depends is run before/outside real-extract. This can be seen
e.g. by textproc/troffcvt, which has a build dependency in a build
dependency. Discussed and tested with seb@.
2006-06-04 21:04:45 +00:00
reed
a36ea4e941 If USE_ABI_DEPENDS=no, do not add the BUILDLINK_ABI_DEPENDS.$pkg
to BUILD_DEPENDS. (I posted about this to pkgsrc-users on April 14.)
2006-05-06 03:28:44 +00:00
jlam
28856457ab If we can't find the package with pkg_info when computing BUILDLINK_PREFIX,
make the resulting error message more useful for debugging purposes
by including the name of the variable in a null statement that is part
of the command executed.
2006-04-14 16:59:04 +00:00
tron
346770d72d Correct typo in example Makefile snippet. 2006-04-10 12:25:43 +00:00
reed
5abef9be14 Over 1200 files touched but no revisions bumped :)
RECOMMENDED is removed. It becomes ABI_DEPENDS.

BUILDLINK_RECOMMENDED.foo becomes BUILDLINK_ABI_DEPENDS.foo.

BUILDLINK_DEPENDS.foo becomes BUILDLINK_API_DEPENDS.foo.

BUILDLINK_DEPENDS does not change.

IGNORE_RECOMMENDED (which defaulted to "no") becomes USE_ABI_DEPENDS
which defaults to "yes".

Added to obsolete.mk checking for IGNORE_RECOMMENDED.

I did not manually go through and fix any aesthetic tab/spacing issues.

I have tested the above patch on DragonFly building and packaging
subversion and pkglint and their many dependencies.

I have also tested USE_ABI_DEPENDS=no on my NetBSD workstation (where I
have used IGNORE_RECOMMENDED for a long time). I have been an active user
of IGNORE_RECOMMENDED since it was available.

As suggested, I removed the documentation sentences suggesting bumping for
"security" issues.

As discussed on tech-pkg.

I will commit to revbump, pkglint, pkg_install, createbuildlink separately.

Note that if you use wip, it will fail!  I will commit to pkgsrc-wip
later (within day).
2006-04-06 06:21:32 +00:00
hira
ed44db6a86 Fix build of the packages which pass .la files to libtool by relative
path.  This allows to use symbolic linked path as WRKOBJDIR and should
fix PR pkg/31337.
2005-12-09 16:16:41 +00:00
jlam
35be7aab3b If we need imake, then also pull in any other tools that imake needs to
work.
2005-08-10 16:28:59 +00:00
jlam
ca47ca0ada Hardcode a workaround for perl's DynaLoader.a which is definitely a
PIC code archive, but libtool isn't smart enough to realize it.  Munge
the name within cmd-sink-libtool into something that will make libtool
recognize it as a PIC code archive.  We unmunge it in arg-pp-main so
non-libtool wrappers see the right thing.  This let's us use libtool
to link applications with an embedded Perl interpreter.

I feel so dirty...
2005-08-05 19:46:41 +00:00
jlam
40b99e5f80 Tools that are marked with ":pkgsrc" are needed very early on, probably
too early for pkgsrc to adequately cope.  In this case, imake-check.mk
was marking "imake" as a tool that was used to perform some tests.
This was causing xpkgwedge to be unnecessarily marked as a build
dependency since using imake in pkgsrc pretty much requires xpkgwedge.
However, in the case where we are running the "imake checks", we don't
need xpkgwedge around.

Solve this issue by marking all the tools in imake-check.mk with
":pkgsrc", and modify the xpkgwedge dependency test to not care about
"imake:pkgsrc".
2005-07-19 23:01:55 +00:00
jlam
bf9129c41e Drop distinction between PKGSRC_USE_TOOLS and USE_TOOLS by making
PKGSRC_USE_TOOLS go away.  There is now only a single USE_TOOLS variable
that specifies all of the tools we need to build/run the package.
2005-07-15 18:27:48 +00:00
jlam
4149dcc90e We were writing the wrong directory path for the location to the
uninstalled libtool archive in the case where we build it into some
place other than the current directory.  Older versions of libtool
didn't allow you to build a *.la file anywhere other than the current
directory, and libtool-fix-la made use of this assumption in libtool's
behavior.  More recent versions of libtool *do* let you build a *.la
file anywhere you'd like, so instead of blindly assuming it's the
current directory, use the path to the argument of the -o option.
This embeds the proper directory path into the uninstalled libtool
archive.

This has no impact on packages that just build libtool archives into
the current directory.  The packages that *are* impacted are the ones
that:

   (1) pkgsrc converted to use libtool, and,
   (2) build shared libraries that are linked into other things
       as part of the build, and,
   (3) builds the libtool archives in some place other than the
       current directory.
2005-06-22 21:08:37 +00:00
jlam
809759a4de Allow for explicit PREFER.<pkg> settings to override PREFER_NATIVE and
PREFER_PKGSRC.
2005-06-20 05:44:17 +00:00
jlam
b9ac1b57c0 Avoid generating a blank line as the first command of a target as that
isn't understood by some make programs, e.g. /usr/ccs/bin/make.
2005-06-15 17:54:59 +00:00
jlam
08c60ab83d Coalesce the common makefile code in the builtin.mk file that inspect
the X11 distribution using imake into mk/buildlink3/imake-check.mk.
imake-check.mk calls out to a helper shell script mk/buildlink3/imake-check
that generates the required Imakefiles and runs imake.  Remove the
now extraneous builtin-imake.mk files as the builtin.mk files can now
contain the name of the imake symbol to check.
2005-06-03 19:12:49 +00:00
jlam
95fd1f6ec9 Massive cleanup of buildlink3.mk and builtin.mk files in pkgsrc.
Several changes are involved since they are all interrelated.  These
changes affect about 1000 files.

The first major change is rewriting bsd.builtin.mk as well as all of
the builtin.mk files to follow the new example in bsd.builtin.mk.
The loop to include all of the builtin.mk files needed by the package
is moved from bsd.builtin.mk and into bsd.buildlink3.mk.  bsd.builtin.mk
is now included by each of the individual builtin.mk files and provides
some common logic for all of the builtin.mk files.  Currently, this
includes the computation for whether the native or pkgsrc version of
the package is preferred.  This causes USE_BUILTIN.* to be correctly
set when one builtin.mk file includes another.

The second major change is teach the builtin.mk files to consider
files under ${LOCALBASE} to be from pkgsrc-controlled packages.  Most
of the builtin.mk files test for the presence of built-in software by
checking for the existence of certain files, e.g. <pthread.h>, and we
now assume that if that file is under ${LOCALBASE}, then it must be
from pkgsrc.  This modification is a nod toward LOCALBASE=/usr.  The
exceptions to this new check are the X11 distribution packages, which
are handled specially as noted below.

The third major change is providing builtin.mk and version.mk files
for each of the X11 distribution packages in pkgsrc.  The builtin.mk
file can detect whether the native X11 distribution is the same as
the one provided by pkgsrc, and the version.mk file computes the
version of the X11 distribution package, whether it's built-in or not.

The fourth major change is that the buildlink3.mk files for X11 packages
that install parts which are part of X11 distribution packages, e.g.
Xpm, Xcursor, etc., now use imake to query the X11 distribution for
whether the software is already provided by the X11 distribution.
This is more accurate than grepping for a symbol name in the imake
config files.  Using imake required sprinkling various builtin-imake.mk
helper files into pkgsrc directories.  These files are used as input
to imake since imake can't use stdin for that purpose.

The fifth major change is in how packages note that they use X11.
Instead of setting USE_X11, package Makefiles should now include
x11.buildlink3.mk instead.  This causes the X11 package buildlink3
and builtin logic to be executed at the correct place for buildlink3.mk
and builtin.mk files that previously set USE_X11, and fixes packages
that relied on buildlink3.mk files to implicitly note that X11 is
needed.  Package buildlink3.mk should also include x11.buildlink3.mk
when linking against the package libraries requires also linking
against the X11 libraries.  Where it was obvious, redundant inclusions
of x11.buildlink3.mk have been removed.
2005-06-01 18:02:37 +00:00
xtraeme
b433ad3e49 Add BUILTIN_PACKAGES, this will contain all builtin dependencies used
in packages, e.g on my NetBSD system:

$ cd pkgsrc/graphics/gimp && make show-var VARNAME=BUILTIN_PACKAGES
bzip2 heimdal openssl db1 gettext iconv zlib pthread
$

Ok'ed by jlam.
2005-05-24 15:41:05 +00:00
jlam
80f5031e99 Add a new file find-libs.mk that can be included by builtin.mk files
to detect the presence of libraries in the base system.

The input variable is BUILDLINK_FIND_LIBS, which is a list of library
names, e.g. ncurses, iconv, etc., that will be sought in the base
system.  BUILDLINK_LIB_FOUND.<lib> is set to "yes" or "no" depending
on the result of the search.

An example use is:

BUILDLINK_FIND_LIBS:= intl iconv
.include "../../mk/buildlink3/find-libs.mk"
# ${BUILDLINK_LIB_FOUND.intl} and ${BUILDLINK_LIB_FOUND.iconv} are now
# either "yes" or "no".
2005-05-24 03:44:04 +00:00
jlam
0dbd0c0762 Rename MAKE_VARS to MAKEVARS so that it more closely resembles
"MAKEFLAGS".  Both "MAKEVARS" and "MAKEFLAGS" affect the package-level
make process, not the software's own make process.
2005-05-11 22:08:18 +00:00
jlam
03e9337879 Teach bsd.pkg.mk to create a phase-specific "makevars.mk" file that
caches variable definitions that were computed by make.  These variables
are specified by listing them in MAKE_VARS, e.g.,

	.if !defined(FOO)
	FOO!=	very_time_consuming_command
	.endif
	MAKE_VARS+=	FOO

bsd.pkg.mk will include only the one generated during the most recent
phase.  A particular phase's makevars.mk file consists of variable
definitions that are a superset of all of the ones produced in previous
phases of the build.

The caching is useful because bsd.pkg.mk invokes make recursively,
which in the example above has the potential to run the very time-consuming
command each time unless we cause FOO to be defined for the sub-make
processes.  We don't cache via MAKE_FLAGS because MAKE_FLAGS isn't
consistently applied to every invocation of make, and also because
MAKE_FLAGS can overflow the maximum length of a make variable very
quickly if we add many values to it.

One important and desirable property of variables cached via MAKE_VARS
is that they only apply to the current package, and not to any
dependencies whose builds may have been triggered by the current
package.

The makevars.mk files are generated by new targets fetch-vars,
extract-vars, patch-vars, etc., and these targets are built during
the corresponding real-* target to ensure that they are being invoked
with PKG_PHASE set to the proper value.

Also, remove the variables cache file that bsd.wrapper.mk was generating
since the new makevars.mk files provide the same functionality at a
higher level.  Change all WRAPPER_VARS definitions that were used by
the old wrapper-phase cache file into MAKE_VARS definitions.
2005-05-09 05:06:55 +00:00
tv
fe3c1321bf USE_BUILDLINK3 is no longer optional (and cannot be turned off). Per mail
to tech-pkg:

=====

* USE_BUILDLINK3=YES will be unconditional.  (In fact, USE_BUILDLINK3 will
  be ignored altogether by mk/; but see below.)

* NO_BUILDLINK and NO_WRAPPER will be ignored by mk/.  If a build happens,
  these phases will happen.

* The existing NO_BUILD will imply the previous NO_BUILDLINK and NO_WRAPPER.
  If no build happens, those phases are not needed.

* NO_TOOLS will be ignored by mk/.  The tools phase, which provides much
  more than just the C compiler, will always happen regardless of package.
  This will make metapackage builds only slightly slower, in trade for far
  less user error.
2005-03-24 17:46:00 +00:00
seb
8ead146eeb Revert previous. This breaks databases/postgresql74-lib for me on NetBSD
current.
2005-02-17 12:15:44 +00:00
seb
61b849b1a3 Add ${BUILDLINK_VARS} to WRAPPER_VARS.
Since the bsd.wrapper.mk framework was introduced, hence the removal
of BUILDLINK_VARS handling from bsd.buildlink3.mk, none of the variables
listed in BUILDLINK_VARS were "cached" in any way.
2005-02-16 23:08:16 +00:00
jlam
e9eb68750b The libtool wrapper should always do the compiler wrapper transformations,
so move the setting for _WRAP_ARG_PP.LIBTOOL out of conditional areas of
bsd.wrapper.mk and set it globally in bsd.buildlink3.mk with the rest of
the libtool wrapper variables.
2005-02-15 03:18:50 +00:00
wiz
913b2647ad "the the" -> "the" 2004-12-01 09:52:59 +00:00
jlam
eb9034727a Modify the way that the toolchain variables, e.g. CC, CPP, CXX, LD, etc.,
are handled.  The idea now is to simply remove the paths in the values
of these variables, leaving behind only the basename plus any arguments,
e.g.:

	CC= /usr/local/bin/gcc       becomes   CC= gcc
	CPP= /usr/local/bin/gcc -E   becomes   CPP= gcc -E

The wrapper scripts are generated for every unique executable mentioned
by the toolchain variables, so for the example above, only a "gcc"
wrapper script is generated for ${CC} and ${CPP}.  PKG_{CC,CPP,CXX,etc.}
are the paths to the executables wrapped by the wrapper scripts.

Note that it's now possible to set "CC" to something more than just the
path to the compiler, e.g.

	CC= cc -ffast-math -funroll-loops -fomit-frame-pointer

and the full value of ${CC} will be passed through via CONFIGURE_ENV
and MAKE_ENV.
2004-11-30 14:50:37 +00:00
jlam
40377c791f Remove pre-buildlink and post-buildlink as part of getting pkgsrc ready
for pkgsrc-2004Q4.  The "buildlink" phase was removed for the last branch,
and this is the final cleanup.  "post-buildlink" is now "post-wrapper".
2004-11-28 19:19:51 +00:00
jlam
b990d523e9 Generalize BUILDLINK_AUTO_LIBS.<pkg> to BUILDLINK_AUTO_VARS.<pkg>,
which is "yes" or "no" for whether the values of any of
BUILDLINK_{CPPFLAGS,CFLAGS,LDFLAGS,LIBS}.<pkg> should be appended
automatically to their respective variables.
2004-11-17 21:01:00 +00:00
jlam
9418b1ff37 BUILDLINK_AUTO_LIBS.<pkg> is "yes" or "no" for whether BUILDLINK_LIBS.<pkg>
should automatically be appended to LIBS.  It defaults to "yes".
2004-11-17 19:40:35 +00:00
sketch
cc78d56bb6 Introduce LIBABISUFFIX for platforms which require ABI-dependant library paths. 2004-11-12 20:25:41 +00:00
jlam
88b9364ed3 Add a new variable BUILDLINK_LIBS.<pkg> which contains a list of -l...
options (library options) to be appended automatically to LIBS when
building against <pkg>.  LIBS is used by GNU configure scripts to note
the library options that are automatically added to the link command
line.
2004-11-12 04:57:31 +00:00
jlam
45aebed3b7 Allow BUILDLINK_BUILTIN_MK.<pkg> to point to the builtin.mk file for the
specified package.  This defaults to the builtin.mk file in the pkgsrc
package directory.
2004-11-10 17:39:03 +00:00
jlam
087adf00de Move the "dependency reduction" code from buildlink3 to bsd.pkg.mk so
that all of pkgsrc can benefit from removing redundant dependencies.
The code is encapsulated in a new file reduce-depends.mk which is
included by bsd.pkg.mk after all dependencies have been specified.
2004-10-05 15:28:50 +00:00
jlam
b339673bcc When transforming from ${LOCALBASE} into ${BUILDLINK_DIR}, convert
into the mangled name for ${BUILDLINK_DIR} as an intermediate step,
then convert the mangled name into ${BUILDLINK_DIR} at the end.  This
avoids problems with too many substitutions when ${BUILDLINK_DIR} is
a subdirectory of ${LOCALBASE}, as noted in PR pkg/27104.
2004-10-04 17:57:08 +00:00
jlam
5b6ee3d6b7 Don't cache transformations of "-lfoo" into "rel/path/to/libfoo.la" because
"rel/path/to" can be different each time.  This should fix problems with
building transcode after the wrapper framework was integrated.
2004-10-03 21:39:07 +00:00
jlam
4933de09cd G/C _WRAPPER_SH.LIBTOOL which isn't needed (it's value was being
overwritten within bsd.wrapper.mk anyway).  Also fix up the documentation
surrounding that section.  From Stoned Elipot in private email.
2004-09-30 16:34:32 +00:00
jlam
cf55b4e474 Teach the libtool wrapper about the "clean" and "uninstall" modes, where
we don't append the BUIDLINK_LDFLAGS to the commandline.
2004-09-24 20:44:28 +00:00
jlam
6cdf3f2903 Create ${BUILDLINK_DIR}/bin for use by packages that need to drop off a
buildlink wrapper for an installed binary or script.
2004-09-24 16:15:18 +00:00
jlam
bfecc5b0c7 Add a toggle that determines whether we pass extra arguments or not. This
is intended to be toggled by a $scan file.  Simplify buildlink3 by removing
_BLNK_LIBTOOL_LDFLAGS and just setting _WRAP_EXTRA_ARGS.* like all of the
other wrappers.
2004-09-22 17:56:31 +00:00
jlam
1d55af8fb2 Initial commit of a new wrapper script framework that encapsulates
the non-buildlink-related code and moves it out of mk/buildlink3 into
mk/wrapper.  The buildlink3 code is modified to simply hook its
transformations into the wrapper script framework.

The wrapper script framework has some new features:

* Support automatically passing "ABI" flags to the compiler and linker
  depending on the value of ${ABI}.  Currently supports the SunPro
  compiler with ${ABI} == 64 and the MIPSPro compiler with ${ABI} as
  any of 32, n32, o32, and 64.

* making UnixWare GCC accept -rpath options and silently converting
  them into an appropriate LD_RUN_PATH

* Add cmd-sink-interix-gcc and cmd-sink-interix-ld that errors out
  when it sees -fpic/-fPIC and -shared/-Bshareable, respectively
  (requested by <tv>).

* Much improved debugging output.  It's possible to output the wrapper
  work log in-line with normal output by setting WRAPPER_LOG to
  "stderr".

Important differences in behaviour from the old buildlink3 code include:

* Only move the -l options to the end of the command line, leaving the
  -L options in-place.

* Extend the autodetection of the libtool mode to detect "compile" and
  "uninstall".

* Fix problem noted in both PR pkg/24760 and PR pkg/25500, where
  -L/usr/lib/* was being mangled improperly.

* Remove the top-level "buildlink" target; instead, make buildlinking
  occur as part of the "wrapper" target.

* mangle and sub-mangle are only meant to transform directories in
  -I, -L, and rpath options, so remove the lines in
  buildlink3/gen-transform.sh that transformed bare directories.

* Add the ability for the libtool wrapper to be called just to unwrap
  an existing libtool archive by running:

	libtool --mode=unwrap -o libfoo.la

  The old --fix-la syntax no longer works.


20040818
========
* Initial release of a new wrapper script framework that encapsulates
  the non-buildlink-related code and moves it out of mk/buildlink3.
  These features include:

   * making MIPSpro accept GCC options
   * making MIPSpro "ucode" accept GCC options
   * making SunPro accept GCC options
   * making "ld" accept -Wl,* options and silently removing the "-Wl,"
   * (NEW) making UnixWare GCC accept -rpath options and silently
     converting them into an appropriate LD_RUN_PATH

  One major benefit of this is that the buildlink3 code is now much
  tighter and easier to understand since it concerns itself solely
  with buildlink-related details.  I haven't yet optimized the wrapper
  cache, so the new wrapper scripts may take slightly longer to execute
  than the old buildlink3 wrapper scripts, but I'll be improving this
  over time.


20040821
========
* Move the inclusion of $cmd_sink outside of the main loop in wrapper.sh
  so that the $cmd_sink script can be used to globally scan and process
  the arguments.  Move the LD_RUN_PATH code to a cmd-sink-unixware-gcc
  script.  Garbage-collect the now unused export_vars-related code.

* Add cmd-sink-aix-xlc for AIX xlc that munges -Wl,-R* into an
  appropriate -blibpath option.

* Add cmd-sink-interix-gcc and cmd-sink-interix-ld that errors out
  when it sees -fpic/-fPIC and -shared/-Bshareable, respectively
  (requested by <tv>).

* Move the code that converts full paths to shared libraries into the
  "-Ldir -llib" equivalents from the buildlink3 code into wrapper/logic.
  Remove the same from bsd.buildlink3.mk and gen-transform.sh.

* Move the code that checks for absolute rpaths from the buildlink3
  code into wrapper/arg-source.  Remove the same from bsd.buildlink3.mk
  and gen-transform.sh.

* Only move the -l options to the end of the command line, leaving the
  -L options in-place.

* Add more debugging code.


20040824
========
* Fix quoting problems after arguments are transformed.  Remove the
  hack that was inserted that magically made almost everything work
  because we do it the right way now.

* Move the inclusion of $logic outside of the main loop in wrapper.sh
  so that the $logic script doesn't have to worry about underflowing
  the argument buffer.

* Encapsulate the loop in wrapper.sh that fills the argument buffer
  entirely within the arg-source script.

* Move from the logic script into the arg-source script the
  transformations that merge or split arguments.

* Fix bug where skipargs was effectively being ignored if it was more
  than 1.

* Handle the whitespace in transformations in the logic script that
  turn one library option into multiple library options, e.g.
  "-lreadline" -> "-ledit -ltermcap".

* Allow you to specify an environment variable WRAPPER_SKIP_TRANSFORM
  for whether you wish to skip the transformation step in the logic
  script.  This is intended for testing purposes.

* Added check_prog() and init_lib() functions to the shell code library
  to make it more reusable outside of the wrapper framework.

* Allow the msg_log() function to output to "stdout" or "stderr".  If
  you want to have all of the logging appear on the screen, then you
  can now set WRAPPER_LOG=stderr.

* Make some of the script components not overridable on a per-wrapper
  basis.

* Add a gen-transform.sh script that generates transformation sedfiles.
  The "transform" script is used to transform arguments, while the
  "untransform" script is used to unwrap files.  Move the no-rpath
  logic from buildlink3/gen-transform.sh into wrapper/gen-transform.sh
  since it's not buildlink3-specific.

* Check for a non-empty blibpath before adding the option in
  cmd-sink-aix-xlc.

* Extend the autodetection of the libtool mode to detect "compile" and
  "uninstall".

* Add a cmd-sink-libtool script that doesn't pass linker options to
  libtool unless we're in "link" mode.

* Set _USE_RPATH to "yes" for UnixWare so that the wrappers will see the
  rpath options and convert them to a LD_RUN_PATH definition.

* Add more debugging code.


20040826
========
* Rewrite buildlink3/gen-transform.sh to produce more precise sed commands.
  Drop some unused commands from the mini-language, and add a few more
  that are more restrictive in their scope.

* Fix problem where repeated options weren't properly handled by some
  of sed commands.  It's not enough that they're "global replace",
  since some patterns match separator characters before and after each
  option.  We must repeat those patterns twice to catch all instances
  correctly.

* Fix problem noted in both PR pkg/24760 and PR pkg/25500, where
  -L/usr/lib/* was being mangled improperly.

* Remove the top-level "buildlink" target; instead, make buildlinking
  occur as part of the "wrapper" target.

* Add more debugging code.


20040828
========
* Added a head_queue function to shell-lib that returns the head of the
  named queue without popping it off the front of the queue.

* Strip consecutive, repeated library options from the command line when
  we read it in the logic script.

* Be more careful about not underflowing the argument buffer.


20040906
========
* shell-lib was moved into pkgsrc/mk/scripts; correct references to that
  file in the wrapper code.

* Use opt-sub instead of sub-mangle when protecting -I/usr/include/*
  and -L/usr/lib/* from buildlink transformations.  This avoids adding
  lines that look like "-I-I..." in the transformation sedfiles.

* mangle and sub-mangle are only meant to transform directories in
  -I, -L, and rpath options, so remove the lines in
  buildlink3/gen-transform.sh that transformed bare directories.

* Fix bug in strip-slashdot where the "." wasn't backquoted and thus
  matched all characters instead of only the "." character.

* Change the libtool wrapper to use a modified buildcmd script that
  doesn't rearrange any of the arguments.  This should fix spurious
  problems where libtool doesn't understand how to parse the command
  line when the -l options are moved to the end of the argument list.

* Fix bug in the logic script where the $cachearg and $cachedarg
  weren't being properly set at all times, which caused the cache to
  contain the wrong transformed argument.


20040907
========
* Support automatically passing "ABI" flags to the compiler and linker
  depending on the value of ${ABI}.  Currently supports the SunPro
  compiler with ${ABI} == 64 and the MIPSPro compiler with ${ABI} as
  any of 32, n32, o32, and 64.

* Move back the code that splits absolute paths to shared libraries
  from arg-source back into logic.  This allows us to correctly skip
  splitting those paths based on the previous option.  Also add a
  sanity check that the library name in the split argument doesn't
  contain a "/" since shell globs are not as precise as REs.

* Don't transform the path given after --dynamic-linker (used by GNU
  ld for ELF linkage).

* Add the ability for the libtool wrapper to be called just to unwrap
  an existing libtool archive by running:

	libtool --mode=unwrap -o libfoo.la


20040914
========
* Add a loop in libtool-fix-la to ensure that all of the options listed
  in the dependency_libs lines of *.lai files are processed.  This fixes
  a buildlink3 leakage bug.

* Merge the gen-transform.sh scripts between buildlink3 and wrapper and
  place them all in wrapper.  This makes sense since the commands simply
  allow for many types of transformations, which buildlink3 takes
  advantage of, but there is nothing inherently buildlink-ish about
  those commands.

* Don't directly manipulate SUBST_SED.unwrap.  Instead, create the
  value of SUBST_SED.unwrap by combining several other variables
  (currently just _UNWRAP_SED) to ensure that the correct ordering is
  preserved.

* Correct some confusing debugging messages.
2004-09-21 15:01:38 +00:00
jlam
b1d4c9dd68 UNBUILDLINK_{PATTERNS,FILES} are actually no more, so garbage-collec them
and update the documentation.
2004-09-08 08:02:00 +00:00
jlam
0927de52e8 Use UNWRAP_{PATTERNS,FILES} instead of UNBUILDLINK_{PATTERNS,FILES}. This
will help to minimize diffs for packages between the forthcoming
pkgsrc-2004Q3 branch and the HEAD after the integration of the wrapper
script framework.
2004-09-07 00:14:13 +00:00
wiz
a1e9ee2fea Fix typo in comment, reported by Ryo HAYASAKA in PR 26797. 2004-08-29 14:25:10 +00:00
jlam
672b335314 Make "rename" a synonym for "S". 2004-08-28 06:02:21 +00:00
jlam
3fffb3472f Add "rm:opt" as a synonym for "S:opt:", and "rmdir:dir" for "r:dir".
These are supported options from the soon-to-be-committed wrapper
framework and are meant to more precisely state the intended
transformation.  Also just skip over unknown commands instead of
generating an error.
2004-08-28 05:51:30 +00:00
jlam
5c7a0a7938 Restore a default definition for _BLNK_RPATH_FLAGS lost in previous commit. 2004-08-27 08:38:22 +00:00
jlam
ca70938428 Replace RPATH_FLAG with LINKER_RPATH_FLAG and COMPILER_RPATH_FLAG,
which are the full option names used to set rpath directives for the
linker and the compiler, respectively.  In places were we are invoking
the linker, use "${LINKER_RPATH_FLAG} <path>", where the space is
inserted in case the flag is a word, e.g. -rpath.  The default values
of *_RPATH_FLAG are set by the compiler/*.mk files, depending on the
compiler that you use.  They may be overridden on a ${OPSYS}-specific
basis by setting _OPSYS_LINKER_RPATH_FLAG and _OPSYS_COMPILER_RPATH_FLAG,
respectively.  Garbage-collect _OPSYS_RPATH_NAME and _COMPILER_LD_FLAG.
2004-08-27 06:29:06 +00:00
jlam
446886c30e Add ${CAT} as the final pipeline command to BUILDLINK_FILES_CMD.<pkg> so
that the whole pipeline returns 0.  This avoids subtle breakage when the
we use built-in software and there is actually no list of files passed as
input to the pipeline, and the final egrep returns non-zero.
2004-08-13 03:43:23 +00:00
dmcmahill
d7098ab8a2 add some quoting to deal with the case where a file in a package
has a space in the filename.  Without the quoting the buildlink
stage fails completely with errors.  ok'ed by Johnny Lam.
2004-08-13 00:48:05 +00:00
jlam
ec2830a96a Reorder the transformations in _BLNK_TRANSFORM so that commands to
remove rpath options come first.  This fixes problems we may encounter
if ${_OPSYS_RPATH_NAME} is something surprising, like "-L".  On Darwin,
this was causing -L/usr/lib to be stripped out of "-Wl,-L/usr/lib",
which left a bare "-Wl," on the command line.
2004-08-10 15:16:29 +00:00
jlam
dda95b6721 In the rpath transformations, also handle -Wl,@_OPSYS_RPATH_NAME@... in
case ${_OPSYS_RPATH_NAME} is something surprising, like "-L".
2004-08-10 15:13:25 +00:00
jlam
08ffe1eca5 Update documentation for the current state of buildlink3. 2004-07-30 20:52:44 +00:00
xtraeme
9f3bfb4a8f Enable X11_TYPE=xorg now that we have the X.org packages on pkgsrc. 2004-07-29 05:09:29 +00:00
grant
1d8168af4e explicitly don't transform "-Wl,*", fixing a bug that meant we were
throwing away all -W arguments that weren't -Wl,-R.

fixes building of a number of packages on Solaris.
2004-07-10 12:55:08 +00:00
wiz
36ccfca825 Handle --execute the same way as --install (not modifying the arguments).
Needed to convert inputmethods/xcin to bl3. Idea from jlam.
2004-07-04 09:52:04 +00:00
grant
4b6f21b903 transform --export-dynamic to -G and strip -fstrict-prototypes. 2004-07-04 08:30:46 +00:00
grant
ca57d6e396 update the cache for -static 2004-07-03 20:53:59 +00:00
grant
456c546037 fix typo and slight botch up in last 2004-07-03 20:53:47 +00:00
salo
61d3b15bc9 Convert -static to -Bstatic. 2004-07-03 20:39:26 +00:00
xtraeme
d8d555b461 Remove references about BUILDLINK_UPDATE_CACHE in the configure stage,
you could build packages faster right now (yay), I'm using this way
around +2 months ago without any problem.

Ok'ed by jlam@.
2004-06-22 23:23:36 +00:00
grant
9bc788ad87 strip -fno-gnu-keywords argument to SunPro, and munge -pthread into
-lpthread. ok'd by jlam.

addresses PR pkg/24966 from Charlie Allom.
2004-06-13 08:50:15 +00:00
tv
b04b3d3ba0 A couple packages (including the new boost) use "libfoo.so" as a directory
name -- this seems to be common among Jam-using packages.  So, make sure
to do the -L -l transform only if at the end of a word.  This unfortunately
doubles the number of regexes needed to match (one with $_sep, one with $).

While here, though, the expressions for .so, .so.X, .so.X.Y, and .so.X.Y.Z
can all be collapsed into only one set with the use of \(\.[0-9]\)*, so we
actually end up with *less* regexes than before.  :)
2004-06-04 19:21:23 +00:00
jschauma
8196789a05 Append ${ABI} to some lib-dirs. This is a no-op on systems that do not
use ABI, but allows IRIX and particularly IRIX64 to find the correct libraries
especially when linking against X11 libs.  Tested over several months and
multiple bulk-builds.
2004-06-04 15:00:14 +00:00
seb
00cc0486ea Garbage collect BUILDLINK_PKGBASE.<pkg> from buildlink3: it is not anymore
used since revision 1.139 of mk/buildlink3/bsd.buildlink3.mk.
2004-05-17 21:32:33 +00:00
jlam
9dc812c039 libtool archives don't start with '-', so don't match those, which are
probably options to the compiler.
2004-05-17 10:37:57 +00:00
grant
f8cbf47c3e remove a word which shouldn't be there. 2004-05-08 23:46:20 +00:00
minskim
228608ef83 Define BLNK_RECMETHOD.${_pkg_} not only for full dependency but also
for build dependency.  Also fix a related pasto.  This fixes a
malformed conditional error that occurs when a package in build
dependency has BUILDLINK_RECOMMENDED.*.

OK'ed by jmmv@.
2004-04-26 16:27:36 +00:00
jlam
419a7941e9 Don't treat ${BUILDLINK_DIR} like a local directory in the "${WRKSRC} ==
${WRKDIR}" case when converting references to local libtool archives into
the full paths.
2004-04-24 22:04:46 +00:00
minskim
a6b771c787 Create links to .pc files in BUILDLINK_DIR when building a pkgviews
package.  OK'ed by jmmv@.
2004-04-24 15:49:42 +00:00
snj
961fd1293d When substituting the location of a libtool archive, check to make sure
that the new one actually exists.  Fixes PR pkg/25054.
2004-04-22 22:28:19 +00:00
snj
34fe1cb3c3 Symlink *.idl into ${BUILDLINK_DIR}. This is needed for various gnome
packages.
2004-04-18 22:33:06 +00:00
jmmv
ed73278ee0 Let -D flags be passed through the transformation script, so that they
can be easily suppressed/modified from package Makefiles; this is needed
to fix some programs to build against GTK+ 2.4 without having to patch
the sources.
2004-04-15 09:31:48 +00:00
tv
237bbc5d95 Revert the uberdependencies introduced when originally intending to
fix a bug in the way gnome-libs's dependencies work.  This should be
fixed by a mechanism that takes into account exactly how the API
dependencies are structured.

fixes PR pkg/25088 -- and reopens PR pkg/24799
2004-04-12 19:37:03 +00:00
xtraeme
b15072fe03 err BUILDLINK_UPDATE_CACHE should be no for now... sorry I had this change
in my local tree.
2004-04-06 04:39:00 +00:00
xtraeme
703534638e Ensure USE_BUILTIN.<pkg> is defined before checking its value, fixes
last problems seen when using X11_TYPE=XFree86.
2004-04-05 17:00:12 +00:00
jlam
c7be0d97cf Be robust against the possibility that buildlibdir isn't defined. 2004-04-01 21:21:13 +00:00
jlam
ce7bf9c372 Move the check for USE_X11 after bsd.builtin.mk included since that file
may indirectly set USE_X11.  This should fix using some of the builtin
X11 software to build non-X11 packages.
2004-03-31 07:12:31 +00:00
jlam
a87ac65a40 There is no "heimdal-libs" package. 2004-03-30 20:29:54 +00:00
jlam
7783b66d89 Extend the capabilities of buildlink3's libtool wrapper a bit compared
to the stock libtool: you can now copy or symlink an uninstalled
libtool archive file somewhere else than its build directory, and you
can still link against it.  This allows us to more easily bolt libtool
build machinery onto packages that have unusual(ly crappy) build
systems that rely on installing libraries to some common build directory
after they're built.

We do this by adding a "buildlibdir" variable to the uninstalled
libtool archive that points to the build directory of the archive.
Whenever we link against this archive, we rewrite the path to archive
on the libtool command line so that it points to the true archive.
This allows the real libtool to find the files under $buildlibdir/.libs.
2004-03-30 17:25:19 +00:00
jlam
474598e164 Allow setting BUILDLINK_WRAPPER_LOG in /etc/mk.conf and using that as the
log file used by all of the wrapper scripts.
2004-03-29 06:05:10 +00:00
jlam
a0923cb1cf Handle "-Xlinker" being equivalent to "-Wl," when passing arguments
to the linker.  This fixes a bug building Emacs on Linux.
2004-03-29 06:02:53 +00:00
jlam
82cd68d38a Look at the list of run-time dependencies for the package (gleaned
from BUILDLINK_PACKAGES, which is built up by including buildlink[23].mk
files in the package's Makefile), and for each dependency, if it's
already installed, then automatically include the buildlink[23].mk
file for that dependency.

This means that for any package, the dependencies are taken to be the
union of the dependency information as laid out in /usr/pkgsrc and
the dependency information of installed packages stored in /var/db/pkg.

This handle situations where an installed package has _more_ dependencies
than the package as it exists in pkgsrc.  This can occur, e.g., if
you build databases/gnome-libs with BDB_DEFAULT=db4, and then you
decide that you'd rather build other packages using the native Berkeley
DB, so you remove that setting from your environment.  You'd still
like for your packages that depend on gnome-libs to also depend on
db4, but the pkgsrc Makefiles no longer reflect that dependency.
2004-03-29 05:42:58 +00:00
jlam
020b3ec3e2 Make the list of files "buildlinked" be unique for cleanliness' sake. 2004-03-29 05:27:42 +00:00
jlam
d1b4206bba Instead of saving all of the buildlink3 variables into the command-line
environment, it creates a Makefile fragment that is included within
bsd.buildlink3.mk that contains all of the buildlink3 variable
definitions that we want to pass to make(1) invocations on the same
package Makefile.  Change the make variables that are only relevant
for the current package to use BUILDLINK_VARS instead of MAKEFLAGS.
This avoids overflowing the command line with lots of extra arguments.
2004-03-29 05:21:17 +00:00
xtraeme
18a3083bd9 Enable X11_TYPE=XFree86. 2004-03-28 22:25:35 +00:00
jlam
e237ad11d0 Ensure that ${LOCALBASE}/lib is always in the runtime library search path,
even for packages that have no dependencies.
2004-03-26 08:53:01 +00:00
jlam
aa26ea0b16 Move the code that includes the package builtin.mk files into a separate
file, bsd.builtin.mk.  Document the requirements and the recommended
structure of a builtin.mk file in the comments at the top of
bsd.builtin.mk.
2004-03-21 00:03:32 +00:00
jlam
725855d095 Don't match "bin/libtool" and symlink into the buildlink directory if
libtool/buildlink3.mk is included by a package Makefile, as that symlink
overwrites the libtool wrapper script.  This fixes pkg/24851.
2004-03-19 20:27:44 +00:00
danw
bf0551245e add another darwin linker option that needs to be protected from
path munging
2004-03-19 00:04:42 +00:00
jlam
27336df716 Back out part of previous that was an unrelated change accidentally
committed.
2004-03-18 09:22:34 +00:00
jlam
7db11b582a Fix serious bug where BUILDLINK_PACKAGES wasn't being ordered properly
by moving the inclusion of buildlink3.mk files outside of the protected
region.  This bug would be seen by users that have set PREFER_PKGSRC
or PREFER_NATIVE to non-default values.

BUILDLINK_PACKAGES should be ordered so that for any package in the
list, that package doesn't depend on any packages to the left of it
in the list.  This ordering property is used to check for builtin
packages in the correct order.  The problem was that including a
buildlink3.mk file for <pkg> correctly ensured that <pkg> was removed
from BUILDLINK_PACKAGES and appended to the end.  However, since the
inclusion of any other buildlink3.mk files within that buildlink3.mk
was in a region that was protected against multiple inclusion, those
dependencies weren't also moved to the end of BUILDLINK_PACKAGES.
2004-03-18 09:12:08 +00:00
jlam
59bdf89739 If the ${PKGBASE} of a package doesn't match the token passed to
BUILDLINK_PACKAGES, then set BUILDLINK_PKGBASE.<pkg> explicitly so that
we can map from <pkg> to BUILDLINK_PKGBASE.<pkg>.
2004-03-16 18:23:26 +00:00
jlam
fb92616cec Be more permissive in finding libraries to symlink into the buildlink
directory as libraries may be found outside of ${PREFIX}/lib.  We now
match anything that looks like "/lib[^/]*$".
2004-03-16 16:19:37 +00:00
jlam
dbe375ec88 Some of the builtin.mk files append more values to BUILDLINK_PACKAGES, so
make a separate loop to set the default value of USE_BUILTIN.<pkg>.
2004-03-16 02:03:31 +00:00
jlam
62bd2cd672 Add -L${X11BASE}/lib for the benefit of any *-config scripts on
use-xpkgwedge systems.  Not needed when building within pkgsrc, but useful
if you want to link outside 3rd-party software against pkgsrc-controlled
libraries.
2004-03-15 17:55:31 +00:00
jlam
8a2b888017 Back out previous and remove an extra ")" that was causing "malformed
conditional" problems.
2004-03-14 20:27:17 +00:00
jlam
e506d614ce Apparently, some pre-conditions aren't true, so set a default USE_BUILTIN
value before checking it.
2004-03-14 19:04:01 +00:00
jlam
86bb0a15b8 Don't bother checking whether a package is actually built-in or not
in the fall-through code for setting a default value for USE_BUILTIN.<pkg>.
This provides ensures that USE_BUILTIN.<pkg> is always set for every
package listed in BUILDLINK_PACKAGES.  Back out previous as it's now
unneeded.
2004-03-14 18:57:04 +00:00
jmmv
14aa52924a Fix a 'malformed conditional' error. 2004-03-14 12:15:19 +00:00
uebayasi
ac4027935c Indent. 2004-03-13 03:41:13 +00:00
jlam
277b3e1dbb During the "extract" phase (which is when "install-depends" is invoked),
add all of the direct _and_ indirect dependencies to the DEPENDS list.
This causes "install-depends" to check that every dependency, whether
it be direct or indirect, is up-to-date.  This fixes PR 24721 by Jeremy
Reed.
2004-03-13 03:33:31 +00:00
jlam
9eac3f73f0 Ensure that _BLNK_DEPENDS is a subset of _BLNK_PACKAGES. Also rearrange
some code to more easily allow other having different dependency lists for
different phases.
2004-03-12 18:45:20 +00:00
jlam
056d15bbf0 Move a code snippet for easier readability. 2004-03-12 18:03:53 +00:00
jlam
76bf003824 Put comments in order that make sense. 2004-03-12 15:45:43 +00:00
jlam
12d273cd9d Check that a variable is defined before using it.
BUILDLINK_PKGSRCDIR.<pkg> may not be defined since <pkg> may refer to a
dummy package, e.g. "db-native" as set by bdb.buildlink3.mk.
2004-03-11 08:36:41 +00:00
jlam
f755e633c2 X11_TYPE is a user-settable variable that can take the values:
native		use the native, non-pkgsrc-managed X11R6
	XFree86		use x11/XFree86-libs (not yet implemented)
	xlibs		use freedesktop.org xlibs (not yet implemented)

It is used to set the X11 implementation used to build X11 packages.
2004-03-11 06:32:58 +00:00
jlam
c1302f2da6 We can garbage collect USE_X11_LINKS which was used solely to avoid
build loops, which are now handled in a more general way using
IGNORE_PKG.<pkg>.
2004-03-11 05:15:23 +00:00
jlam
088bbd1c66 Avoid build loops by ensuring that a package can never inadvertantly be
a dependency for itself.  This is done by setting IGNORE_PKG.<pkg> if
<pkg> is the current package and then appropriately checking its value.
2004-03-11 05:13:31 +00:00
jlam
a06db92674 Instead of doing a special step to copy the contents of
/usr/pkg/share/x11-links into the buildlink directory, just rely on the
regular buildlink3 infrastructure to do it for us.  This simplifies the
handling of X11 in buildlink3.  The only caveat is that "x11-links"
should appear at the head of BUILDLINK_PACKAGES, and this detail is
handled by x11-links/buildlink3.mk.
2004-03-11 00:54:51 +00:00
jlam
de9a48935b Along with BUILDLINK_INCDIRS.<pkg> and BUILDLINK_LIBDIRS.<pkg>, also have
BUILDLINK_RPATHDIRS.<pkg> which is a list of directories relative to
BUILDLINK_PREFIX.<pkg> to add to the library runtime search path.  For
packages that are a full dependency, this defaults to
BUILDLINK_LIBDIRS.<pkg>, but for packages that are a build dependency,
this defaults to an empty list (on the theory that a build dependency
doesn't have any shared libraries required by the package at runtime).
2004-03-11 00:26:29 +00:00
jlam
463209639c The libtool archive filter was incorrectly eating the closing quote on
the dependency_libs line if it ended in a "-Ldir" option.  Fix by not
eating shell word separators [ \`\"':;,].  This should fix PR 24639 by
Matthias Scheler.
2004-03-10 19:42:27 +00:00
jlam
9d61fef853 Get rid of BUILDLINK_USE_BUILTIN and BUILDLINK_IS_BUILTIN, as they're
renamed to {USE,IS}_BUILTIN and are handled separately by the builtin.mk
files.

Create a new variable PREFER.<pkg> that lets <pkg>/builtin.mk determine
what the preference is in a simple way.
2004-03-10 17:49:26 +00:00
jlam
6d89d6f410 Do previous in a different way by providing a default value for
USE_BUILTIN.<pkg> before it is checked.  _BLNK_PACKAGES isn't strictly
a superset of _BLNK_DEPENDS due to the special x11-links handling
which should eventually be removed altogether.
2004-03-06 14:38:01 +00:00
xtraeme
19638ed9ef Make sure USE_BUILTIN.<pkg> is defined before checking its value. jlam@
seems dead again... so I'll commit this.
2004-03-06 09:46:05 +00:00
jlam
9ff0e10340 Reorder location and setting of BUILDLINK_PACKAGES to match template
buildlink3.mk file in revision 1.101 of bsd.buildlink3.mk.
2004-03-05 19:25:06 +00:00
jlam
07634a03fa Update template bsd.buildlink3.mk file to work with to-be-committed
changes to the buildlink3 framework.  The changes ensure that
BUILDLINK_PACKAGES orders packages so that for any element in the
list, the packages to the right do not depend on any packages to the
left of that element.
2004-03-05 19:09:56 +00:00
jlam
1a98a9895b sjg recommends escaping the bare left curly brace in the make variable
modifer expression.
2004-02-23 09:15:33 +00:00
jlam
00b950724b Back out previous because that brace is not supposed to be there. 2004-02-23 08:58:22 +00:00
dogcow
48adda54db add a missing } to the end of the line; fixes PR/24525. 2004-02-23 08:18:59 +00:00
jlam
65af2d1fe6 According to the documentation on version numbering of shared libraries at:
http://fink.sourceforge.net/doc/porting/shared.php

It's okay to link against a name like "libqt.2.3.0.dylib" using
"-lqt.2.3.0", which means we never need to do anything more than just
strip the trailing ".dylib" from shared library names when converting from
a full path to "-L... -l...".  This should fix PR 24402.
2004-02-19 18:39:27 +00:00
jlam
3d05ef90b1 Use the mipspro-ucode bits if we're using the mipspro-ucode compiler. 2004-02-19 13:17:13 +00:00
jlam
b4081e6300 Resolve ${LOCALBASE} to its phyiscal path and mangle it back into
${LOCALBASE}.  Some packages' configure scripts resolve all paths to
physical paths, and since buildlink3 suppresses references outside of
${LOCALBASE}, it can break the build of those packages.

This should fix the problem noted by Nathan Williams in the thread
titled "x11/tk build failure" at:

	http://mail-index.netbsd.org/tech-pkg/2004/02/17/0004.html
2004-02-19 12:50:47 +00:00
jlam
2a766c79fa Don't spew files in the package directory if the BUILDLINK_DEPENDS.<pkg>
uses {} to list several "or" dependencies.
2004-02-19 07:41:44 +00:00
jlam
5c40aefbbe Output a more informative/desriptive error than:
cd: cd BUILDLINK_PREFIX.foo_not_found

We now say that the package wasn't installed at the time that we were
trying to buildlink its files.
2004-02-18 19:16:52 +00:00
jlam
3bc670ced3 Remove some checks for PREPEND_PATH as we don't need them. 2004-02-18 14:23:42 +00:00
jlam
c40ee95964 * Move pkgsrc/mk/compiler/bsd.compiler.mk to pkgsrc/mk/compiler.mk.
Package Makefiles may now directly include compiler.mk.

* Don't include compiler.mk within bsd.prefs.mk any longer.  It was only
  included for the purposes of defining CC_VERSION.  Packages that want
  to test the value of CC_VERSION should now first include
  "../../mk/compiler.mk".  Any GCC_REQD statements in package Makefiles
  should be set before compiler.mk is included.

* Simpllfy pkgsrc/mk/compiler/*.mk files as a result of not needing to
  be included indirectly by bsd.prefs.mk.  We remove the special handling
  associated with detecting whether the file was included from within
  bsd.prefs.mk.  These files are now much more straightforward to write
  and understand.

* G/C the BSD_PREFS_MK stack mechanism as the only users (compiler/*)
  no longer need it.

* Ensure that directories are prepended to the PATH only from within
  bsd.pkg.mk.
2004-02-18 13:32:38 +00:00
jlam
455aa176d8 Initial support for the MIPSpro ucode compilers found on IRIX 5.3. The
ucode compilers only support building the "o32" ABI.
2004-02-18 11:18:42 +00:00
jlam
990623913c Typo in comment. 2004-02-18 11:10:35 +00:00
jlam
192e73f9e3 Typo in comment. 2004-02-18 05:23:37 +00:00
jlam
bedc09eef8 Require x11-links-0.23 for the correct set of links with XFree86-4.3.x. 2004-02-17 16:56:47 +00:00
jlam
350ca28970 Fix the glob pattern to match >= dependencies correctly. 2004-02-17 16:07:37 +00:00
jlam
50e37dd0bd Do "dependency reduction" where dependency lists of the form "foo>=0.2
foo>=0.3 foo>=0.4" are collapsed into a single "foo>=0.4" dependency.
2004-02-17 14:49:17 +00:00
jlam
bad42f1f3f +less obfuscated errors 2004-02-17 08:59:44 +00:00
grant
1c81e8e6a1 also ignore -pedantic, SunPro doesn't need to be told ;-) 2004-02-16 22:22:38 +00:00
jlam
e95593a479 Symlink any *.pc files into ${BUILDLINK_DIR} for dependencies and force
pkg-config to only look in ${BUILDLINK_DIR}/lib/pkgconfig for *.pc files.
This will correctly hide the presence of software from configure scripts
that query pkg-config for that information.

Idea suggested by Julio M. Merino Vidal.
2004-02-16 21:01:17 +00:00
jlam
2a3f166b38 Add some TODO items for me. 2004-02-16 20:50:50 +00:00
grant
0e24610e47 ignore -ansi, SunPro doesn't need to be told to support ANSI C. 2004-02-16 12:18:15 +00:00
jlam
bacf725a9d Move section that checks for PREFER_PKGSRC a little higher so that it
actually has some effect.
2004-02-16 03:08:52 +00:00
jlam
d48d056fe7 Whitespace nits. 2004-02-15 14:50:11 +00:00
jlam
d859a79bb1 Aside from everything under ${PREFIX}/include, grab all *.h files for
symlinking into ${BUILDLINK_DIR} for a more complete set of headers.
2004-02-15 14:37:00 +00:00
jlam
f9efcd5148 Create wrappers for the compilers for every language supported by the
compiler set.  This will cause the libtool configuration found in several
packages to use the correct C++ compiler even though the package doesn't
use C++.  This was causing bugs when CXXFLAGS contained flags not
understood by the system gcc-2.95.3.
2004-02-15 13:34:33 +00:00
jlam
5dfc302c34 Change "-I dir" to "-Idir" (same for -L/-R) so that the .transform.sed
script will understand these commands.
2004-02-13 16:49:53 +00:00
jlam
4beeebf425 Move a test from the reorderlibs script out to the wrapper scripts for
efficiency reasons.
2004-02-12 20:29:34 +00:00
jlam
bf3e309dc8 Add missing "$" that was causing the reorderlibs script to create a
variable with an exponentially increasing size.  Fixes infinite loop when
building security/cyrus-saslauthd.
2004-02-12 20:20:35 +00:00
jlam
64a361223d Skip the common cache for more options that are only sunpro-cc related. 2004-02-12 10:16:27 +00:00
jlam
c1fa249663 Modify the "no-rpath" to not need a "/" to start the rpath. Also modify
the "r" command to allow paths ending in "/".  This should fix PR 24352.
2004-02-12 08:28:58 +00:00
jlam
09ed136483 Darwin's special GCC also uses -dylib_file and -dylib_install_name in
similar ways to -install_name, and all need the subsequent argument to be
protected from /path/shlib -> -L/path -lshlib transformations.
2004-02-09 04:35:12 +00:00
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