Commit graph

185 commits

Author SHA1 Message Date
joerg
cb1ac20e13 Further refine AIX support. From Jens Rehsack. 2009-01-09 11:46:34 +00:00
joerg
e5d0951320 Fix misbalanced brackets as noticed by jnemeth. 2008-12-29 21:26:55 +00:00
joerg
709d52f492 Improve AIX/XLC support:
- provide cpp wrapper using cc -E
- provide c++_r wrapper working like c++
- provide -rpath handling for cc
- fix some debug messages to provide the correct script name
2008-12-29 16:53:06 +00:00
joerg
b5fd177ee1 Adjust xlc_r check to actually look for the right binary.
Prefer xlc_r over cc_r as authoritive name. Export CC_R.
From Jens Rehstack.
2008-11-27 17:56:52 +00:00
ahoka
f4426ff657 Don't try to build gcc2 on AMD64, as it's not supported by that compiler.
This issue was reported by Daniel Horecki.
2008-11-16 17:01:53 +00:00
joerg
07e7458998 Improve AIX/XLC support based on discussions with Jens Rehsack:
- Add cc_r/xlc_r wrapper using the same rules as xlc itself.
  It is used for example by Perl.
- Improve the RPATH emulation:
  - Always set -blibpath, use /usr/lib:/lib as default
  - If -blibpath is exlicitly given, add to the default
  - Additionally append any -Wl,-rpath given.
2008-11-14 14:04:12 +00:00
rillig
ec31b10111 Added the list of variables, so that "bmake show-all-gcc" shows all the
internals of this file.
2008-09-16 15:02:55 +00:00
sketch
a0c131c7aa Sun Studio 12 has a generic -m64 flag rather than individual -xarch targets. 2008-06-17 11:23:48 +00:00
obache
442d2697d6 Suppress automatical addition c to USE_LANGUAGES (ref. PR 34079)
if F2C does not really required.

Fixes problem mentioned in PR 38626.
2008-05-24 07:27:11 +00:00
rillig
3e67327748 Replaced _PKG_SILENT and _PKG_DEBUG with RUN.
XXX: Why do we have the exactly same code in all the files?
2008-02-07 20:59:05 +00:00
tnn
ddfd411544 Always tell the C++ compiler that we want support for ANSI C++ features
like namespace std enabled.
2008-01-15 10:08:18 +00:00
rhaen
9075c9986b Solaris SunPro Compiler 11/12 fails on Solaris 8/9 with -xc99. The header files supplied by the OS are not c99 aware, the manpage suggests the setting: -xc99=all,no_lib for Solaris 8/9.
See PR 37200
2007-11-30 16:55:28 +00:00
rillig
7a16551a71 Added the variable CCACHE_BASE, so that a ccache other than the one
installed by devel/ccache can be used. This is especially important for
cross-builds.

Documented IGNORE_CCACHE.

Fixed the double use of the directory ${WRKDIR}/.ccache, which was used
both as wrapper directory and as cache directory.
2007-10-16 09:33:29 +00:00
rillig
8832ece985 Added lots of XXX that should be cleaned up when the compiler framework
is rewritten the next time.
2007-10-05 22:09:09 +00:00
reed
edb3562456 For Portable C Compiler.
Add beginning of PKGSRC_COMPILER=pcc support.
Based on "sunpro".

Please help improve this. I have not tested with C++ or fortan.
2007-09-18 01:51:10 +00:00
joerg
1871076e0c At least with XLC V9, xlc -V isn't that useful as it prints the
man page. Use -qversion instead.
2007-08-30 21:47:29 +00:00
joerg
0094e01f2c Provide _COMPILER_RPATH_FLAG and _LINKER_RPATH_FLAG. This should work
at the very least with AIX 5.3 directly and for older, wrapper should
take care.

Provide some more sane defaults for XLC and bail out explicitly if
XLCBASE can't be determined.
2007-08-15 21:26:28 +00:00
joerg
f24acb4a25 When calling gcc to extract the version number, pass down
ALL_ENV as well. This ensures that any locale settings are
overridden and the output matches what pkgsrc expects.

This should fix some of the strange bootstrap issues seen over
time that were seemingly fxied by USE_NATIVE_GCC=yes.
2007-08-11 17:31:22 +00:00
joerg
005620851f Add core of the infrastructure support for cross-compilation.
- USE_CROSS_COMPILATION activates it, CROSS_DESTDIR specifies root of
  the target filesystem
- derive _CROSS_DESTDIR from CROSS_DESTDIR or MAKEOBJDIR
- buildlink3.mk prefixes the files to symlink with _CROSS_DESTDIR
- compiler/gcc.mk knows about the target prefix (e.g. i386--netbsdelf)
- PKG_DBDIR is prefixed with _CROSS_DESTDIR
- package-install and bin-install are not called with su
- install and strip are redirected to the tool version
- links for the target specific ar, as, ld, nm, objdump, ranlib and
  strip are added
- compiler wrapper detect if linking is requested or not
- special command sinks for CPP and CC/CXX add the cross-compile magic:
  - modify include dirs to get the target /usr/include
  - modify linker dirs and runpath to use target /usr/lib at link time,
    but keep correct rpath entries

Supported-by: Google SoC 2007
Basic tests by he@ on Sparc. Review from jlam@.
2007-08-02 18:19:31 +00:00
martti
5867247b54 Remove trailing spaces. 2007-05-28 11:07:00 +00:00
sketch
aa1c561a73 Add C99 support, required for packages which use C99 such as devel/glib2 2007-05-23 08:42:36 +00:00
tnn
1a639746d4 fix botched $NetBSD$ 2007-04-17 11:09:28 +00:00
tnn
409fd2c40a add support for the HP-UX C/aC++ compilers 2007-04-17 11:05:33 +00:00
rillig
34cbf0da37 _COMPILER_LD_FLAG is only used in this file, and no other compiler file
defines this variable, so it doesn't hurt to remove it.
2007-03-15 22:33:42 +00:00
rillig
0bb5c89c69 Removed unused variables. Note that _ALIASES.* could only be removed
because all the alias names are covered by _WRAP_ALIASES.*.

Slowly this file becomes as short and simple as it should have always
been.
2007-03-09 10:58:20 +00:00
rillig
137f973134 Removed the creation of the extra wrapper directory WRKDIR/.sunpro and
everything that is related to it.

The wrappers in WRKDIR/.wrapper now call the compilers in SUNWSPROBASE
directly. The aliases that have been provided had never been called
because WRKDIR/.wrapper was earlier in the PATH and already called the
canonical compiler (for example, .wrapper/gcc called .sunpro/cc, not
.sunpro/gcc).

Also removed the comments related to f2c. We have a version control
system to keep outdated code, so why keep it in the current source?
2007-03-09 10:29:29 +00:00
rillig
a74015f852 Rewrote the file so that it is easier to see what needs to be done when
adding a language.
2007-03-09 09:59:21 +00:00
rillig
17d32cd56b Make the #error directive an error with MIPSpro. 2007-03-07 01:37:18 +00:00
rillig
f6a8043bf5 Replaced the deprecated PKG_SKIP_REASON with PKG_FAIL_REASON. 2007-02-10 08:59:07 +00:00
dmcmahill
5e003ae099 when using sunpro, go ahead and use the sun fortran compiler insted of f2c. The former seems to work as well or better 2007-01-16 17:16:24 +00:00
dmcmahill
b08bdfa69e alias f2c-f77 as g77 as well as f77 and f2c-f77. libtool cares. 2007-01-16 17:16:20 +00:00
gavan
5d1e177d2f gcc2 does not support -std=c99. If c99 is needed, require
at least gcc 3.0.
2007-01-08 19:29:45 +00:00
martti
2cc4216d5e Remove trailing spaces. 2006-12-15 12:46:23 +00:00
joerg
2284bed722 Don't force strict C99 mode by default, but the relaxed GNU-C99 mode. 2006-12-06 16:18:19 +00:00
jschauma
721b60b433 Instead of setting compiler flags in each package if it uses C99,
allow USE_LANGUAGES+=c99 and let gcc and mipspro do the right thing.
May need to be reviewed/added for other compilers.
ok rillig@
2006-12-02 22:32:59 +00:00
rillig
4b4898f8a7 Added header comments. 2006-10-22 00:14:17 +00:00
rillig
701b7f3fd7 Added the user-settable variable CCACHE_DIR, so that the cache can be
outside of WRKDIR. I don't see a reason for having the cache inside a
directory that will go away on "make clean", but I left the default
value as is.
2006-10-14 08:59:08 +00:00
schwarz
ff389f044d CPP on IRIX 5 with IDO cc is /usr/lib/cpp 2006-08-06 18:59:41 +00:00
rillig
5092ccdc95 Whenever f2c is mentioned in USE_LANGUAGES, a C compiler is also needed,
so automatically add it to USE_LANGUAGES. Fixes PR 34079.
2006-07-25 10:20:03 +00:00
jlam
7d1f4cca8e "BUILD_ENV" was misnamed. It's actually the environment that is passed
to all internal recursive make processes.  As such, rename it to
"PKGSRC_MAKE_ENV".

XXX Note, some of the usage of this variable in package Makefiles seems
XXX incorrect.  They probably want "MAKE_ENV", which is the environment
XXX passed to the make process when running "make" within ${WRKSRC}.
2006-07-21 14:27:56 +00:00
markd
5c5f253ff0 On Solaris set _COMPILER_ABI_FLAG.64 to be consistent with the sunpro
settings.
2006-07-06 11:48:03 +00:00
markd
42e8e95800 Set _COMPILER_ABI_FLAG.64 correctly for non sparc (ie amd64). 2006-07-06 11:46:33 +00:00
shannonjr
0faa421404 Change _GCC_DIST_VERSION from 3.4.5 to 3.4.6 to reflect update to
lang/gcc34.
2006-04-05 12:31:24 +00:00
shannonjr
b9b7e90faa Bump '_GCC_DIST_VERSION' to '3.4.5' to match lang/gcc34 2006-02-10 11:26:41 +00:00
schwarz
a315454cc6 added missing header lines. 2005-10-30 10:33:23 +00:00
schwarz
7e79f31cbf added support for the SGI IDO (IRIX Development Option) cc used by IRIX 5.3.
changes approved by jschauma and recht.
2005-10-16 19:44:44 +00:00
grant
aa28d4e53a some packages expect "-Wl," immediately before flags to be passed to
the linker, set _COMPILER_RPATH_FLAG accordingly. "-Wl," is removed by
the sunpro compiler wrapper where necessary.

fix comment for _LINKER_RPATH_FLAG while here.

this fixes, among other things, apache modules built with apxs.
2005-07-21 01:36:25 +00:00
shannonjr
671529f3f6 Updated _GCC_DIST_VERSION from 3.4.3 to 3.4.4 to reflect recent update
to lang/gcc34.
2005-05-31 10:51:36 +00:00
rillig
e251db98e2 The sunpro wrapper now creates aliases for gcc and g++, too. This is needed
because the <sys.mk> Makefile fragment sets CC?=gcc.
2005-05-17 19:06:21 +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