Drop unnecessary BuildRequires: jruby

Drop version prefix from javadocs installation the ghosted symlink
  blocking us from doing this has last shipped in Fedora 16
Update to match latest java packaging guidelines
This commit is contained in:
Hans de Goede 2019-11-25 21:31:20 +01:00
commit ad8eba37d1
2 changed files with 22 additions and 14 deletions

5
sdljava.rpmlintrc Normal file
View file

@ -0,0 +1,5 @@
# We ship a cleaned tarbal with nonfree fonts removed
addFilter("W: invalid-url Source0: sdljava-0.9.1.tar.gz")
# The demos do not have docs / manpages, nor do they need these
addFilter("W: no-manual-page-for-binary .*")
addFilter("W: no-documentation")

View file

@ -7,11 +7,11 @@
Name: sdljava
Version: 0.9.1
Release: 44%{?dist}
Release: 45%{?dist}
Summary: Java binding to the SDL API
License: LGPLv2+
URL: http://sdljava.sourceforge.net/
# this is http://downloads.sourceforge.net/%{name}/%{name}-%{version}.tar.gz
# this is http://downloads.sourceforge.net/%%{name}/%%{name}-%%{version}.tar.gz
# with the included Microsoft Copyrighted Arial fonts removed
Source0: %{name}-%{version}.tar.gz
Source1: %{name}-runtest.sh
@ -35,12 +35,10 @@ BuildRequires: swig
BuildRequires: bsh
BuildRequires: jdom
BuildRequires: xml-commons-apis
BuildRequires: jruby
BuildRequires: %{_bindir}/ruby
Requires: java
Requires: javapackages-tools
Requires: javapackages-filesystem
Requires: bsh
Requires: jdom
@ -68,6 +66,7 @@ Requires: /usr/share/fonts/dejavu/DejaVuSans.ttf
Requires: /usr/share/fonts/dejavu/DejaVuSans-Bold.ttf
Requires: /usr/share/fonts/dejavu/DejaVuSans-Oblique.ttf
Requires: /usr/share/fonts/dejavu/DejaVuSans-BoldOblique.ttf
Requires: javapackages-tools
%description demo
Demonstrations and samples for %{name}.
@ -113,7 +112,7 @@ rm src/org/gljava/opengl/native/glew_wrap.c
%build
# We must add -D__%{_arch}__ to swigs arguments as swig doesn't do that itself.
# We must add -D__%%{_arch}__ to swigs arguments as swig doesn't do that itself.
# Special case ppc as the define is powerpc not ppc and both ppc and ppc64
# must be set for ppc64, also add -D__LONG_DOUBLE_128__ which works around
# swig barfing on bits/stdlib-ldbl.h
@ -168,20 +167,18 @@ ant jar javadoc
mkdir -p $RPM_BUILD_ROOT%{_bindir}
mkdir -p $RPM_BUILD_ROOT%{_libdir}/%{name}
mkdir -p $RPM_BUILD_ROOT%{_datadir}/%{name}
mkdir -p $RPM_BUILD_ROOT%{_javadir}
# should be just %{_javadocdir}/%{name} but that is a ghosted symlink in older
# versions and rpm does not grok replacing that with a dir
mkdir -p $RPM_BUILD_ROOT%{_javadocdir}/%{name}-%{version}
mkdir -p $RPM_BUILD_ROOT%{_jnidir}
mkdir -p $RPM_BUILD_ROOT%{_javadocdir}/%{name}
# jars
install -m 644 lib/%{name}.jar \
$RPM_BUILD_ROOT%{_javadir}/%{name}.jar
$RPM_BUILD_ROOT%{_jnidir}/%{name}.jar
# native libraries
install -m 755 lib/*.so $RPM_BUILD_ROOT%{_libdir}/%{name}
# javadoc
cp -pr docs/api/* $RPM_BUILD_ROOT%{_javadocdir}/%{name}-%{version}
cp -pr docs/api/* $RPM_BUILD_ROOT%{_javadocdir}/%{name}
# demo scripts
install -m 755 %{SOURCE1} $RPM_BUILD_ROOT%{_bindir}
@ -208,11 +205,11 @@ ln -s ../../fonts/dejavu/DejaVuSans-BoldOblique.ttf \
%files
%doc README TODO docs/CHANGES_0_9_1
%{_javadir}/%{name}.jar
%{_jnidir}/%{name}.jar
%{_libdir}/%{name}
%files javadoc
%doc %{_javadocdir}/%{name}-%{version}
%doc %{_javadocdir}/%{name}
%files demo
%{_bindir}/%{name}-*.sh
@ -220,6 +217,12 @@ ln -s ../../fonts/dejavu/DejaVuSans-BoldOblique.ttf \
%changelog
* Mon Nov 25 2019 Hans de Goede <hdegoede@redhat.com> - 0.9.1-45
- Drop unnecessary BuildRequires: jruby
- Drop version prefix from javadocs installation the ghosted symlink
blocking us from doing this has last shipped in Fedora 16
- Update to match latest java packaging guidelines
* Fri Jul 26 2019 Fedora Release Engineering <releng@fedoraproject.org> - 0.9.1-44
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild