Gentoo Archives: gentoo-commits

From: "Mike Frysinger (vapier)" <vapier@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in app-shells/bash: bash-4.3_rc2.ebuild ChangeLog
Date: Fri, 31 Jan 2014 05:42:15
Message-Id: 20140131054209.2B2132004C@flycatcher.gentoo.org
1 vapier 14/01/31 05:42:09
2
3 Modified: ChangeLog
4 Added: bash-4.3_rc2.ebuild
5 Log:
6 Version bump.
7
8 (Portage version: 2.2.8-r1/cvs/Linux x86_64, signed Manifest commit with key D2E96200)
9
10 Revision Changes Path
11 1.351 app-shells/bash/ChangeLog
12
13 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-shells/bash/ChangeLog?rev=1.351&view=markup
14 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-shells/bash/ChangeLog?rev=1.351&content-type=text/plain
15 diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-shells/bash/ChangeLog?r1=1.350&r2=1.351
16
17 Index: ChangeLog
18 ===================================================================
19 RCS file: /var/cvsroot/gentoo-x86/app-shells/bash/ChangeLog,v
20 retrieving revision 1.350
21 retrieving revision 1.351
22 diff -u -r1.350 -r1.351
23 --- ChangeLog 18 Jan 2014 02:25:19 -0000 1.350
24 +++ ChangeLog 31 Jan 2014 05:42:08 -0000 1.351
25 @@ -1,6 +1,11 @@
26 # ChangeLog for app-shells/bash
27 # Copyright 1999-2014 Gentoo Foundation; Distributed under the GPL v2
28 -# $Header: /var/cvsroot/gentoo-x86/app-shells/bash/ChangeLog,v 1.350 2014/01/18 02:25:19 vapier Exp $
29 +# $Header: /var/cvsroot/gentoo-x86/app-shells/bash/ChangeLog,v 1.351 2014/01/31 05:42:08 vapier Exp $
30 +
31 +*bash-4.3_rc2 (31 Jan 2014)
32 +
33 + 31 Jan 2014; Mike Frysinger <vapier@g.o> +bash-4.3_rc2.ebuild:
34 + Version bump.
35
36 18 Jan 2014; Mike Frysinger <vapier@g.o> bash-3.1_p17.ebuild,
37 bash-3.2_p51.ebuild, bash-4.0_p38.ebuild, bash-4.1_p11.ebuild,
38
39
40
41 1.1 app-shells/bash/bash-4.3_rc2.ebuild
42
43 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-shells/bash/bash-4.3_rc2.ebuild?rev=1.1&view=markup
44 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-shells/bash/bash-4.3_rc2.ebuild?rev=1.1&content-type=text/plain
45
46 Index: bash-4.3_rc2.ebuild
47 ===================================================================
48 # Copyright 1999-2014 Gentoo Foundation
49 # Distributed under the terms of the GNU General Public License v2
50 # $Header: /var/cvsroot/gentoo-x86/app-shells/bash/bash-4.3_rc2.ebuild,v 1.1 2014/01/31 05:42:08 vapier Exp $
51
52 EAPI="1"
53
54 inherit eutils flag-o-matic toolchain-funcs multilib
55
56 # Official patchlevel
57 # See ftp://ftp.cwru.edu/pub/bash/bash-4.2-patches/
58 PLEVEL=${PV##*_p}
59 MY_PV=${PV/_p*}
60 MY_PV=${MY_PV/_/-}
61 MY_P=${PN}-${MY_PV}
62 [[ ${PV} != *_p* ]] && PLEVEL=0
63 patches() {
64 local opt=$1 plevel=${2:-${PLEVEL}} pn=${3:-${PN}} pv=${4:-${MY_PV}}
65 [[ ${plevel} -eq 0 ]] && return 1
66 eval set -- {1..${plevel}}
67 set -- $(printf "${pn}${pv/\.}-%03d " "$@")
68 if [[ ${opt} == -s ]] ; then
69 echo "${@/#/${DISTDIR}/}"
70 else
71 local u
72 for u in ftp://ftp.cwru.edu/pub/bash mirror://gnu/${pn} ; do
73 printf "${u}/${pn}-${pv}-patches/%s " "$@"
74 done
75 fi
76 }
77
78 DESCRIPTION="The standard GNU Bourne again shell"
79 HOMEPAGE="http://tiswww.case.edu/php/chet/bash/bashtop.html"
80 SRC_URI="mirror://gnu/bash/${MY_P}.tar.gz $(patches)"
81 [[ ${PV} == *_rc* ]] && SRC_URI+=" ftp://ftp.cwru.edu/pub/bash/${MY_P}.tar.gz"
82
83 LICENSE="GPL-3"
84 SLOT="0"
85 #KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd"
86 IUSE="afs bashlogger examples mem-scramble +net nls plugins +readline vanilla"
87
88 DEPEND=">=sys-libs/ncurses-5.2-r2
89 readline? ( >=sys-libs/readline-6.2 )
90 nls? ( virtual/libintl )"
91 RDEPEND="${DEPEND}
92 !<sys-apps/portage-2.1.6.7_p1
93 !<sys-apps/paludis-0.26.0_alpha5"
94 # we only need yacc when the .y files get patched (bash42-005)
95 DEPEND+=" virtual/yacc"
96
97 S=${WORKDIR}/${MY_P}
98
99 pkg_setup() {
100 if is-flag -malign-double ; then #7332
101 eerror "Detected bad CFLAGS '-malign-double'. Do not use this"
102 eerror "as it breaks LFS (struct stat64) on x86."
103 die "remove -malign-double from your CFLAGS mr ricer"
104 fi
105 if use bashlogger ; then
106 ewarn "The logging patch should ONLY be used in restricted (i.e. honeypot) envs."
107 ewarn "This will log ALL output you enter into the shell, you have been warned."
108 fi
109 }
110
111 src_unpack() {
112 unpack ${MY_P}.tar.gz
113 cd "${S}"
114 src_prepare
115 }
116
117 src_prepare() {
118 use mem-scramble
119 # Include official patches
120 [[ ${PLEVEL} -gt 0 ]] && epatch $(patches -s)
121
122 # Clean out local libs so we know we use system ones w/releases.
123 if [[ ${PV} != *_rc* ]] ; then
124 rm -rf lib/{readline,termcap}/*
125 touch lib/{readline,termcap}/Makefile.in # for config.status
126 sed -ri -e 's:\$[(](RL|HIST)_LIBSRC[)]/[[:alpha:]]*.h::g' Makefile.in || die
127 fi
128
129 # Avoid regenerating docs after patches #407985
130 sed -i -r '/^(HS|RL)USER/s:=.*:=:' doc/Makefile.in || die
131 touch -r . doc/*
132
133 epatch "${FILESDIR}"/${PN}-4.2-execute-job-control.patch #383237
134 epatch "${FILESDIR}"/${PN}-4.2-no-readline.patch
135
136 epatch_user
137 }
138
139 src_configure() {
140 local myconf=()
141
142 # For descriptions of these, see config-top.h
143 # bashrc/#26952 bash_logout/#90488 ssh/#24762
144 append-cppflags \
145 -DDEFAULT_PATH_VALUE=\'\"/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin\"\' \
146 -DSTANDARD_UTILS_PATH=\'\"/bin:/usr/bin:/sbin:/usr/sbin\"\' \
147 -DSYS_BASHRC=\'\"/etc/bash/bashrc\"\' \
148 -DSYS_BASH_LOGOUT=\'\"/etc/bash/bash_logout\"\' \
149 -DNON_INTERACTIVE_LOGIN_SHELLS \
150 -DSSH_SOURCE_BASHRC \
151 $(use bashlogger && echo -DSYSLOG_HISTORY)
152
153 # Don't even think about building this statically without
154 # reading Bug 7714 first. If you still build it statically,
155 # don't come crying to us with bugs ;).
156 #use static && export LDFLAGS="${LDFLAGS} -static"
157 use nls || myconf+=( --disable-nls )
158
159 # Historically, we always used the builtin readline, but since
160 # our handling of SONAME upgrades has gotten much more stable
161 # in the PM (and the readline ebuild itself preserves the old
162 # libs during upgrades), linking against the system copy should
163 # be safe.
164 # Exact cached version here doesn't really matter as long as it
165 # is at least what's in the DEPEND up above.
166 export ac_cv_rl_version=6.2
167
168 # Force linking with system curses ... the bundled termcap lib
169 # sucks bad compared to ncurses. For the most part, ncurses
170 # is here because readline needs it. But bash itself calls
171 # ncurses in one or two small places :(.
172
173 if [[ ${PV} != *_rc* ]] ; then
174 # Use system readline only with released versions.
175 myconf+=( --with-installed-readline=. )
176 fi
177
178 use plugins && append-ldflags -Wl,-rpath,/usr/$(get_libdir)/bash
179 tc-export AR #444070
180 econf \
181 --with-curses \
182 $(use_with afs) \
183 $(use_enable net net-redirections) \
184 --disable-profiling \
185 $(use_enable mem-scramble) \
186 $(use_with mem-scramble bash-malloc) \
187 $(use_enable readline) \
188 $(use_enable readline history) \
189 $(use_enable readline bang-history) \
190 "${myconf[@]}"
191 }
192
193 src_compile() {
194 src_configure
195 emake || die
196
197 if use plugins ; then
198 emake -C examples/loadables all others || die
199 fi
200 }
201
202 src_install() {
203 emake install DESTDIR="${D}" || die
204
205 dodir /bin
206 mv "${D}"/usr/bin/bash "${D}"/bin/ || die
207 dosym bash /bin/rbash
208
209 insinto /etc/bash
210 doins "${FILESDIR}"/{bashrc,bash_logout}
211 insinto /etc/skel
212 for f in bash{_logout,_profile,rc} ; do
213 newins "${FILESDIR}"/dot-${f} .${f}
214 done
215
216 local sed_args=(
217 -e "s:#${USERLAND}#@::"
218 -e '/#@/d'
219 )
220 if ! use readline ; then
221 sed_args+=( #432338
222 -e '/^shopt -s histappend/s:^:#:'
223 -e 's:use_color=true:use_color=false:'
224 )
225 fi
226 sed -i \
227 "${sed_args[@]}" \
228 "${D}"/etc/skel/.bashrc \
229 "${D}"/etc/bash/bashrc || die
230
231 if use plugins ; then
232 exeinto /usr/$(get_libdir)/bash
233 doexe $(echo examples/loadables/*.o | sed 's:\.o::g') || die
234 insinto /usr/include/bash-plugins
235 doins *.h builtins/*.h examples/loadables/*.h include/*.h \
236 lib/{glob/glob.h,tilde/tilde.h}
237 fi
238
239 if use examples ; then
240 for d in examples/{functions,misc,scripts,scripts.noah,scripts.v2} ; do
241 exeinto /usr/share/doc/${PF}/${d}
242 insinto /usr/share/doc/${PF}/${d}
243 for f in ${d}/* ; do
244 if [[ ${f##*/} != PERMISSION ]] && [[ ${f##*/} != *README ]] ; then
245 doexe ${f}
246 else
247 doins ${f}
248 fi
249 done
250 done
251 fi
252
253 doman doc/*.1
254 dodoc README NEWS AUTHORS CHANGES COMPAT Y2K doc/FAQ doc/INTRO
255 dosym bash.info /usr/share/info/bashref.info
256 }
257
258 pkg_preinst() {
259 if [[ -e ${ROOT}/etc/bashrc ]] && [[ ! -d ${ROOT}/etc/bash ]] ; then
260 mkdir -p "${ROOT}"/etc/bash
261 mv -f "${ROOT}"/etc/bashrc "${ROOT}"/etc/bash/
262 fi
263
264 if [[ -L ${ROOT}/bin/sh ]]; then
265 # rewrite the symlink to ensure that its mtime changes. having /bin/sh
266 # missing even temporarily causes a fatal error with paludis.
267 local target=$(readlink "${ROOT}"/bin/sh)
268 local tmp=$(emktemp "${ROOT}"/bin)
269 ln -sf "${target}" "${tmp}"
270 mv -f "${tmp}" "${ROOT}"/bin/sh
271 fi
272 }
273
274 pkg_postinst() {
275 # If /bin/sh does not exist, provide it
276 if [[ ! -e ${ROOT}/bin/sh ]]; then
277 ln -sf bash "${ROOT}"/bin/sh
278 fi
279 }