jna/jna.spec

347 lines
12 KiB
RPMSpec
Raw Normal View History

2008-04-04 23:46:58 +00:00
Name: jna
2017-03-28 18:07:41 +00:00
Version: 4.4.0
2017-07-03 12:43:23 +00:00
Release: 2%{?dist}
2008-04-04 23:46:58 +00:00
Summary: Pure Java access to native libraries
2015-06-11 06:11:15 +00:00
# Most of code is dual-licensed under either LGPL 2.1 only or Apache
# License 2.0. WeakIdentityHashMap.java was taken from Apache CXF,
# which is pure Apache License 2.0.
License: (LGPLv2 or ASL 2.0) and ASL 2.0
2015-09-15 13:57:13 +00:00
URL: https://github.com/java-native-access/jna/
# ./generate-tarball.sh
Source0: %{name}-%{version}-clean.tar.xz
Source1: package-list
Source2: generate-tarball.sh
2017-01-16 15:01:47 +00:00
Patch0: 0001-Adapt-build.patch
2008-04-04 23:46:58 +00:00
# This patch is Fedora-specific for now until we get the huge
# JNI library location mess sorted upstream
2017-01-16 15:01:47 +00:00
Patch1: 0002-Load-system-library.patch
# The X11 tests currently segfault; overall I think the X11 JNA stuff is just a
# Really Bad Idea, for relying on AWT internals, using the X11 API at all,
# and using a complex API like X11 through JNA just increases the potential
# for problems.
2017-01-16 15:01:47 +00:00
Patch2: 0003-Tests-headless.patch
2017-01-31 13:24:51 +00:00
# Adds --allow-script-in-comments arg to javadoc to avoid error
Patch3: 0004-Fix-javadoc-build.patch
2008-04-04 23:46:58 +00:00
# We manually require libffi because find-requires doesn't work
# inside jars.
2017-01-16 15:01:47 +00:00
Requires: libffi
BuildRequires: gcc
BuildRequires: make
2017-07-03 12:43:23 +00:00
BuildRequires: javapackages-local
2017-01-16 15:01:47 +00:00
BuildRequires: libffi-devel
BuildRequires: ant
BuildRequires: ant-junit
BuildRequires: junit
BuildRequires: libX11-devel
BuildRequires: libXt-devel
2015-09-15 13:57:13 +00:00
BuildRequires: reflections
2008-04-04 23:46:58 +00:00
%description
JNA provides Java programs easy access to native shared libraries
(DLLs on Windows) without writing anything but Java code. JNA's
design aims to provide native access in a natural way with a
minimum of effort. No boilerplate or generated code is required.
While some attention is paid to performance, correctness and ease
of use take priority.
%package javadoc
Summary: Javadocs for %{name}
BuildArch: noarch
2008-04-04 23:46:58 +00:00
%description javadoc
This package contains the javadocs for %{name}.
2010-07-22 09:58:03 +00:00
%package contrib
Summary: Contrib for %{name}
2015-06-11 06:11:15 +00:00
License: LGPLv2 or ASL 2.0
Requires: %{name} = %{version}-%{release}
2015-09-15 13:57:13 +00:00
BuildArch: noarch
2009-11-09 08:07:56 +00:00
2010-07-22 09:58:03 +00:00
%description contrib
This package contains the contributed examples for %{name}.
2009-11-09 08:07:56 +00:00
2008-04-04 23:46:58 +00:00
%prep
2014-03-07 15:07:07 +00:00
%setup -q -n %{name}-%{version}
2013-04-29 14:31:43 +00:00
cp %{SOURCE1} .
%patch0 -p1 -b .build
2013-07-06 20:32:00 +00:00
%patch1 -p1 -b .loadlib
%patch2 -p1 -b .tests-headless
2017-01-31 13:24:51 +00:00
%patch3 -p1
2015-06-11 07:06:03 +00:00
chmod -Rf a+rX,u+w,g-w,o-w .
sed -i 's|@LIBDIR@|%{_libdir}/%{name}|' src/com/sun/jna/Native.java
2008-04-04 23:46:58 +00:00
# clean LICENSE.txt
2012-03-07 11:20:26 +00:00
sed -i 's/\r//' LICENSE
2012-03-07 11:20:26 +00:00
chmod -c 0644 LICENSE OTHERS CHANGES.md
2008-04-04 23:46:58 +00:00
2015-06-11 07:06:03 +00:00
sed s,'<include name="junit.jar"/>,&<include name="reflections.jar"/>,' -i build.xml
2017-03-28 18:07:41 +00:00
build-jar-repository -s -p lib junit reflections ant
2015-09-15 13:57:13 +00:00
2015-06-11 07:06:03 +00:00
cp lib/native/aix-ppc64.jar lib/clover.jar
2008-04-04 23:46:58 +00:00
2015-09-15 13:57:13 +00:00
2008-04-04 23:46:58 +00:00
%build
# We pass -Ddynlink.native which comes from our patch because
# upstream doesn't want to default to dynamic linking.
2013-07-08 13:23:58 +00:00
#ant -Dcflags_extra.native="%{optflags}" -Ddynlink.native=true native compile javadoc jar contrib-jars
ant -Dcompatibility=1.6 -Dplatform.compatibility=1.6 -Dcflags_extra.native="%{optflags}" -Ddynlink.native=true native dist
2010-07-22 09:58:03 +00:00
# remove compiled contribs
find contrib -name build -exec rm -rf {} \; || :
2008-04-04 23:46:58 +00:00
%install
# NOTE: JNA has highly custom code to look for native jars in this
# directory. Since this roughly matches the jpackage guidelines,
# we'll leave it unchanged.
install -d -m 755 %{buildroot}%{_libdir}/%{name}
2013-07-06 20:32:00 +00:00
install -m 755 build/native*/libjnidispatch*.so %{buildroot}%{_libdir}/%{name}/
2008-04-04 23:46:58 +00:00
2017-07-03 12:43:23 +00:00
%mvn_file :jna jna jna/jna
2010-07-22 09:58:03 +00:00
2017-07-03 12:43:23 +00:00
%mvn_package :jna-platform contrib
%mvn_alias :jna-platform :platform
2010-07-22 09:58:03 +00:00
2017-07-03 12:43:23 +00:00
%mvn_artifact pom-jna.xml build/jna-min.jar
%mvn_artifact pom-jna-platform.xml contrib/platform/dist/jna-platform.jar
%mvn_install -J doc/javadoc
2008-04-04 23:46:58 +00:00
%files -f .mfiles
%doc OTHERS README.md CHANGES.md TODO
2017-01-16 15:01:47 +00:00
%license LICENSE LGPL2.1 AL2.0
2008-04-04 23:46:58 +00:00
%{_libdir}/%{name}
2009-11-09 08:07:56 +00:00
2017-07-03 12:43:23 +00:00
%files javadoc -f .mfiles-javadoc
2017-01-16 15:01:47 +00:00
%license LICENSE LGPL2.1 AL2.0
2008-04-04 23:46:58 +00:00
2017-07-03 12:43:23 +00:00
%files contrib -f .mfiles-contrib
2009-11-09 08:07:56 +00:00
2008-04-04 23:46:58 +00:00
%changelog
2017-07-03 12:43:23 +00:00
* Mon Jul 03 2017 Michael Simacek <msimacek@redhat.com> - 4.4.0-2
- Install with XMvn
2017-03-28 18:07:41 +00:00
* Tue Mar 28 2017 Michael Simacek <msimacek@redhat.com> - 4.4.0-1
- Update to upstream version 4.4.0
* Tue Feb 07 2017 Michael Simacek <msimacek@redhat.com> - 4.3.0-4
- Use --allow-script-in-comments on all arches
* Wed Feb 1 2017 Mikolaj Izdebski <mizdebsk@redhat.com> - 4.3.0-3
- Add missing build-requires on GCC
2017-01-31 13:24:51 +00:00
* Tue Jan 31 2017 Michael Simacek <msimacek@redhat.com> - 4.3.0-2
- Try to fix javadoc generation
2017-01-16 15:01:47 +00:00
* Mon Jan 16 2017 Michael Simacek <msimacek@redhat.com> - 4.3.0-1
- Update to upstream version 4.3.0
- Cleanup rhel macros, because packages was retired in EPEL
2016-03-24 11:23:05 +00:00
* Thu Mar 24 2016 Mikolaj Izdebski <mizdebsk@redhat.com> - 4.2.2-1
- Update to upstream version 4.2.2
* Thu Feb 04 2016 Fedora Release Engineering <releng@fedoraproject.org> - 4.2.1-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
2015-10-20 06:29:48 +00:00
* Tue Oct 20 2015 Mikolaj Izdebski <mizdebsk@redhat.com> - 4.2.1-1
- Update to upstream version 4.2.1
2015-09-17 20:43:53 +00:00
* Thu Sep 17 2015 Levente Farkas <lfarkas@lfarkas.org> - 4.2.0-1
- Update to 4.2.0
* Wed Jun 17 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 4.1.0-9
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild
* Thu Jun 11 2015 Mikolaj Izdebski <mizdebsk@redhat.com> - 4.1.0-8
- Force Java 1.6 source/target (rhbz#842609)
2015-06-11 06:11:15 +00:00
- Fix licensing headers (rhbz#988808)
* Wed Oct 01 2014 Michal Srb <msrb@redhat.com> - 4.1.0-7
- Fix for 32-bit systems (Resolves: rhbz#1148349)
- Fix FTBFS (Resolves: rhbz#1106955)
* Sat Aug 16 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 4.1.0-6
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild
* Sun Jun 08 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 4.1.0-5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
2014-01-14 21:16:55 +00:00
* Fri Jan 10 2014 Roland Grunberg <rgrunber@redhat.com> - 4.0.0-4
- fix updated depmap
* Fri Jan 10 2014 Roland Grunberg <rgrunber@redhat.com> - 4.0.0-3
- Update depmap calls and fix tests compilation issue.
* Sat Aug 03 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 4.0.0-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
2013-07-06 20:32:00 +00:00
* Sat Jul 6 2013 Levente Farkas <lfarkas@lfarkas.org> - 4.0-1
- Update to 4.0
2013-06-28 14:01:16 +00:00
* Fri Jun 28 2013 Mikolaj Izdebski <mizdebsk@redhat.com> - 3.5.2-2
- Fix ant-trax and ant-nodeps BR on RHEL
2013-04-25 12:32:09 +00:00
* Thu Apr 25 2013 Levente Farkas <lfarkas@lfarkas.org> - 3.5.2-1
- Update to 3.5.2
* Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.5.0-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
* Thu Jul 19 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.4.0-5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
2012-06-20 16:20:52 +00:00
* Wed Jun 20 2012 Levente Farkas <lfarkas@lfarkas.org> - 3.4.0-4
- fix #833786 by Mary Ellen Foster
2012-03-14 10:52:52 +00:00
* Wed Mar 14 2012 Juan Hernandez <juan.hernandez@redhat.com> - 3.4.0-3
- Generate correctly the maven dependencies map (#)
* Sun Mar 11 2012 Ville Skyttä <ville.skytta@iki.fi> - 3.4.0-2
- Don't strip binaries too early, build with $RPM_LD_FLAGS (#802020).
2012-03-07 11:20:26 +00:00
* Wed Mar 7 2012 Levente Farkas <lfarkas@lfarkas.org> - 3.4.0-1
- Update to 3.4.0
* Fri Jan 13 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.2.7-13
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
* Wed Feb 09 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.2.7-12
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
* Thu Dec 9 2010 Ville Skyttä <ville.skytta@iki.fi> - 3.2.7-11
- Drop dependency on main package from -javadoc.
- Add license to -javadoc, and OTHERS and TODO to main package docs.
- Install javadocs and jars unversioned.
- Fix release-notes.html permissions.
- Make -javadoc and -contrib noarch where available.
* Fri Dec 3 2010 Levente Farkas <lfarkas@lfarkas.org> - 3.2.7-10
2010-12-03 13:48:24 +00:00
- fix pom file name #655810
2010-12-03 14:15:50 +00:00
- disable check everywhere since it seems to always fail in mock
2010-12-03 13:48:24 +00:00
2010-11-05 17:31:33 +00:00
* Fri Nov 5 2010 Dan Horák <dan[at]danny.cz> - 3.2.7-9
- exclude checks on s390(x)
2010-10-12 07:24:48 +00:00
* Tue Oct 12 2010 Levente Farkas <lfarkas@lfarkas.org> - 3.2.7-8
- exclude check on ppc
2010-10-08 09:40:04 +00:00
* Fri Oct 8 2010 Levente Farkas <lfarkas@lfarkas.org> - 3.2.7-7
- fix excludearch condition
2010-10-07 15:54:26 +00:00
* Wed Oct 6 2010 Levente Farkas <lfarkas@lfarkas.org> - 3.2.7-6
- readd excludearch for old release fix #548099
2010-10-02 02:42:04 +00:00
* Fri Oct 01 2010 Dennis Gilmore <dennis@ausil.us> - 3.2.7-5.1
- remove the ExcludeArch it makes no sense
* Sun Aug 1 2010 Levente Farkas <lfarkas@lfarkas.org> - 3.2.7-5
- reenable test and clean up contrib files
2010-07-27 10:13:13 +00:00
* Tue Jul 27 2010 Levente Farkas <lfarkas@lfarkas.org> - 3.2.7-4
- add Obsoletes for jna-examples
2010-07-23 22:57:49 +00:00
* Sat Jul 24 2010 Levente Farkas <lfarkas@lfarkas.org> - 3.2.7-3
- upstream 64bit fixes
2013-04-29 16:01:52 +00:00
* Fri Jul 23 2010 Levente Farkas <lfarkas@lfarkas.org> - 3.2.7-2
2010-07-22 21:17:11 +00:00
- Temporary hack for 64bit build
2010-07-22 09:58:03 +00:00
* Thu Jul 22 2010 Levente Farkas <lfarkas@lfarkas.org> - 3.2.7-1
- Rebase on upstream 3.2.7
* Wed Jul 21 2010 Stanislav Ochotnicky <sochotnicky@redhat.com> - 3.2.4-6
- Add maven depmap
2010-04-22 19:50:09 +00:00
* Thu Apr 22 2010 Colin Walters <walters@verbum.org> - 3.2.4-5
- Add patches to make the build happen with gcj
2010-04-21 21:56:22 +00:00
* Wed Apr 21 2010 Colin Walters <walters@verbum.org> - 3.2.4-4
- Fix the build by removing upstream's hardcoded md5
2009-12-17 08:55:45 +00:00
* Thu Dec 17 2009 Levente Farkas <lfarkas@lfarkas.org> - 3.2.4-3
- add proper ExclusiveArch
* Thu Dec 17 2009 Alexander Kurtakov <akurtako@redhat.com> 3.2.4-2
- Comment rhel ExclusiveArchs - not correct applies on Fedora.
2009-11-23 18:32:42 +00:00
* Sat Nov 14 2009 Levente Farkas <lfarkas@lfarkas.org> - 3.2.4-1
- Rebase on upstream 3.2.4
2009-11-09 08:07:56 +00:00
* Thu Oct 29 2009 Lubomir Rintel <lkundrak@v3.sk> - 3.0.9-6
- Add examples subpackage
* Fri Jul 24 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.0.9-5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
* Wed Feb 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.0.9-4
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
* Tue Dec 30 2008 Colin Walters <walters@redhat.com> - 3.0.9-3
- Add patch to allow opening current process
* Sun Nov 30 2008 Colin Walters <walters@redhat.com> - 3.0.9-2
- Fix library mapping, remove upstreamed patches
2008-11-01 01:05:21 +00:00
* Fri Oct 31 2008 Colin Walters <walters@redhat.com> - 3.0.9-1
- Rebase on upstream 3.0.9
* Tue Oct 14 2008 Colin Walters <walters@redhat.com> - 3.0.4-10.svn729
- Add patch to support String[] returns
* Wed Oct 01 2008 Colin Walters <walters@redhat.com> - 3.0.4-9.svn729
- Add new patch to support NativeMapped[] which I want
* Wed Oct 01 2008 Colin Walters <walters@redhat.com> - 3.0.4-8.svn729
- Update to svn r729
- drop upstreamed typemapper patch
2013-04-29 16:01:52 +00:00
* Thu Sep 18 2008 Colin Walters <walters@redhat.com> - 3.0.4-7.svn700
- Add patch to make typemapper always accessible
- Add patch to skip cracktastic X11 test bits which currently fail
2008-09-09 15:51:06 +00:00
* Tue Sep 09 2008 Colin Walters <walters@redhat.com> - 3.0.4-5.svn700
- Update to upstream SVN r700; drop all now upstreamed patches
2008-09-06 22:13:22 +00:00
* Sat Sep 06 2008 Colin Walters <walters@redhat.com> - 3.0.4-3.svn630
- A few more patches for JGIR
* Thu Sep 04 2008 Colin Walters <walters@redhat.com> - 3.0.4-2.svn630
- Add two (sent upstream) patches that I need for JGIR
* Thu Jul 31 2008 Colin Walters <walters@redhat.com> - 3.0.4-1.svn630
- New upstream version, drop upstreamed patch parts
- New patch jna-3.0.4-nomixedjar.patch which ensures that we don't
include the .so in the .jar
2008-04-04 23:46:58 +00:00
* Fri Apr 04 2008 Colin Walters <walters@redhat.com> - 3.0.2-7
- Add patch to use JPackage-compatible JNI library path
- Do build debuginfo package
- Refactor build patch greatly so it's hopefully upstreamable
- Install .so directly to JNI directory, rather than inside jar
- Clean up Requires/BuildRequires (thanks Mamoru Tasaka)
* Sun Mar 30 2008 Conrad Meyer <konrad@tylerc.org> - 3.0.2-6
- -javadocs should be -javadoc.
- %%files section cleaned a bit.
* Mon Mar 17 2008 Conrad Meyer <konrad@tylerc.org> - 3.0.2-5
- -javadocs package should be in group "Documentation".
* Mon Mar 17 2008 Conrad Meyer <konrad@tylerc.org> - 3.0.2-4
- License should be LGPLv2+, not GPLv2+.
- Several minor fixes.
- Fix Requires in javadoc package.
* Sun Mar 16 2008 Conrad Meyer <konrad@tylerc.org> - 3.0.2-3
- Don't use internal libffi.
* Thu Mar 6 2008 Conrad Meyer <konrad@tylerc.org> - 3.0.2-2
- Don't pull in jars from the web.
* Mon Mar 3 2008 Conrad Meyer <konrad@tylerc.org> - 3.0.2-1
- Initial package.