2007-11-23 00:56:17 +01:00
|
|
|
#
|
2011-10-01 04:58:52 +02:00
|
|
|
# spec file for package gettext-java
|
2007-11-23 00:56:17 +01:00
|
|
|
#
|
2012-01-12 16:07:04 +01:00
|
|
|
# Copyright (c) 2012 SUSE LINUX Products GmbH, Nuernberg, Germany.
|
2007-11-23 00:56:17 +01:00
|
|
|
#
|
2008-10-13 16:22:50 +02:00
|
|
|
# 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.
|
|
|
|
|
2007-11-23 00:56:17 +01:00
|
|
|
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
|
|
|
#
|
|
|
|
|
2008-04-10 13:16:55 +02:00
|
|
|
|
2007-11-23 00:56:17 +01:00
|
|
|
Name: gettext-java
|
2012-07-02 13:04:44 +02:00
|
|
|
BuildRequires: fdupes
|
|
|
|
BuildRequires: gcc-c++
|
|
|
|
BuildRequires: gcc-java
|
2011-10-02 21:19:40 +02:00
|
|
|
BuildRequires: libtool
|
2012-07-02 13:04:44 +02:00
|
|
|
BuildRequires: perl-libintl-perl
|
|
|
|
BuildRequires: tcl
|
2007-11-23 00:56:17 +01:00
|
|
|
Url: http://www.gnu.org/software/gettext/
|
2010-12-21 13:54:03 +01:00
|
|
|
Version: 0.18.1.1
|
2012-07-02 13:04:44 +02:00
|
|
|
Release: 0
|
2007-11-23 00:56:17 +01:00
|
|
|
Summary: Java Support for Native Language Support (NLS)
|
2012-07-02 13:04:44 +02:00
|
|
|
License: LGPL-2.1+
|
|
|
|
Group: Development/Tools/Other
|
2007-11-23 00:56:17 +01:00
|
|
|
PreReq: %{install_info_prereq}
|
|
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
|
|
|
Source: gettext-%{version}.tar.bz2
|
|
|
|
Source1: gettext-rpmlintrc
|
|
|
|
Source2: suse-start-po-mode.el
|
|
|
|
Source3: gettext-linkdupes.sh
|
|
|
|
Patch: gettext-0.12.1-sigfpe.patch
|
|
|
|
Patch2: gettext-0.12.1-gettextize.patch
|
|
|
|
Patch3: gettext-codecleanup.patch
|
2012-09-24 17:29:07 +02:00
|
|
|
Patch4: gettext-po-mode.diff
|
2007-11-23 00:56:17 +01:00
|
|
|
Patch5: gettext-initialize_vars.patch
|
|
|
|
Patch6: gettext-0.15-docdir.diff
|
|
|
|
Patch7: gettext-autotools.patch
|
|
|
|
Patch9: gettext-needlessly_init_vars.patch
|
2012-07-22 21:22:22 +02:00
|
|
|
Patch10: getext-stdio.in.patch
|
2012-09-24 17:29:07 +02:00
|
|
|
Patch11: gettext-no_silent_rules.patch
|
2007-11-23 00:56:17 +01:00
|
|
|
|
|
|
|
%description
|
|
|
|
This package includes the tools needed to support message catalogs in
|
|
|
|
Java applications. It also includes example code for java, java+awt and
|
|
|
|
java+swing.
|
|
|
|
|
|
|
|
%prep
|
|
|
|
%setup -q -n gettext-%{version}
|
|
|
|
%patch
|
|
|
|
%patch2
|
|
|
|
%patch3
|
|
|
|
%patch4
|
|
|
|
%patch5
|
2010-12-21 13:54:03 +01:00
|
|
|
%patch6
|
2007-11-23 00:56:17 +01:00
|
|
|
%patch7
|
|
|
|
%patch9
|
2012-07-22 21:22:22 +02:00
|
|
|
%patch10 -p1
|
2012-09-24 17:29:07 +02:00
|
|
|
%patch11
|
2007-11-23 00:56:17 +01:00
|
|
|
|
|
|
|
%build
|
2010-12-21 13:54:03 +01:00
|
|
|
export CFLAGS="%{optflags} -pipe -W -Wall -Dgcc_is_lint"
|
|
|
|
export CXXFLAGS="%{optflags} -pipe -W -Wall -Dgcc_is_lint"
|
|
|
|
autoreconf -fiv
|
2007-11-23 00:56:17 +01:00
|
|
|
%configure --enable-shared
|
2012-09-24 17:29:07 +02:00
|
|
|
make GMSGFMT=../src/msgfmt %{?_smp_mflags} V=1
|
2007-11-23 00:56:17 +01:00
|
|
|
|
|
|
|
%install
|
|
|
|
export LC_CTYPE=ISO-8859-15
|
2010-12-21 13:54:03 +01:00
|
|
|
make -C gettext-tools/gnulib-lib install DESTDIR=%{buildroot}
|
|
|
|
make -C gettext-tools/src install DESTDIR=%{buildroot}
|
2007-11-23 00:56:17 +01:00
|
|
|
make -C gettext-runtime/intl-java install DESTDIR=$PWD docdir=/docs
|
|
|
|
make -C gettext-tools/examples install DESTDIR=$PWD docdir=/allexamples
|
|
|
|
mkdir -p docs/examples
|
|
|
|
mv allexamples/examples/*java* docs/examples
|
|
|
|
cd docs/examples
|
|
|
|
fdupes -r *|while read dupe; do
|
|
|
|
if [ -z "$dupe" ]; then
|
|
|
|
startlink=
|
|
|
|
elif [ -z "$startlink" ]; then
|
|
|
|
startlink="$dupe"
|
|
|
|
else
|
|
|
|
ln -f "$startlink" "$dupe"
|
|
|
|
fi
|
|
|
|
done
|
|
|
|
cd ..
|
|
|
|
find -size 0 -print0 | xargs -0 --no-run-if-empty rm
|
2010-12-21 13:54:03 +01:00
|
|
|
rm -rf %{buildroot}/%{_datadir}/*
|
|
|
|
mkdir -p %{buildroot}/%{_defaultdocdir}/%{name}
|
|
|
|
cp -av * %{buildroot}/%{_defaultdocdir}/%{name}
|
2007-11-23 00:56:17 +01:00
|
|
|
cd ../allexamples/examples
|
|
|
|
rm -rf *csharp*
|
|
|
|
fdupes -r * | while read dupe; do
|
|
|
|
if [ -z "$dupe" ]; then
|
|
|
|
startlink=
|
|
|
|
elif [ -z "$startlink" ]; then
|
|
|
|
startlink="$dupe"
|
|
|
|
else
|
|
|
|
echo "ln -f '$startlink' '$dupe'" >>../../gettext-linkdupes.sh
|
|
|
|
fi
|
|
|
|
done
|
|
|
|
diff %{SOURCE3} . || {
|
|
|
|
cat <<END
|
|
|
|
######################################################
|
|
|
|
######################################################
|
|
|
|
## Updated gettext-linkdupes.sh in $PWD ##
|
|
|
|
######################################################
|
|
|
|
######################################################
|
|
|
|
END
|
|
|
|
}
|
2010-12-21 13:54:03 +01:00
|
|
|
ls -l %{buildroot}/%_datadir
|
2009-07-29 17:31:31 +02:00
|
|
|
# exclude files packaged via other spec files
|
2010-12-21 13:54:03 +01:00
|
|
|
rm -rf %{buildroot}/%_prefix/bin
|
|
|
|
rm -f %{buildroot}/%_libdir/lib*
|
|
|
|
rm -f %{buildroot}/%_libdir/gettext/hostname
|
|
|
|
rm -f %{buildroot}/%_libdir/gettext/project-id
|
|
|
|
rm -f %{buildroot}/%_libdir/gettext/urlget
|
|
|
|
rm -f %{buildroot}/%_libdir/gettext/user-email
|
2007-11-23 00:56:17 +01:00
|
|
|
|
|
|
|
%clean
|
2010-12-21 13:54:03 +01:00
|
|
|
rm -rf %{buildroot}
|
2007-11-23 00:56:17 +01:00
|
|
|
|
|
|
|
%files
|
|
|
|
%defattr(-,root,root)
|
|
|
|
%{_defaultdocdir}/%{name}
|
|
|
|
%_libdir/gettext/gnu.gettext.DumpResource
|
|
|
|
%_libdir/gettext/gnu.gettext.GetURL
|
|
|
|
|
|
|
|
%changelog
|