commit | author | age
|
e69410
|
1 |
# |
AP |
2 |
# This file and its contents are supplied under the terms of the |
a14fd0
|
3 |
# Common Development and Distribution License ("CDDL"). You may |
e69410
|
4 |
# only use this file in accordance with the terms of the CDDL. |
AP |
5 |
# |
|
6 |
# A full copy of the text of the CDDL should have accompanied this |
|
7 |
# source. A copy of the CDDL is also available via the Internet at |
|
8 |
# http://www.illumos.org/license/CDDL. |
|
9 |
# |
|
10 |
|
|
11 |
# |
|
12 |
# Copyright 2012, Jon Tibble |
|
13 |
# |
|
14 |
include ../../make-rules/shared-macros.mk |
|
15 |
|
|
16 |
COMPONENT_NAME= illumos-gcc |
|
17 |
COMPONENT_VERSION= 4.4.4 |
|
18 |
COMPONENT_SRC= illumos-gcc-bcf43dd |
|
19 |
COMPONENT_ARCHIVE= $(COMPONENT_SRC).tar.gz |
|
20 |
COMPONENT_ARCHIVE_HASH= sha256:373d39fe19299da26e0a4e124e1a2f97565a2535c8fabf9bd075a0e6fda050e1 |
|
21 |
ILLUMOS_VERSION= gcc-4.4.4-il-3 |
|
22 |
COMPONENT_ARCHIVE_URL= https://github.com/illumos/gcc/tarball/$(ILLUMOS_VERSION) |
|
23 |
|
|
24 |
include $(WS_TOP)/make-rules/prep.mk |
|
25 |
include $(WS_TOP)/make-rules/configure.mk |
|
26 |
include $(WS_TOP)/make-rules/ips.mk |
|
27 |
|
|
28 |
CC_BITS= |
|
29 |
CFLAGS= -g -O2 |
|
30 |
CONFIG_SHELL= /bin/sh |
|
31 |
|
|
32 |
CONFIGURE_PREFIX= /opt/gcc/$(COMPONENT_VERSION) |
|
33 |
|
|
34 |
PARCH = $(MACH:i386=i386-pc) |
|
35 |
GNU_ARCH = $(PARCH:sparc=sparc-sun)-solaris$(SOLARIS_VERSION) |
|
36 |
PKG_MACROS += GNU_ARCH="$(GNU_ARCH)" |
|
37 |
|
|
38 |
# sparc and x86 use different assemblers |
|
39 |
CONFIGURE_OPTIONS.sparc += --without-gnu-as --with-as=/usr/bin/as |
|
40 |
CONFIGURE_OPTIONS.i386 += --with-gnu-as --with-as=/usr/sfw/bin/gas |
|
41 |
|
|
42 |
CONFIGURE_OPTIONS = --prefix=$(CONFIGURE_PREFIX) |
|
43 |
CONFIGURE_OPTIONS += $(CONFIGURE_OPTIONS.$(MACH)) |
|
44 |
CONFIGURE_OPTIONS += --with-ld=/usr/bin/ld |
|
45 |
CONFIGURE_OPTIONS += --without-gnu-ld |
|
46 |
CONFIGURE_OPTIONS += --enable-languages="c,c++,objc" |
|
47 |
CONFIGURE_OPTIONS += --enable-shared |
|
48 |
CONFIGURE_OPTIONS += --with-mpfr-include=/usr/include/mpfr |
|
49 |
CONFIGURE_OPTIONS += --with-gmp-include=/usr/include/gmp |
|
50 |
CONFIGURE_OPTIONS += --with-pkgversion="Illumos $(ILLUMOS_VERSION)" |
|
51 |
CONFIGURE_OPTIONS += --with-bugurl="http://github.com/illumos/gcc/issues" |
|
52 |
|
|
53 |
COMPONENT_BUILD_ENV= SHELL=$(CONFIG_SHELL) CFLAGS="$(CFLAGS)" STAGE1_CFLAGS="$(CFLAGS)" CFLAGS_FOR_TARGET="$(CFLAGS)" |
|
54 |
COMPONENT_BUILD_GMAKE_ARGS= -j8 |
|
55 |
COMPONENT_BUILD_TARGETS= bootstrap |
|
56 |
|
|
57 |
COMPONENT_POST_INSTALL_ACTION= ( \ |
|
58 |
elfedit -e 'dyn:rpath /opt/gcc/4.4.4/lib' $(PROTO_DIR)/opt/gcc/4.4.4/lib/libgomp.so.1 ; \ |
|
59 |
elfedit -e 'dyn:rpath /opt/gcc/4.4.4/lib/amd64' $(PROTO_DIR)/opt/gcc/4.4.4/lib/amd64/libgomp.so.1 ; \ |
|
60 |
elfedit -e 'dyn:rpath /opt/gcc/4.4.4/lib' $(PROTO_DIR)/opt/gcc/4.4.4/lib/libssp.so.0 ; \ |
|
61 |
elfedit -e 'dyn:rpath /opt/gcc/4.4.4/lib/amd64' $(PROTO_DIR)/opt/gcc/4.4.4/lib/amd64/libssp.so.0 ; \ |
|
62 |
elfedit -e 'dyn:rpath /opt/gcc/4.4.4/lib' $(PROTO_DIR)/opt/gcc/4.4.4/lib/libstdc++.so.6 ; \ |
|
63 |
elfedit -e 'dyn:rpath /opt/gcc/4.4.4/lib/amd64' $(PROTO_DIR)/opt/gcc/4.4.4/lib/amd64/libstdc++.so.6 ) |
|
64 |
|
|
65 |
build: $(BUILD_32) |
|
66 |
|
|
67 |
install: $(INSTALL_32) |