SHA256
1
0
forked from pool/icu
icu/icu.spec

279 lines
8.3 KiB
RPMSpec
Raw Normal View History

#
# spec file for package icu
#
# Copyright (c) 2020 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
Accepting request 642586 from home:namtrac:branches:X11:common:Factory - Update to new upstream release 63.1 * CLDR 34 + Segmentation rules and emoji sort order adjusted for Unicode 11 + Somali and Javanese data now up to moderate level (document content) + Tongan, Konkani, Maori, Dzongkha, Tatar, Kurdish (ku), and Xhosa data now up to basic level + Many data additions and corrections in many other languages + The following languages have been added to ICU: Sindhi, Maori, Turkmen, Javanese, Interlingua, Kurdish (ku), Xhosa * New currency: Venezuela's Bolívar Soberano (VES) * New Japanese calendar era from 2019: CLDR and ICU include data for testing that can be enabled. (ICU #12973, CLDR #10750) * To enable CLDR new Japanese era placeholder name, set environment variable (and Java system property for ICU4J) ICU_ENABLE_TENTATIVE_ERA=true. * New API for number and currency range formatting (class NumberRangeFormatter, #11276) * Support for additional Unicode properties: Indic_Positional_Category & Indic_Syllabic_Category (#8966) and Vertical_Orientation (#12850) * New API for code point maps and tries, mapping Unicode code points (U+0000..U+10FFFF) to integer values. (#13530) * Java classes CodePointMap, CodePointTrie, MutableCodePointTrie * C types UCPMap, UCPTrie, UMutableCPTrie * New API for getting a UnicodeSet per binary property and a code point map per enumerated/int-value property. (#20086) OBS-URL: https://build.opensuse.org/request/show/642586 OBS-URL: https://build.opensuse.org/package/show/X11:common:Factory/icu?expand=0&rev=96
2018-10-17 14:30:32 +02:00
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
Accepting request 796373 from home:namtrac:branches:X11:common:Factory - Update to version 67.1 * Unicode 13 (ICU-20893, same as in ICU 66) + Total of 5930 new characters + 4 new scripts + 55 new emoji characters, plus additional new sequences + New CJK extension, first characters in plane 3: U+30000..U+3134A * CLDR 37 + New language at Modern coverage: Nigerian Pidgin + New languages at Basic coverage: Fulah (Adlam), Maithili, Manipuri, Santali, Sindhi (Devanagari), Sundanese + Region containment: EU no longer includes GB + Unicode 13 root collation data and Chinese data for collation and transliteration * DateTimePatternGenerator now obeys the "hc" preference in the locale identifier (ICU-20442) * Various other improvements for ECMA-402 conformance * Number skeletons have a new "concise" form that can be used in MessageFormat strings (ICU-20418) * Currency formatting options for formal and other currency display name variants (ICU-20854) * ListFormatter: new public API to select the style & type (ICU-12863) * ListFormatter now selects the proper “and”/“or” form for Spanish & Hebrew (ICU-21016) * Locale ID canonicalization upgraded to implement the complete CLDR spec (ICU-20834, ICU-20272) * LocaleMatcher: New option to ignore one-way matches (ICU-20936), and other tweaks to the code (ICU-20916, ICU-20917) and data (from CLDR) * acceptLanguage() reimplemented via LocaleMatcher (ICU-20700) * Data build tool: tzdbNames.res moved from the "zone_tree" category to the "zone_supplemental" category (ICU-21073) * Fixed uses of u8"literals" broken by the C++20 introduction of the incompatible char8_t type (ICU-20972), * and added a few API overloads to reduce the need for reinterpret_cast (ICU-20984). * Support for manipulating CLDR 37 unit identifiers in MeasureUnit. OBS-URL: https://build.opensuse.org/request/show/796373 OBS-URL: https://build.opensuse.org/package/show/X11:common:Factory/icu?expand=0&rev=127
2020-04-23 10:25:28 +02:00
%define lname libicu67
%define amajor 67
%define aversion 67
%ifarch %armb hppa mips mips64 ppc ppc64 %sparc s390 s390x m68k
%define be_platform 1
%else
%define be_platform 0
%endif
# icu-versioning.diff needs update for new Version too
Name: icu
Accepting request 796373 from home:namtrac:branches:X11:common:Factory - Update to version 67.1 * Unicode 13 (ICU-20893, same as in ICU 66) + Total of 5930 new characters + 4 new scripts + 55 new emoji characters, plus additional new sequences + New CJK extension, first characters in plane 3: U+30000..U+3134A * CLDR 37 + New language at Modern coverage: Nigerian Pidgin + New languages at Basic coverage: Fulah (Adlam), Maithili, Manipuri, Santali, Sindhi (Devanagari), Sundanese + Region containment: EU no longer includes GB + Unicode 13 root collation data and Chinese data for collation and transliteration * DateTimePatternGenerator now obeys the "hc" preference in the locale identifier (ICU-20442) * Various other improvements for ECMA-402 conformance * Number skeletons have a new "concise" form that can be used in MessageFormat strings (ICU-20418) * Currency formatting options for formal and other currency display name variants (ICU-20854) * ListFormatter: new public API to select the style & type (ICU-12863) * ListFormatter now selects the proper “and”/“or” form for Spanish & Hebrew (ICU-21016) * Locale ID canonicalization upgraded to implement the complete CLDR spec (ICU-20834, ICU-20272) * LocaleMatcher: New option to ignore one-way matches (ICU-20936), and other tweaks to the code (ICU-20916, ICU-20917) and data (from CLDR) * acceptLanguage() reimplemented via LocaleMatcher (ICU-20700) * Data build tool: tzdbNames.res moved from the "zone_tree" category to the "zone_supplemental" category (ICU-21073) * Fixed uses of u8"literals" broken by the C++20 introduction of the incompatible char8_t type (ICU-20972), * and added a few API overloads to reduce the need for reinterpret_cast (ICU-20984). * Support for manipulating CLDR 37 unit identifiers in MeasureUnit. OBS-URL: https://build.opensuse.org/request/show/796373 OBS-URL: https://build.opensuse.org/package/show/X11:common:Factory/icu?expand=0&rev=127
2020-04-23 10:25:28 +02:00
Version: 67.1
Release: 0
Summary: International Components for Unicode
License: ICU
Group: Development/Libraries/C and C++
URL: http://icu-project.org/
#Git-Clone: https://github.com/unicode-org/icu.git
Accepting request 796373 from home:namtrac:branches:X11:common:Factory - Update to version 67.1 * Unicode 13 (ICU-20893, same as in ICU 66) + Total of 5930 new characters + 4 new scripts + 55 new emoji characters, plus additional new sequences + New CJK extension, first characters in plane 3: U+30000..U+3134A * CLDR 37 + New language at Modern coverage: Nigerian Pidgin + New languages at Basic coverage: Fulah (Adlam), Maithili, Manipuri, Santali, Sindhi (Devanagari), Sundanese + Region containment: EU no longer includes GB + Unicode 13 root collation data and Chinese data for collation and transliteration * DateTimePatternGenerator now obeys the "hc" preference in the locale identifier (ICU-20442) * Various other improvements for ECMA-402 conformance * Number skeletons have a new "concise" form that can be used in MessageFormat strings (ICU-20418) * Currency formatting options for formal and other currency display name variants (ICU-20854) * ListFormatter: new public API to select the style & type (ICU-12863) * ListFormatter now selects the proper “and”/“or” form for Spanish & Hebrew (ICU-21016) * Locale ID canonicalization upgraded to implement the complete CLDR spec (ICU-20834, ICU-20272) * LocaleMatcher: New option to ignore one-way matches (ICU-20936), and other tweaks to the code (ICU-20916, ICU-20917) and data (from CLDR) * acceptLanguage() reimplemented via LocaleMatcher (ICU-20700) * Data build tool: tzdbNames.res moved from the "zone_tree" category to the "zone_supplemental" category (ICU-21073) * Fixed uses of u8"literals" broken by the C++20 introduction of the incompatible char8_t type (ICU-20972), * and added a few API overloads to reduce the need for reinterpret_cast (ICU-20984). * Support for manipulating CLDR 37 unit identifiers in MeasureUnit. OBS-URL: https://build.opensuse.org/request/show/796373 OBS-URL: https://build.opensuse.org/package/show/X11:common:Factory/icu?expand=0&rev=127
2020-04-23 10:25:28 +02:00
Source: https://github.com/unicode-org/icu/releases/download/release-67-1/icu4c-67_1-src.tgz
Source2: https://github.com/unicode-org/icu/releases/download/release-67-1/icu4c-67_1-src.tgz.asc
Source3: https://github.com/unicode-org/icu/releases/download/release-67-1/icu4c-67_1-docs.zip
Source4: https://github.com/unicode-org/icu/releases/download/release-67-1/icu4c-67_1-docs.zip.asc
Source5: %name.keyring
Source100: baselibs.conf
Patch4: icu-fix-install-mode-files.diff
Patch6: icu-error-reporting.diff
Patch7: icu-avoid-x87-excess-precision.diff
Patch8: locale.diff
BuildRequires: fdupes
BuildRequires: gcc-c++
BuildRequires: pkg-config
BuildRequires: python3-base
BuildRequires: unzip
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%description
ICU is a set of C and C++ libraries that provide extensive Unicode and locale
support, such as calendar, conversions for many character sets, language
sensitive collation, date and time formatting, support for many locales,
message catalogs and resources, message formatting, normalization, number and
currency formatting, time zone support, transliteration, and word, line, and
sentence breaking.
/
This subpackage contains the runtime programs for interacting with ICU.
%package -n %lname
Summary: International Components for Unicode
Group: System/Libraries
Requires: timezone
%if %be_platform
Requires: libicu%aversion-bedata = %version
%else
Requires: libicu%aversion-ledata = %version
%endif
%description -n %lname
ICU is a set of C and C++ libraries that provide extensive Unicode
and locale support.
This package contains the runtime libraries for ICU.
%package -n libicu%aversion-bedata
Summary: Rule databases and tables for ICU
Group: System/Libraries
%if 0%{?suse_version} >= 1210
BuildArch: noarch
%endif
%description -n libicu%aversion-bedata
ICU is a set of C and C++ libraries that provide extensive Unicode
and locale support.
ICU makes use of a wide variety of data tables to provide many of its
services: converter mapping tables, collation rules, transliteration
rules, break iterator rules and dictionaries.
This subpackage contains these data tables, in big-endian format.
%package -n libicu%aversion-ledata
Summary: Rule databases and tables for ICU
Group: System/Libraries
%if 0%{?suse_version} >= 1210
BuildArch: noarch
%endif
%description -n libicu%aversion-ledata
ICU is a set of C and C++ libraries that provide extensive Unicode
and locale support.
ICU makes use of a wide variety of data tables to provide many of its
services: converter mapping tables, collation rules, transliteration
rules, break iterator rules and dictionaries.
This subpackage contains these data tables, in little-endian format.
%package -n libicu-devel
Summary: Development files for the ICU library
Group: Development/Libraries/C and C++
Requires: %lname = %version
%description -n libicu-devel
ICU is a set of C and C++ libraries that provide extensive Unicode
and locale support.
This package contains the headers for ICU.
%package -n libicu-doc
Summary: Documentation for the ICU library
Group: Documentation/HTML
%description -n libicu-doc
ICU is a set of C and C++ libraries that provide extensive Unicode
and locale support.
This package contains the HTML documentation.
%prep
%setup -qn icu
%autopatch -p1
# docs are special
mkdir html
pushd html/
unzip %SOURCE3
popd
%build
cd source
mkdir -p data/out/tmp # build procedure forgets to do this on its own
export CXXFLAGS="%optflags -DICU_DATA_DIR=\\\"%_datadir/icu/%version/\\\""
export CFLAGS="$CXXFLAGS"
%configure \
--disable-static \
--enable-shared \
--disable-samples \
--with-data-packaging=archive
make %{?_smp_mflags} VERBOSE=1
# Build the other endianess, too.
pushd data/
%if %be_platform
cp in/icudt%{amajor}l.dat out/
%else
LD_LIBRARY_PATH="../lib:../stubdata:../tools/ctestfw:$LD_LIBRARY_PATH" \
../bin/icupkg -tb in/icudt%{amajor}l.dat out/icudt%{amajor}b.dat
! cmp in/icudt%{amajor}l.dat out/icudt%{amajor}b.dat
%endif
popd
%install
mkdir -p "%buildroot/%_docdir/%name"
cp -a html "%buildroot/%_docdir/%name/"
cp -a license.html readme.html "%buildroot/%_docdir/%name/"
find . -name CVS -type d -exec rm -Rf "{}" "+"
cd source
make DESTDIR="%buildroot" install %{?_smp_mflags}
cp data/out/icudt*.dat "%buildroot/%_datadir/icu/%version/"
#
# ICU's "pkgdata" utility is really fragile, so icu-versioning.diff
# does as few actions as possible, but that means we need some additional
# cleanup in the spec file now.
#
pushd "%buildroot/%_libdir/"
for i in *.so.[0-9]*; do
echo "Looking at $i"
if [ "${i##*.so.}" != "%version" ]; then
rm -fv "$i"
continue
fi
# Because U_ICU_VERSION_SHORT is "51_2" and not "51.2",
# create some symlinks.
ln -s "$i" "${i%%%version}%aversion"
done
popd
# /usr/lib/rpm/elfdeps requires +x bit and not all files had it at one point.
# - OpenBSD for example is known to have patched their libtool program
# to kill the x bit on install :(
chmod a+rx "%buildroot/%_libdir"/lib*.so.*
# install uncompiled source data:
mkdir -p "%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/"
rm "%buildroot/%_datadir/icu/%version/install-sh"
# Seems unused
rm -Rf "%buildroot/%_datadir/icu/%version/unidata/" \
"%buildroot/%_datadir/icu/%version/UnicodeData.txt" \
"%buildroot/%_libdir/icu/current" \
"%buildroot/%_libdir/icu/Makefile.inc" \
"%buildroot/%_libdir/icu/pkgdata.inc"
%fdupes %buildroot/%_prefix
%check
# s390x see: https://ssl.icu-project.org/trac/ticket/13095
cd source
%if !0%{?qemu_user_space_build:1}
# Checks disabled in qemu because of races happening when we emulate
# multi-threaded programs, and some check tests atomic instructions in
# multi-threaded icu invocations
ICU_DATA="%buildroot/%_datadir/icu/%version" make check %{?_smp_mflags} VERBOSE=1
%endif
%post -n %lname -p /sbin/ldconfig
%postun -n %lname -p /sbin/ldconfig
%files
%defattr(-,root,root)
%_bindir/derb
%_bindir/gen*
%_bindir/icuinfo
%_bindir/makeconv
%_bindir/pkgdata
%_bindir/uconv
%_sbindir/*
%_mandir/man*/*
%dir %_datadir/icu
%dir %_datadir/icu/%version
%_datadir/icu/%version/LICENSE
%dir %_docdir/%name/
%_docdir/%name/license.html
%_docdir/%name/readme.html
%files -n %lname
%defattr(-, root, root)
%_libdir/libicu*.so.*
%files -n libicu%aversion-bedata
%defattr(-,root,root)
%dir %_datadir/icu
%dir %_datadir/icu/%version
%_datadir/icu/%version/icudt%{amajor}b.dat
%files -n libicu%aversion-ledata
%defattr(-,root,root)
%dir %_datadir/icu
%dir %_datadir/icu/%version
%_datadir/icu/%version/icudt%{amajor}l.dat
%files -n libicu-devel
%defattr(-, root, root)
%_libdir/libicu*.so
%_includedir/unicode/
%dir %_libdir/icu/
%dir %_libdir/icu/%version/
%_libdir/icu/%version/Makefile.inc
%_libdir/icu/%version/pkgdata.inc
%_libdir/pkgconfig/icu-*.pc
%_bindir/icu-config
%dir %_datadir/icu/
%dir %_datadir/icu/%version/
%_datadir/icu/%version/mkinstalldirs
%_datadir/icu/%version/config/
%files -n libicu-doc
%defattr(-,root,root)
%dir %_docdir/%name/
%_docdir/%name/html/
%changelog