commit | author | age
|
11b22b
|
1 |
# |
AP |
2 |
# CDDL HEADER START |
|
3 |
# |
|
4 |
# The contents of this file are subject to the terms of the |
|
5 |
# Common Development and Distribution License (the "License"). |
|
6 |
# You may not use this file except in compliance with the License. |
|
7 |
# |
|
8 |
# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE |
|
9 |
# or http://www.opensolaris.org/os/licensing. |
|
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 usr/src/OPENSOLARIS.LICENSE. |
|
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 |
# |
6a596a
|
21 |
|
11b22b
|
22 |
# |
6a596a
|
23 |
# Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. |
997211
|
24 |
# Copyright (c) 2020, Michal Nowak |
d5f9dc
|
25 |
# Copyright (c) 2021, Andreas Wacknitz |
8a7e34
|
26 |
# Copyright (c) 2022, Niklas Poslovski |
6a596a
|
27 |
# |
MN |
28 |
|
4e2b2b
|
29 |
BUILD_BITS= 64 |
11b22b
|
30 |
include ../../../make-rules/shared-macros.mk |
AP |
31 |
|
|
32 |
COMPONENT_NAME= bash |
8a7e34
|
33 |
COMPONENT_VERSION= 5.2 |
1110bc
|
34 |
COMPONENT_SUMMARY= GNU Bourne-Again shell (bash) |
11b22b
|
35 |
COMPONENT_SRC= $(COMPONENT_NAME)-$(COMPONENT_VERSION) |
6d6546
|
36 |
COMPONENT_PROJECT_URL= https://www.gnu.org/software/bash/ |
11b22b
|
37 |
COMPONENT_ARCHIVE= $(COMPONENT_SRC).tar.gz |
8a7e34
|
38 |
COMPONENT_ARCHIVE_HASH = sha256:a139c166df7ff4471c5e0733051642ee5556c1cc8a4a78f145583c5c81ab32fb |
6903ff
|
39 |
COMPONENT_ARCHIVE_URL= https://ftp.gnu.org/gnu/bash/$(COMPONENT_ARCHIVE) |
03cc90
|
40 |
COMPONENT_FMRI= shell/bash |
AW |
41 |
COMPONENT_CLASSIFICATION= System/Shells |
1110bc
|
42 |
COMPONENT_LICENSE= GPLv3, FDLv1.2 |
11b22b
|
43 |
|
997211
|
44 |
include $(WS_MAKE_RULES)/common.mk |
11b22b
|
45 |
|
AP |
46 |
BASH_PATCHLEVEL=$(shell grep -h "define PATCHLEVEL" $(COMPONENT_DIR)/patches/bash* | nawk '{print $$NF}' | sort -n | tail -1) |
6d6546
|
47 |
ifeq ($(BASH_PATCHLEVEL),) |
AW |
48 |
BASH_PATCHLEVEL=0 |
|
49 |
endif |
d5f9dc
|
50 |
IPS_COMPONENT_VERSION= $(COMPONENT_VERSION).$(BASH_PATCHLEVEL) |
AW |
51 |
HUMAN_VERSION= $(COMPONENT_VERSION).p$(BASH_PATCHLEVEL) |
11b22b
|
52 |
PATCH_LEVEL = 0 |
AP |
53 |
|
6a596a
|
54 |
PKG_PROTO_DIRS += $(COMPONENT_DIR)/files |
11b22b
|
55 |
|
AP |
56 |
CFLAGS += -I/usr/include/ncurses |
|
57 |
|
|
58 |
# configure checks for some functions, but doesn't seem to want to link in |
|
59 |
# the required libraries for them. We avoid linking with libthread.so.1 |
|
60 |
# just because we pass -mt, by explicitly passing -lc. |
|
61 |
LIBS = -lc -lsocket -lgen |
|
62 |
|
|
63 |
# -z redlocsym -- let's shrink the SHT_SYMTAB as much as we can |
|
64 |
LDFLAGS = $(LD_Z_REDLOCSYM) |
|
65 |
|
1110bc
|
66 |
COMPONENT_PREP_ACTION = ( cd $(@D); autoconf -f -i ) |
6d6546
|
67 |
|
AW |
68 |
COMPONENT_POST_INSTALL_ACTION = \ |
|
69 |
( cd $(PROTOUSRSHAREDIR)/locale ; \ |
|
70 |
cp -Rp "en@boldquot" en ; \ |
|
71 |
cp -Rp "en@boldquot" en_CA ; \ |
|
72 |
cp -Rp "en@boldquot" en_GB ) |
11b22b
|
73 |
|
1110bc
|
74 |
CONFIGURE_ENV += LIBS="$(LIBS)" |
AL |
75 |
CONFIGURE_ENV += LD_OPTIONS="-lc -lm -lgen -lsocket -lnsl -lresolv $(LD_Z_IGNORE)" |
11b22b
|
76 |
|
1110bc
|
77 |
CONFIGURE_OPTIONS += --disable-profiling |
AL |
78 |
CONFIGURE_OPTIONS += --disable-strict-posix-default |
|
79 |
CONFIGURE_OPTIONS += --enable-alias |
|
80 |
CONFIGURE_OPTIONS += --enable-arith-for-command |
|
81 |
CONFIGURE_OPTIONS += --enable-array-variables |
|
82 |
CONFIGURE_OPTIONS += --enable-bang-history |
|
83 |
CONFIGURE_OPTIONS += --enable-brace-expansion |
|
84 |
CONFIGURE_OPTIONS += --enable-casemod-attributes |
|
85 |
CONFIGURE_OPTIONS += --enable-casemod-expansions |
|
86 |
CONFIGURE_OPTIONS += --enable-command-timing |
|
87 |
CONFIGURE_OPTIONS += --enable-cond-command |
|
88 |
CONFIGURE_OPTIONS += --enable-cond-regexp |
|
89 |
CONFIGURE_OPTIONS += --enable-coprocesses |
|
90 |
CONFIGURE_OPTIONS += --enable-debugger |
|
91 |
CONFIGURE_OPTIONS += --enable-directory-stack |
|
92 |
CONFIGURE_OPTIONS += --enable-disabled-builtins |
|
93 |
CONFIGURE_OPTIONS += --enable-dparen-arithmetic |
|
94 |
CONFIGURE_OPTIONS += --enable-extended-glob |
|
95 |
CONFIGURE_OPTIONS += --enable-help-builtin |
|
96 |
CONFIGURE_OPTIONS += --enable-history |
|
97 |
CONFIGURE_OPTIONS += --enable-job-control |
|
98 |
CONFIGURE_OPTIONS += --enable-largefile |
|
99 |
CONFIGURE_OPTIONS += --enable-mem-scramble |
|
100 |
CONFIGURE_OPTIONS += --enable-multibyte |
|
101 |
CONFIGURE_OPTIONS += --enable-net-redirections |
|
102 |
CONFIGURE_OPTIONS += --enable-nls |
|
103 |
CONFIGURE_OPTIONS += --enable-process-substitution |
|
104 |
CONFIGURE_OPTIONS += --enable-progcomp |
|
105 |
CONFIGURE_OPTIONS += --enable-prompt-string-decoding |
|
106 |
CONFIGURE_OPTIONS += --enable-readline |
|
107 |
CONFIGURE_OPTIONS += --enable-restricted |
|
108 |
CONFIGURE_OPTIONS += --enable-select |
|
109 |
CONFIGURE_OPTIONS += --enable-separate-helpfiles |
|
110 |
CONFIGURE_OPTIONS += --enable-single-help-strings |
|
111 |
CONFIGURE_OPTIONS += --enable-static-link |
|
112 |
CONFIGURE_OPTIONS += --enable-usg-echo-default=yes |
|
113 |
CONFIGURE_OPTIONS += --enable-xpg-echo-default=yes |
|
114 |
CONFIGURE_OPTIONS += --infodir=$(CONFIGURE_INFODIR) |
|
115 |
CONFIGURE_OPTIONS += --localstatedir=/var |
6d6546
|
116 |
CONFIGURE_OPTIONS += --without-bash-malloc |
1110bc
|
117 |
CONFIGURE_OPTIONS += --with-curses |
AL |
118 |
CONFIGURE_OPTIONS += --with-installed-readline=no |
|
119 |
|
6d6546
|
120 |
COMPONENT_TEST_DIR = $(BUILD_DIR_64) |
AW |
121 |
COMPONENT_TEST_ENV = - $(TEST_PATH) |
|
122 |
# The bash test harness needs the GNU userland utilities |
|
123 |
TEST_PATH = "PATH=$(BUILD_DIR_64):$(GNUBIN):$(USRBINDIR)" |
11b22b
|
124 |
|
6d6546
|
125 |
# Results output is slightly different on Intel vs. SPARC. |
03cc90
|
126 |
#COMPONENT_TEST_MASTER = \ |
6d6546
|
127 |
$(COMPONENT_TEST_RESULTS_DIR)/results-$(MACH).master |
c781d8
|
128 |
|
6d6546
|
129 |
# Bash tests can't pass if they don't have tty available. This script makes |
AW |
130 |
# sure to provide a tty if we are missing one |
|
131 |
COMPONENT_TEST_CMD = $(COMPONENT_DIR)/bash_test_wrapper |
03cc90
|
132 |
COMPONENT_TEST_TRANSFORMS += \ |
AW |
133 |
'-n' \ |
|
134 |
'-e "/run-/p"' \ |
|
135 |
'-e "/Passed/p"' |
6d6546
|
136 |
|
AW |
137 |
# If the tests decided they need to execute itself in screen(1) then move the |
|
138 |
# resulting file to final location where the rest of userland infrastructure |
|
139 |
# will process it. Then remove files from the /tmp folder that have been used. |
|
140 |
COMPONENT_POST_TEST_ACTION += \ |
|
141 |
if [ -e "$(COMPONENT_TEST_DIR)/outfile" ]; then \ |
|
142 |
mv $(COMPONENT_TEST_DIR)/outfile $(COMPONENT_TEST_OUTPUT); \ |
|
143 |
fi && \ |
|
144 |
rm -f /tmp/bashtst* |
c7f5b5
|
145 |
|
6a596a
|
146 |
# Auto-generated dependencies |
6d6546
|
147 |
REQUIRED_PACKAGES += library/ncurses |
012bc4
|
148 |
REQUIRED_PACKAGES += shell/ksh93 |
c7f5b5
|
149 |
REQUIRED_PACKAGES += system/library |