Skip to content

Commit 318f58c

Browse files
author
Matthias Koeppe
committed
m4/iconv.m4, config/config.rpath: Import using gnulib-tool --import iconv
1 parent a6e696e commit 318f58c

File tree

5 files changed

+977
-50
lines changed

5 files changed

+977
-50
lines changed

.gitignore

+6-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,12 @@
99
# Autotools generated files
1010
/aclocal.m4
1111
/autom4te.cache/
12-
/config/
12+
/config/install-sh
13+
/config/compile
14+
/config/config.guess
15+
/config/config.sub
16+
/config/install-sh
17+
/config/missing
1318
/config.log
1419
/config.status
1520
/configure

Makefile

+1-1
Original file line numberDiff line numberDiff line change
@@ -167,7 +167,7 @@ distclean: build-clean
167167
# Delete all auto-generated files which are distributed as part of the
168168
# source tarball
169169
bootstrap-clean:
170-
rm -rf config configure build/make/Makefile-auto.in
170+
rm -rf config/install-sh config/compile config/config.guess config/config.sub config/install-sh config/missing configure build/make/Makefile-auto.in
171171
rm -f src/doc/en/installation/*.txt
172172
rm -rf src/doc/en/reference/spkg/*.rst
173173
rm -f environment.yml

bootstrap

+3-48
Original file line numberDiff line numberDiff line change
@@ -33,50 +33,6 @@ PKG=build/pkgs/configure
3333
MAKE="${MAKE:-make}"
3434
CONFVERSION=$(cat $PKG/package-version.txt)
3535

36-
install_config_rpath() {
37-
# The file config.rpath which comes from gettext is supposed to be
38-
# installed by automake, but due to a bug in most distros it is not;
39-
# see https://trac.sagemath.org/ticket/27823#comment:17
40-
#
41-
# Here we need to determine where gettext stores its data files and
42-
# copy config.rpath from there to config/
43-
gettextize="$(command -v gettextize)"
44-
if [ -z "$gettextize" ]; then
45-
echo >&2 "gettext and the gettextize program must be installed and be in"
46-
echo >&2 "your PATH. E.g. Homebrew installs them in /usr/local/opt/gettext/bin."
47-
return 179
48-
fi
49-
eval `sed -n '/^prefix=.*$/p' "$gettextize"`
50-
eval `sed -n '/^datarootdir=.*$/p' "$gettextize"`
51-
eval `sed -n '/^: \${gettext_datadir=.*$/p' "$gettextize"`
52-
53-
if [ -z "$gettext_datadir" ]; then
54-
eval `sed -n '/^gettext_dir=.*$/p' "$gettextize"`
55-
# In older versions (before 2014) this is spelled gettext_dir
56-
# See https://github.com/autotools-mirror/gettext/commit/ff18897068486560e2bb421004cfbd42b7cdd0f8
57-
gettext_datadir="$gettext_dir"
58-
fi
59-
60-
if [ -z "$gettext_datadir" ]; then
61-
echo >&2 "Failed to read the gettext_datadir directory from $gettextize"
62-
echo >&2 "The config.rpath file must manually be copied into config/"
63-
echo >&2 "This file is installed with gettext typically in /usr/share/gettext"
64-
return 179
65-
fi
66-
67-
config_rpath="$gettext_datadir/config.rpath"
68-
if [ ! -f "$config_rpath" ]; then
69-
echo >&2 "Missing $config_rpath file; this indicates a broken gettext install."
70-
return 179
71-
fi
72-
73-
if [ "${BOOTSTRAP_QUIET}" = "no" ]; then
74-
echo "bootstrap:$LINENO: installing 'config/config.rpath'"
75-
fi
76-
cp "$config_rpath" config/
77-
}
78-
79-
8036

8137
bootstrap () {
8238
if [ "${BOOTSTRAP_QUIET}" = "no" ]; then
@@ -160,7 +116,6 @@ SAGE_SPKG_FINALIZE([$pkgname], [$pkgtype], [$SPKG_SOURCE], [$SPKG_TREE_VAR])"
160116
# third, filter, and then swap them back.
161117
./bootstrap-conda && \
162118
src/doc/bootstrap && \
163-
install_config_rpath && \
164119
aclocal -I m4 && \
165120
automake --add-missing --copy build/make/Makefile-auto 3>&1 1>&2 2>&3 \
166121
| sed "${QUIET_SED_FILTER}" 3>&1 1>&2 2>&3 && \
@@ -170,7 +125,7 @@ SAGE_SPKG_FINALIZE([$pkgname], [$pkgtype], [$SPKG_SOURCE], [$SPKG_TREE_VAR])"
170125
case $st in
171126
0) true;; # Success
172127

173-
179|16|63|127) # install_config_rpath failed|no m4 for pkg-config|autotools not installed|or version too old
128+
179|16|63|127) # no m4 for pkg-config|autotools not installed|or version too old
174129
if [ $DOWNLOAD = yes ]; then
175130
echo >&2 "Bootstrap failed, downloading required files instead."
176131
bootstrap_download || exit $?
@@ -182,7 +137,7 @@ SAGE_SPKG_FINALIZE([$pkgname], [$pkgtype], [$SPKG_SOURCE], [$SPKG_TREE_VAR])"
182137
else
183138
verb="upgrade"
184139
fi
185-
echo >&2 "Bootstrap failed. Either $verb autotools and gettext; or run bootstrap with"
140+
echo >&2 "Bootstrap failed. Either $verb autotools; or run bootstrap with"
186141
echo >&2 "the -d option to download the auto-generated files instead."
187142

188143
SYSTEM=$(build/bin/sage-guess-package-system)
@@ -243,7 +198,7 @@ save () {
243198
mkdir -p upstream
244199
tar zcf "$NEWCONFBALL" \
245200
configure \
246-
config/* \
201+
config/install-sh config/compile config/config.guess config/config.sub config/install-sh config/missing \
247202
build/make/Makefile-auto.in \
248203
src/doc/en/installation/*.txt \
249204
src/doc/en/reference/spkg/*.rst \

0 commit comments

Comments
 (0)