Run spec-beautifier
OBS-URL: https://build.opensuse.org/package/show/X11:common:Factory/icu?expand=0&rev=44
This commit is contained in:
parent
19a13e1ea4
commit
11fd60bc4f
156
icu.spec
156
icu.spec
@ -25,8 +25,8 @@ Summary: International Components for Unicode
|
|||||||
License: MIT
|
License: MIT
|
||||||
Group: Development/Libraries/C and C++
|
Group: Development/Libraries/C and C++
|
||||||
Url: http://icu-project.org/
|
Url: http://icu-project.org/
|
||||||
Source: http://download.icu-project.org/files/icu4c/%version/icu4c-%{aversion}-src.tgz
|
Source: http://download.icu-project.org/files/icu4c/%version/icu4c-%aversion-src.tgz
|
||||||
Source2: http://download.icu-project.org/files/icu4c/%version/icu4c-%{aversion}-docs.zip
|
Source2: http://download.icu-project.org/files/icu4c/%version/icu4c-%aversion-docs.zip
|
||||||
Source3: sanitize_docs.sh
|
Source3: sanitize_docs.sh
|
||||||
Patch1: icu-rpmlint.diff
|
Patch1: icu-rpmlint.diff
|
||||||
Patch2: icu-remove-datetime.patch
|
Patch2: icu-remove-datetime.patch
|
||||||
@ -49,28 +49,28 @@ line, and sentence breaking, etc.
|
|||||||
|
|
||||||
This subpackage contains the runtime programs for interacting with ICU.
|
This subpackage contains the runtime programs for interacting with ICU.
|
||||||
|
|
||||||
%package -n %{lname}
|
%package -n %lname
|
||||||
Summary: International Components for Unicode
|
Summary: International Components for Unicode
|
||||||
Group: System/Libraries
|
Group: System/Libraries
|
||||||
Requires: libicu%{aversion}-data
|
Requires: libicu%aversion-data
|
||||||
Requires: timezone
|
Requires: timezone
|
||||||
# Following O/P added in timeframe for 12.2
|
# Following O/P added in timeframe for 12.2
|
||||||
Provides: libicu = %{version}
|
Provides: libicu = %version
|
||||||
Obsoletes: libicu < %{version}
|
Obsoletes: libicu < %version
|
||||||
|
|
||||||
%description -n %{lname}
|
%description -n %lname
|
||||||
ICU is a set of C and C++ libraries that provides robust and
|
ICU is a set of C and C++ libraries that provides robust and
|
||||||
full-featured Unicode support. This package contains the runtime
|
full-featured Unicode support. This package contains the runtime
|
||||||
libraries for ICU which include precompiled locale data.
|
libraries for ICU which include precompiled locale data.
|
||||||
|
|
||||||
%package -n libicu%{aversion}-data
|
%package -n libicu%aversion-data
|
||||||
Summary: International Components for Unicode
|
Summary: International Components for Unicode
|
||||||
Group: System/Libraries
|
Group: System/Libraries
|
||||||
%if 0%{?suse_version} >= 1210
|
%if 0%{?suse_version} >= 1210
|
||||||
BuildArch: noarch
|
BuildArch: noarch
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
%description -n libicu%{aversion}-data
|
%description -n libicu%aversion-data
|
||||||
ICU is a set of C and C++ libraries that provides robust and
|
ICU is a set of C and C++ libraries that provides robust and
|
||||||
full-featured Unicode support. This package contains the runtime
|
full-featured Unicode support. This package contains the runtime
|
||||||
libraries for ICU which include precompiled locale data.
|
libraries for ICU which include precompiled locale data.
|
||||||
@ -81,7 +81,7 @@ most of the locale-specific information.
|
|||||||
%package -n libicu-devel
|
%package -n libicu-devel
|
||||||
Summary: International Components for Unicode (development files)
|
Summary: International Components for Unicode (development files)
|
||||||
Group: Development/Libraries/C and C++
|
Group: Development/Libraries/C and C++
|
||||||
Requires: %{lname} = %{version}
|
Requires: %lname = %version
|
||||||
|
|
||||||
%description -n libicu-devel
|
%description -n libicu-devel
|
||||||
ICU is a C++ and C library that provides robust and full-featured
|
ICU is a C++ and C library that provides robust and full-featured
|
||||||
@ -98,7 +98,7 @@ Unicode support. This package contains the html documentation.
|
|||||||
%package data
|
%package data
|
||||||
Summary: International Components for Unicode (Sources for the Data in ICU)
|
Summary: International Components for Unicode (Sources for the Data in ICU)
|
||||||
Group: System/Libraries
|
Group: System/Libraries
|
||||||
Requires: %{lname} >= %{version}
|
Requires: %lname >= %version
|
||||||
|
|
||||||
%description data
|
%description data
|
||||||
ICU is a C++ and C library that provides robust and full-featured
|
ICU is a C++ and C library that provides robust and full-featured
|
||||||
@ -115,14 +115,14 @@ This package contains uncompiled source data.
|
|||||||
# docs are special
|
# docs are special
|
||||||
mkdir html
|
mkdir html
|
||||||
cd html
|
cd html
|
||||||
unzip %{SOURCE2}
|
unzip %SOURCE2
|
||||||
cd ..
|
cd ..
|
||||||
|
|
||||||
%patch -P 1 -P 2 -P 3 -P 4 -p1
|
%patch -P 1 -P 2 -P 3 -P 4 -p1
|
||||||
|
|
||||||
%build
|
%build
|
||||||
cd source
|
cd source
|
||||||
export CXXFLAGS="%{optflags} -DICU_DATA_DIR=\\\"%{_datadir}/icu/%{version}/\\\""
|
export CXXFLAGS="%optflags -DICU_DATA_DIR=\\\"%_datadir/icu/%version/\\\""
|
||||||
export CFLAGS="$CXXFLAGS"
|
export CFLAGS="$CXXFLAGS"
|
||||||
%configure \
|
%configure \
|
||||||
--disable-static \
|
--disable-static \
|
||||||
@ -132,21 +132,21 @@ export CFLAGS="$CXXFLAGS"
|
|||||||
make %{?_smp_mflags} VERBOSE=1
|
make %{?_smp_mflags} VERBOSE=1
|
||||||
|
|
||||||
%install
|
%install
|
||||||
mkdir -p "%{buildroot}/%{_docdir}/%{name}"
|
mkdir -p "%buildroot/%_docdir/%name"
|
||||||
cp -a html "%{buildroot}/%{_docdir}/%{name}/"
|
cp -a html "%buildroot/%_docdir/%name/"
|
||||||
cp -a license.html readme.html "%{buildroot}/%{_docdir}/%{name}/"
|
cp -a license.html readme.html "%buildroot/%_docdir/%name/"
|
||||||
|
|
||||||
find . -name CVS -type d -exec rm -Rf "{}" "+"
|
find . -name CVS -type d -exec rm -Rf "{}" "+"
|
||||||
cd source
|
cd source
|
||||||
|
|
||||||
make install DESTDIR="%{buildroot}"
|
make install DESTDIR="%buildroot"
|
||||||
|
|
||||||
#
|
#
|
||||||
# ICU's "pkgdata" utility is really fragile, so icu-versioning.diff
|
# ICU's "pkgdata" utility is really fragile, so icu-versioning.diff
|
||||||
# does as few as possible, but that means we need some additional
|
# does as few as possible, but that means we need some additional
|
||||||
# cleanup in the spec file now.
|
# cleanup in the spec file now.
|
||||||
#
|
#
|
||||||
pushd "%{buildroot}/%{_libdir}/"
|
pushd "%buildroot/%_libdir/"
|
||||||
for i in *.so.[0-9]*; do
|
for i in *.so.[0-9]*; do
|
||||||
echo "Looking at $i"
|
echo "Looking at $i"
|
||||||
if [ "${i##*.so.}" != "%version" ]; then
|
if [ "${i##*.so.}" != "%version" ]; then
|
||||||
@ -155,22 +155,22 @@ for i in *.so.[0-9]*; do
|
|||||||
fi
|
fi
|
||||||
# Because U_ICU_VERSION_SHORT is "51_2" and not "51.2",
|
# Because U_ICU_VERSION_SHORT is "51_2" and not "51.2",
|
||||||
# create some symlinks.
|
# create some symlinks.
|
||||||
ln -s "$i" "${i%%%version}%{aversion}"
|
ln -s "$i" "${i%%%version}%aversion"
|
||||||
done
|
done
|
||||||
popd
|
popd
|
||||||
|
|
||||||
# /usr/lib/rpm/elfdeps requires +x bit and not all had it at one point
|
# /usr/lib/rpm/elfdeps requires +x bit and not all had it at one point
|
||||||
chmod a+rx "%{buildroot}/%{_libdir}"/lib*.so.*
|
chmod a+rx "%buildroot/%_libdir"/lib*.so.*
|
||||||
|
|
||||||
# install uncompiled source data:
|
# install uncompiled source data:
|
||||||
mkdir -p "%{buildroot}/%{_datadir}/icu/%{version}/unidata"
|
mkdir -p "%buildroot/%_datadir/icu/%version/unidata"
|
||||||
install -m 644 data/unidata/*.txt "%{buildroot}/%{_datadir}/icu/%{version}/unidata"
|
install -m 644 data/unidata/*.txt "%buildroot/%_datadir/icu/%version/unidata"
|
||||||
ln -s unidata/UnicodeData.txt "%{buildroot}/%{_datadir}/icu/%{version}/"
|
ln -s unidata/UnicodeData.txt "%buildroot/%_datadir/icu/%version/"
|
||||||
|
|
||||||
rm "%{buildroot}/%{_datadir}/icu/%{version}/license.html"
|
rm "%buildroot/%_datadir/icu/%version/license.html"
|
||||||
rm "%{buildroot}/%{_datadir}/icu/%{version}/install-sh"
|
rm "%buildroot/%_datadir/icu/%version/install-sh"
|
||||||
|
|
||||||
%fdupes %{buildroot}/%{_prefix}
|
%fdupes %buildroot/%_prefix
|
||||||
|
|
||||||
%check
|
%check
|
||||||
cd source
|
cd source
|
||||||
@ -178,91 +178,91 @@ cd source
|
|||||||
# Checks disabled in qemu because of races happening when we emulate
|
# Checks disabled in qemu because of races happening when we emulate
|
||||||
# multi-threaded programs, and some check tests atomic instructions in
|
# multi-threaded programs, and some check tests atomic instructions in
|
||||||
# multi-threaded icu invocations
|
# multi-threaded icu invocations
|
||||||
ICU_DATA="%{buildroot}/%{_datadir}/icu/%{version}" make check %{?_smp_mflags} VERBOSE=1
|
ICU_DATA="%buildroot/%_datadir/icu/%version" make check %{?_smp_mflags} VERBOSE=1
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
# This should be run by whatever owns /usr/lib64/icu -
|
# This should be run by whatever owns /usr/lib64/icu -
|
||||||
# the (main) package in this case
|
# the (main) package in this case
|
||||||
|
|
||||||
%post
|
%post
|
||||||
if test -d "%{_libdir}/icu"; then
|
if test -d "%_libdir/icu"; then
|
||||||
current=$(cd "%{_libdir}/icu/"; find [0-9]* -maxdepth 1 -type d -printf '%f\n' |
|
current=$(cd "%_libdir/icu/"; find [0-9]* -maxdepth 1 -type d -printf '%f\n' |
|
||||||
sort -V | tail -n1);
|
sort -V | tail -n1);
|
||||||
if test -n "$current"; then
|
if test -n "$current"; then
|
||||||
rm -f "%{_libdir}/icu/current";
|
rm -f "%_libdir/icu/current";
|
||||||
ln -sv "$current" "%{_libdir}/icu/current";
|
ln -sv "$current" "%_libdir/icu/current";
|
||||||
fi;
|
fi;
|
||||||
fi;
|
fi;
|
||||||
|
|
||||||
%postun
|
%postun
|
||||||
if test -d "%{_libdir}/icu"; then
|
if test -d "%_libdir/icu"; then
|
||||||
current=$(cd "%{_libdir}/icu/"; find [0-9]* -maxdepth 1 -type d -printf '%f\n' |
|
current=$(cd "%_libdir/icu/"; find [0-9]* -maxdepth 1 -type d -printf '%f\n' |
|
||||||
sort -V | tail -n1);
|
sort -V | tail -n1);
|
||||||
if test -n "$current"; then
|
if test -n "$current"; then
|
||||||
rm -f "%{_libdir}/icu/current";
|
rm -f "%_libdir/icu/current";
|
||||||
ln -sv "$current" "%{_libdir}/icu/current";
|
ln -sv "$current" "%_libdir/icu/current";
|
||||||
fi;
|
fi;
|
||||||
fi;
|
fi;
|
||||||
|
|
||||||
%post -n %{lname} -p /sbin/ldconfig
|
%post -n %lname -p /sbin/ldconfig
|
||||||
|
|
||||||
%postun -n %{lname} -p /sbin/ldconfig
|
%postun -n %lname -p /sbin/ldconfig
|
||||||
|
|
||||||
%files
|
%files
|
||||||
%defattr(-,root,root)
|
%defattr(-,root,root)
|
||||||
%dir %{_libdir}/icu
|
%dir %_libdir/icu
|
||||||
%dir %{_libdir}/icu/%{version}
|
%dir %_libdir/icu/%version
|
||||||
%{_libdir}/icu/current
|
%_libdir/icu/current
|
||||||
%{_bindir}/derb
|
%_bindir/derb
|
||||||
%{_bindir}/gen*
|
%_bindir/gen*
|
||||||
%{_bindir}/icuinfo
|
%_bindir/icuinfo
|
||||||
%{_bindir}/makeconv
|
%_bindir/makeconv
|
||||||
%{_bindir}/pkgdata
|
%_bindir/pkgdata
|
||||||
%{_bindir}/uconv
|
%_bindir/uconv
|
||||||
%{_sbindir}/*
|
%_sbindir/*
|
||||||
%{_mandir}/man*/*
|
%_mandir/man*/*
|
||||||
%dir %{_docdir}/%{name}/
|
%dir %_docdir/%name/
|
||||||
%{_docdir}/%{name}/license.html
|
%_docdir/%name/license.html
|
||||||
%{_docdir}/%{name}/readme.html
|
%_docdir/%name/readme.html
|
||||||
|
|
||||||
%files -n %{lname}
|
%files -n %lname
|
||||||
%defattr(-, root, root)
|
%defattr(-, root, root)
|
||||||
%{_libdir}/libicu*.so.*
|
%_libdir/libicu*.so.*
|
||||||
|
|
||||||
%files -n libicu%{aversion}-data
|
%files -n libicu%aversion-data
|
||||||
%defattr(-,root,root)
|
%defattr(-,root,root)
|
||||||
%dir %{_datadir}/icu
|
%dir %_datadir/icu
|
||||||
%dir %{_datadir}/icu/%{version}
|
%dir %_datadir/icu/%version
|
||||||
%{_datadir}/icu/%{version}/icudt5*[bl].dat
|
%_datadir/icu/%version/icudt5*[bl].dat
|
||||||
|
|
||||||
%files -n libicu-devel
|
%files -n libicu-devel
|
||||||
%defattr(-, root, root)
|
%defattr(-, root, root)
|
||||||
%{_libdir}/libicu*.so
|
%_libdir/libicu*.so
|
||||||
%{_includedir}/unicode/
|
%_includedir/unicode/
|
||||||
%{_includedir}/layout/
|
%_includedir/layout/
|
||||||
%dir %{_libdir}/icu/
|
%dir %_libdir/icu/
|
||||||
%dir %{_libdir}/icu/%{version}/
|
%dir %_libdir/icu/%version/
|
||||||
%{_libdir}/icu/%{version}/Makefile.inc
|
%_libdir/icu/%version/Makefile.inc
|
||||||
%{_libdir}/icu/%{version}/pkgdata.inc
|
%_libdir/icu/%version/pkgdata.inc
|
||||||
%{_libdir}/icu/Makefile.inc
|
%_libdir/icu/Makefile.inc
|
||||||
%{_libdir}/icu/pkgdata.inc
|
%_libdir/icu/pkgdata.inc
|
||||||
%{_libdir}/pkgconfig/icu-*.pc
|
%_libdir/pkgconfig/icu-*.pc
|
||||||
%{_bindir}/icu-config
|
%_bindir/icu-config
|
||||||
%dir %{_datadir}/icu/
|
%dir %_datadir/icu/
|
||||||
%dir %{_datadir}/icu/%{version}/
|
%dir %_datadir/icu/%version/
|
||||||
%{_datadir}/icu/%{version}/mkinstalldirs
|
%_datadir/icu/%version/mkinstalldirs
|
||||||
%{_datadir}/icu/%{version}/config/
|
%_datadir/icu/%version/config/
|
||||||
|
|
||||||
%files -n libicu-doc
|
%files -n libicu-doc
|
||||||
%defattr(-,root,root)
|
%defattr(-,root,root)
|
||||||
%dir %{_docdir}/%{name}/
|
%dir %_docdir/%name/
|
||||||
%{_docdir}/%{name}/html/
|
%_docdir/%name/html/
|
||||||
|
|
||||||
%files data
|
%files data
|
||||||
%defattr(-, root, root)
|
%defattr(-, root, root)
|
||||||
%dir %{_datadir}/icu/
|
%dir %_datadir/icu/
|
||||||
%dir %{_datadir}/icu/%{version}/
|
%dir %_datadir/icu/%version/
|
||||||
%{_datadir}/icu/%{version}/unidata/
|
%_datadir/icu/%version/unidata/
|
||||||
%{_datadir}/icu/%{version}/UnicodeData.txt
|
%_datadir/icu/%version/UnicodeData.txt
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
Loading…
Reference in New Issue
Block a user