static readline libs

OBS-URL: https://build.opensuse.org/package/show/Base:System/bash?expand=0&rev=254
This commit is contained in:
Dr. Werner Fink 2018-02-27 14:38:26 +00:00 committed by Git OBS Bridge
parent 2c1afa84ec
commit 9a131a1247
2 changed files with 34 additions and 4 deletions

View File

@ -1,3 +1,9 @@
-------------------------------------------------------------------
Tue Feb 27 14:26:53 UTC 2018 - werner@suse.de
- Create readline-devel-static package to re-enable static libraries
again (boo#1082913)
------------------------------------------------------------------- -------------------------------------------------------------------
Thu Feb 22 15:10:29 UTC 2018 - fvogt@suse.com Thu Feb 22 15:10:29 UTC 2018 - fvogt@suse.com

View File

@ -44,7 +44,7 @@ Recommends: bash-doc = %bash_vers
Version: 4.4 Version: 4.4
Release: 0 Release: 0
Summary: The GNU Bourne-Again Shell Summary: The GNU Bourne-Again Shell
License: GPL-3.0+ License: GPL-3.0-or-later
Group: System/Shells Group: System/Shells
Url: http://www.gnu.org/software/bash/bash.html Url: http://www.gnu.org/software/bash/bash.html
# Git: http://git.savannah.gnu.org/cgit/bash.git # Git: http://git.savannah.gnu.org/cgit/bash.git
@ -230,7 +230,6 @@ includes history and search functionality.
%package -n readline-devel %package -n readline-devel
Summary: Include Files and Libraries mandatory for Development Summary: Include Files and Libraries mandatory for Development
Group: Development/Libraries/C and C++ Group: Development/Libraries/C and C++
Provides: bash:%{_libdir}/libreadline.a
Version: %{rl_vers} Version: %{rl_vers}
Release: 0 Release: 0
Requires: libreadline7 = %{rl_vers} Requires: libreadline7 = %{rl_vers}
@ -246,6 +245,20 @@ Obsoletes: readline-devel-64bit
This package contains all necessary include files and libraries needed This package contains all necessary include files and libraries needed
to develop applications that require these. to develop applications that require these.
%package -n readline-devel-static
Summary: Static library for Development
Group: Development/Libraries/C and C++
Version: %{rl_vers}
Release: 0
Requires: ncurses-devel
Requires: readline-devel = %{rl_vers}
Recommends: readline-doc = %{rl_vers}
#
%description -n readline-devel-static
This package contains the static library needed
to develop applications that require these.
%package -n readline-doc %package -n readline-doc
Summary: Documentation how to Use and Program with the Readline Library Summary: Documentation how to Use and Program with the Readline Library
Group: System/Libraries Group: System/Libraries
@ -426,7 +439,9 @@ pushd ../readline-%{rl_vers}%{rextend}
LDFLAGS_FOR_BUILD="$LDFLAGS" LDFLAGS_FOR_BUILD="$LDFLAGS"
export CC_FOR_BUILD CFLAGS_FOR_BUILD LDFLAGS_FOR_BUILD CFLAGS LDFLAGS CC export CC_FOR_BUILD CFLAGS_FOR_BUILD LDFLAGS_FOR_BUILD CFLAGS LDFLAGS CC
./configure --build=%{_target_cpu}-suse-linux \ ./configure --build=%{_target_cpu}-suse-linux \
--disable-static \ --enable-static \
--enable-shared \
--enable-multibyte \
--prefix=%{_prefix} \ --prefix=%{_prefix} \
--with-curses \ --with-curses \
--mandir=%{_mandir} \ --mandir=%{_mandir} \
@ -519,6 +534,7 @@ popd
--with-afs \ --with-afs \
$SYSMALLOC \ $SYSMALLOC \
--enable-job-control \ --enable-job-control \
--enable-net-redirections \
--enable-alias \ --enable-alias \
--enable-readline \ --enable-readline \
--enable-history \ --enable-history \
@ -562,7 +578,7 @@ popd
pushd ../readline-%{rl_vers}%{rextend} pushd ../readline-%{rl_vers}%{rextend}
%make_install htmldir=%{_defaultdocdir}/readline \ %make_install htmldir=%{_defaultdocdir}/readline \
installdir=%{_defaultdocdir}/readline/examples installdir=%{_defaultdocdir}/readline/examples
%make_install install-shared libdir=/%{_lib} linkagedir=%{_libdir} %make_install install libdir=/%{_lib} linkagedir=%{_libdir}
rm -rf %{buildroot}%{_defaultdocdir}/bash rm -rf %{buildroot}%{_defaultdocdir}/bash
mkdir -p %{buildroot}%{_defaultdocdir}/bash mkdir -p %{buildroot}%{_defaultdocdir}/bash
chmod 0755 %{buildroot}/%{_lib}/libhistory.so.%{rl_vers} chmod 0755 %{buildroot}/%{_lib}/libhistory.so.%{rl_vers}
@ -573,6 +589,9 @@ pushd ../readline-%{rl_vers}%{rextend}
rm -vf %{buildroot}/%{_lib}/libreadline.so rm -vf %{buildroot}/%{_lib}/libreadline.so
ln -sf /%{_lib}/libhistory.so.%{rl_vers} %{buildroot}/%{_libdir}/libhistory.so ln -sf /%{_lib}/libhistory.so.%{rl_vers} %{buildroot}/%{_libdir}/libhistory.so
ln -sf /%{_lib}/libreadline.so.%{rl_vers} %{buildroot}/%{_libdir}/libreadline.so ln -sf /%{_lib}/libreadline.so.%{rl_vers} %{buildroot}/%{_libdir}/libreadline.so
mv -vf %{buildroot}/%{_lib}/libhistory.a %{buildroot}/%{_libdir}/libhistory.a
mv -vf %{buildroot}/%{_lib}/libreadline.a %{buildroot}/%{_libdir}/libreadline.a
rm -vrf %{buildroot}%{_datadir}/readline/
popd popd
%make_install %make_install
make -C examples/loadables/ install-supported DESTDIR=%{buildroot} libdir=/%{_lib} make -C examples/loadables/ install-supported DESTDIR=%{buildroot} libdir=/%{_lib}
@ -715,6 +734,11 @@ ldd -u -r %{buildroot}/%{_lib}/libreadline.so.* || true
%{_libdir}/libhistory.so %{_libdir}/libhistory.so
%{_libdir}/libreadline.so %{_libdir}/libreadline.so
%files -n readline-devel-static
%defattr(-,root,root)
%{_libdir}/libhistory.a
%{_libdir}/libreadline.a
%files -n readline-doc %files -n readline-doc
%defattr(-,root,root) %defattr(-,root,root)
%doc %{_infodir}/history.info* %doc %{_infodir}/history.info*