Skip to content

Commit 9946ff0

Browse files
author
Keith M Wesolowski
committed
smartos-live#67 Support compiling cpp with gcc.
smartos-live#91 make world fails on trying to include zlib.h OS-1258 Update vim to 7.3 in SmartOS from 7.2 OS-1303 smartos-live src_addon can die OS-1305 illumos-extra should not put libuuid.a into the proto area, ever OS-1309 illumos-extra makefiles need refactoring OS-1311 nspr and openssl create bogus 64-bit links in the proto area
1 parent e146830 commit 9946ff0

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

65 files changed

+4597
-2451
lines changed

.gitignore

+30-32
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
1-
/bash/bash-4.1
1+
/bash/bash-4.1-32
2+
/bind/bind-9.8.0-32
23
/bzip2/bzip2-1.0.6
3-
/bzip2/bzip2-1.0.6-64
4-
/coreutils/coreutils-8.13
5-
/curl/curl-7.21.2
6-
/dialog/dialog-1.1-20111020/
4+
/coreutils/coreutils-8.13-32
5+
/curl/curl-7.21.2-32
6+
/dialog/dialog-1.1-20111020-32
77
/g11n/proto/
88
/g11n/src/lib/iconv/common/amd64/
99
/g11n/src/lib/iconv/common/*.o
@@ -16,44 +16,42 @@
1616
/g11n/src/lib/iconv/utf-8/*.bt
1717
/g11n/src/lib/iconv/utf-8/*.o
1818
/g11n/src/lib/iconv/utf-8/*.so
19-
/gcc/gcc-3.4.3
20-
/gcc/gcc-3.4.3-i386-build
19+
/gcc4/gcc-4.4.4-32
2120
/gcc4/gcc-4.4.4-i386-build
22-
/gcc4/gcc-4.4.4
23-
/gnupg/gnupg-1.4.11
24-
/gtar/tar-1.23
25-
/gzip/gzip-1.3.5
26-
/less/less-436
27-
/libexpat/expat-2.0.1
21+
/gnupg/gnupg-1.4.11-32
22+
/gtar/tar-1.23-32
23+
/gzip/gzip-1.3.5-32
24+
/less/less-436-32
25+
/libexpat/expat-2.0.1-32
2826
/libexpat/expat-2.0.1-64
29-
/libidn/libidn-1.11
27+
/libidn/libidn-1.11-32
3028
/libm/destdir
3129
/libm/statdir
3230
/libm/usr/src/libm/wos/f80387
3331
/libm/usr/src/libm/wos/libmvec
3432
/libm/usr/src/libm/wos64/amd64
3533
/libxml/libxml2-2.7.6
3634
/libxml/libxml2-2.7.6-64
37-
/libz/zlib-1.2.3
35+
/libz/zlib-1.2.3-32
3836
/libz/zlib-1.2.3-64
39-
/ncurses/ncurses-5.7
37+
/ncurses/ncurses-5.7-32
4038
/ncurses/ncurses-5.7-64
41-
/node.js/node-v0.6.17
42-
/nss-nspr/nss-3.12.8
39+
/node.js/node-v0.6.17-32
40+
/nss-nspr/nss-3.12.8-32
4341
/nss-nspr/nss-3.12.8-64
44-
/ntp/ntp-dev-4.2.5p200
45-
/openldap/openldap-2.4.26/
46-
/openssl/openssl-0.9.8o
47-
/openssl/openssl-0.9.8o-64
48-
/pbzip2/pbzip2-1.1.6
49-
/perl/perl-5.12.3
42+
/ntp/ntp-dev-4.2.5p200-32
43+
/openldap/openldap-2.4.26-32
44+
/openssl/openssl-0.9.8w
45+
/openssl/openssl-0.9.8w-64
46+
/pbzip2/pbzip2-1.1.6-32
47+
/perl/perl-5.12.3-32
5048
/proto
51-
/rsync/rsync-3.0.6
52-
/rsyslog/rsyslog-5.8.9
53-
/screen/screen-4.0.3
54-
/socat/socat-1.7.1.3/
55-
/tun/tun-1.1
56-
/uuid/uuid-1.6.2
57-
/vim/vim72
58-
/wget/wget-1.12
49+
/rsync/rsync-3.0.6-32
50+
/rsyslog/rsyslog-5.8.9-32
51+
/screen/screen-4.0.3-32
52+
/socat/socat-1.7.1.3-32
53+
/tun/tun-1.1-64
54+
/uuid/uuid-1.6.2-32
55+
/vim/vim73-32
56+
/wget/wget-1.12-32
5957
/illumos-extra-*.tgz

Makefile

+70-16
Original file line numberDiff line numberDiff line change
@@ -23,29 +23,78 @@
2323
# To build everything just run 'gmake' in this directory.
2424
#
2525

26-
BASE=$(PWD)
27-
DESTDIR=$(BASE)/proto
28-
PATH=$(DESTDIR)/usr/bin:/usr/sfw/bin:/usr/gnu/bin:/opt/local/bin:/sbin:/usr/sbin:/usr/bin:/opt/SUNWspro/bin:/opt/local/bin
29-
SUBDIRS= bash bzip2 coreutils curl dialog g11n gnupg gtar gzip less libexpat \
30-
libidn libm libxml libz ncurses node.js nss-nspr ntp openldap openssl \
31-
pbzip2 perl rsync rsyslog screen socat tun uuid vim wget
26+
BASE = $(PWD)
27+
DESTDIR = $(BASE)/proto
28+
PATH = $(DESTDIR)/usr/bin:/usr/bin:/usr/sbin:/sbin:/opt/local/bin
29+
SUBDIRS = \
30+
bash \
31+
bind \
32+
bzip2 \
33+
coreutils \
34+
cpp \
35+
curl \
36+
dialog \
37+
g11n \
38+
gnupg \
39+
gtar \
40+
gzip \
41+
ipmitool \
42+
less \
43+
libexpat \
44+
libidn \
45+
libm \
46+
libxml \
47+
libz \
48+
ncurses \
49+
node.js \
50+
nss-nspr \
51+
ntp \
52+
openldap \
53+
openssl \
54+
pbzip2 \
55+
perl \
56+
rsync \
57+
rsyslog \
58+
screen \
59+
socat \
60+
tun \
61+
uuid \
62+
vim \
63+
wget
3264

33-
PARALLEL=-j128
65+
STRAP_SUBDIRS = \
66+
cpp \
67+
bzip2 \
68+
libexpat \
69+
libidn \
70+
libm \
71+
libxml \
72+
libz \
73+
nss-nspr \
74+
openssl
3475

35-
NAME=illumos-extra
76+
NAME = illumos-extra
3677

37-
AWK=$(shell (which gawk 2>/dev/null | grep -v "^no ") || which awk)
38-
BRANCH=$(shell git symbolic-ref HEAD | $(AWK) -F/ '{print $$3}')
78+
AWK = $(shell (which gawk 2>/dev/null | grep -v "^no ") || which awk)
79+
BRANCH = $(shell git symbolic-ref HEAD | $(AWK) -F/ '{print $$3}')
3980

4081
ifeq ($(TIMESTAMP),)
41-
TIMESTAMP=$(shell date -u "+%Y%m%dT%H%M%SZ")
82+
TIMESTAMP = $(shell date -u "+%Y%m%dT%H%M%SZ")
4283
endif
4384

44-
GITDESCRIBE=g$(shell git describe --all --long | $(AWK) -F'-g' '{print $$NF}')
45-
TARBALL=$(NAME)-$(BRANCH)-$(TIMESTAMP)-$(GITDESCRIBE).tgz
85+
GITDESCRIBE = \
86+
g$(shell git describe --all --long | $(AWK) -F'-g' '{print $$NF}')
87+
88+
TARBALL = $(NAME)-$(BRANCH)-$(TIMESTAMP)-$(GITDESCRIBE).tgz
4689

4790
all: $(SUBDIRS)
4891

92+
strap: $(STRAP_SUBDIRS)
93+
94+
curl: libz openssl
95+
gzip: libz
96+
node.js: openssl
97+
4998
#
5099
# pkg-config may be installed. This will actually only hurt us rather than help
51100
# us. pkg-config is based as a part of the pkgsrc packages and will pull in
@@ -55,15 +104,20 @@ all: $(SUBDIRS)
55104
# gets appended.
56105
#
57106
$(DESTDIR)/usr/bin/gcc: FRC
58-
cd gcc4; PKG_CONFIG_LIBDIR="" $(MAKE) PARALLEL=$(PARALLEL) DESTDIR=$(DESTDIR) install
107+
(cd gcc4 && \
108+
PKG_CONFIG_LIBDIR="" $(MAKE) DESTDIR=$(DESTDIR) install)
59109

60110
$(SUBDIRS): $(DESTDIR)/usr/bin/gcc
61-
cd $@; PKG_CONFIG_LIBDIR="" $(MAKE) PARALLEL=$(PARALLEL) DESTDIR=$(DESTDIR) install
111+
(cd $@ && \
112+
PKG_CONFIG_LIBDIR="" $(MAKE) DESTDIR=$(DESTDIR) install)
62113

63114
install: $(SUBDIRS) gcc4
64115

116+
install_strap: $(STRAP_SUBDIRS) gcc4
117+
65118
clean:
66-
-for dir in $(SUBDIRS) gcc4; do (cd $$dir; $(MAKE) DESTDIR=$(DESTDIR) clean); done
119+
-for dir in $(SUBDIRS) gcc4; \
120+
do (cd $$dir; $(MAKE) DESTDIR=$(DESTDIR) clean); done
67121
-rm -rf proto
68122

69123
manifest:

Makefile.defs

+109
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,109 @@
1+
#
2+
# CDDL HEADER START
3+
#
4+
# The contents of this file are subject to the terms of the
5+
# Common Development and Distribution License, Version 1.0 only
6+
# (the "License"). You may not use this file except in compliance
7+
# with the License.
8+
#
9+
# You can obtain a copy of the license at COPYING
10+
# See the License for the specific language governing permissions
11+
# and limitations under the License.
12+
#
13+
# When distributing Covered Code, include this CDDL HEADER in each
14+
# file and include the License file at COPYING.
15+
# If applicable, add the following below this CDDL HEADER, with the
16+
# fields enclosed by brackets "[]" replaced with your own identifying
17+
# information: Portions Copyright [yyyy] [name of copyright owner]
18+
#
19+
# CDDL HEADER END
20+
#
21+
# Copyright (c) 2012, Joyent, Inc.
22+
#
23+
24+
BASE = $(PWD)
25+
DESTDIR = $(BASE)/../proto
26+
VER.32 = $(VER)-32
27+
VER.64 = $(VER)-64
28+
29+
PATH = $(DESTDIR)/usr/bin:/usr/bin:/usr/sbin:/sbin:/opt/local/bin
30+
31+
MAKE = gmake
32+
PARALLEL = -j128
33+
GCC = $(DESTDIR)/usr/bin/gcc
34+
GXX = $(DESTDIR)/usr/bin/g++
35+
GCC.64 = $(GCC) -m64
36+
GXX.64 = $(GXX) -m64
37+
38+
SYSINCDIRS = /usr/include
39+
SYSLIBDIRS = /usr/lib /lib
40+
41+
BUILD32 = yes
42+
BUILD64 =
43+
44+
CPPFLAGS = $(SYSINCDIRS:%=-isystem $(DESTDIR)/%)
45+
LDFLAGS = $(SYSLIBDIRS:%=-L$(DESTDIR)/%)
46+
LDFLAGS.64 = $(SYSLIBDIRS:%=-L$(DESTDIR)/%/64)
47+
48+
AUTOCONF_CC = CC="$(GCC)"
49+
AUTOCONF_CXX = CXX="$(GXX)"
50+
AUTOCONF_CC.64 = CC="$(GCC.64)"
51+
AUTOCONF_CXX.64 = CXX="$(GXX.64)"
52+
AUTOCONF_CPPFLAGS = CPPFLAGS="$(CPPFLAGS)"
53+
AUTOCONF_CFLAGS = CFLAGS="$(CFLAGS)"
54+
AUTOCONF_CFLAGS.64 = CFLAGS="$(CFLAGS.64)"
55+
AUTOCONF_LDFLAGS = LDFLAGS="$(LDFLAGS)"
56+
AUTOCONF_LDFLAGS.64 = LDFLAGS="$(LDFLAGS.64)"
57+
AUTOCONF_LIBS = LIBS="$(LIBS)"
58+
AUTOCONF_LIBS.64 = LIBS="$(LIBS.64)"
59+
60+
AUTOCONF_OUT = config.status
61+
AUTOCONF_OUT.32 = $(VER.32)/$(AUTOCONF_OUT)
62+
AUTOCONF_OUT.64 = $(VER.64)/$(AUTOCONF_OUT)
63+
64+
AUTOCONF_PREFIX = /usr
65+
66+
AUTOCONF_ENV = \
67+
PKG_CONFIG_LIBDIR="" \
68+
$(AUTOCONF_CC) \
69+
$(AUTOCONF_CXX) \
70+
$(AUTOCONF_CPPFLAGS) \
71+
$(AUTOCONF_CFLAGS) \
72+
$(AUTOCONF_LDFLAGS) \
73+
$(AUTOCONF_LIBS)
74+
75+
AUTOCONF_ENV.64 = \
76+
PKG_CONFIG_LIBDIR="" \
77+
$(AUTOCONF_CC.64) \
78+
$(AUTOCONF_CXX.64) \
79+
$(AUTOCONF_CPPFLAGS) \
80+
$(AUTOCONF_CFLAGS.64) \
81+
$(AUTOCONF_LDFLAGS.64) \
82+
$(AUTOCONF_LIBS.64)
83+
84+
AUTOCONF_OPTS = \
85+
--prefix=$(AUTOCONF_PREFIX)
86+
87+
AUTOCONF_OPTS.64 = \
88+
$(AUTOCONF_OPTS)
89+
90+
TARBALL = $(VER).tar.gz
91+
TARBALL_COMPRESS = -z
92+
93+
UNPACK_SENTINEL = configure
94+
FROB_SENTINEL.32 = chmod 755 $(VER.32)/$(UNPACK_SENTINEL)
95+
FROB_SENTINEL.64 = chmod 755 $(VER.64)/$(UNPACK_SENTINEL)
96+
97+
PATCHSTRIP = 1
98+
99+
APPLY_PATCHES.32 = \
100+
for p in $(PATCHES); do [ -f "$$p" ] && \
101+
(cd .unpack32/$(VER) && gpatch -p$(PATCHSTRIP) < "../../$$p"); \
102+
done
103+
104+
APPLY_PATCHES.64 = \
105+
for p in $(PATCHES); do [ -f "$$p" ] && \
106+
(cd .unpack64/$(VER) && gpatch -p$(PATCHSTRIP) < "../../$$p"); \
107+
done
108+
109+
.DEFAULT_GOAL = all

Makefile.targ

+78
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,78 @@
1+
#
2+
# CDDL HEADER START
3+
#
4+
# The contents of this file are subject to the terms of the
5+
# Common Development and Distribution License, Version 1.0 only
6+
# (the "License"). You may not use this file except in compliance
7+
# with the License.
8+
#
9+
# You can obtain a copy of the license at COPYING
10+
# See the License for the specific language governing permissions
11+
# and limitations under the License.
12+
#
13+
# When distributing Covered Code, include this CDDL HEADER in each
14+
# file and include the License file at COPYING.
15+
# If applicable, add the following below this CDDL HEADER, with the
16+
# fields enclosed by brackets "[]" replaced with your own identifying
17+
# information: Portions Copyright [yyyy] [name of copyright owner]
18+
#
19+
# CDDL HEADER END
20+
#
21+
# Copyright (c) 2012, Joyent, Inc.
22+
#
23+
24+
all_autoconf: $(BUILD32:yes=all_autoconf_32) $(BUILD64:yes=all_autoconf_64)
25+
26+
all_autoconf_32: $(AUTOCONF_OUT.32)
27+
(cd $(VER.32); env - PATH=$(PATH) $(MAKE) $(PARALLEL) $(OVERRIDES))
28+
29+
all_autoconf_64: $(AUTOCONF_OUT.64)
30+
(cd $(VER.64); env - PATH=$(PATH) $(MAKE) $(PARALLEL) $(OVERRIDES.64))
31+
32+
install_autoconf: $(BUILD32:yes=install_autoconf_32) \
33+
$(BUILD64:yes=install_autoconf_64)
34+
35+
install_autoconf_32: all
36+
mkdir -p $(DESTDIR)
37+
(cd $(VER.32); \
38+
env - PATH=$(PATH) \
39+
$(MAKE) $(install_PARALLEL) DESTDIR=$(DESTDIR) install)
40+
41+
install_autoconf_64: all
42+
mkdir -p $(DESTDIR)
43+
(cd $(VER.64); \
44+
env - PATH=$(PATH) \
45+
$(MAKE) $(install_PARALLEL) DESTDIR=$(DESTDIR) install)
46+
47+
$(AUTOCONF_OUT.32): $(VER.32)/configure
48+
(cd $(VER.32); \
49+
env - PATH=$(PATH) $(AUTOCONF_ENV) \
50+
./configure $(AUTOCONF_OPTS))
51+
52+
$(AUTOCONF_OUT.64): $(VER.64)/configure
53+
(cd $(VER.64); \
54+
env - PATH=$(PATH) $(AUTOCONF_ENV.64) \
55+
./configure $(AUTOCONF_OPTS.64))
56+
57+
$(VER.32)/$(UNPACK_SENTINEL): $(TARBALL)
58+
-rm -rf $(VER.32)
59+
mkdir -p .unpack32
60+
gtar x -C .unpack32 $(TARBALL_COMPRESS) --no-same-owner -f $(TARBALL)
61+
$(APPLY_PATCHES.32)
62+
mv -f .unpack32/$(VER) ./$(VER.32)
63+
-rmdir .unpack32
64+
$(FROB_SENTINEL.32)
65+
touch $(VER.32)/$(UNPACK_SENTINEL)
66+
67+
$(VER.64)/$(UNPACK_SENTINEL): $(TARBALL)
68+
-rm -rf $(VER.64)
69+
mkdir -p .unpack64
70+
gtar x -C .unpack64 $(TARBALL_COMPRESS) --no-same-owner -f $(TARBALL)
71+
$(APPLY_PATCHES.64)
72+
mv -f .unpack64/$(VER) ./$(VER.64)
73+
-rmdir .unpack64
74+
$(FROB_SENTINEL.64)
75+
touch $(VER.64)/$(UNPACK_SENTINEL)
76+
77+
clean:
78+
-rm -rf $(VER) $(VER.32) $(VER.64) .unpack32 .unpack64 $(CLEANFILES)

0 commit comments

Comments
 (0)