- Fix library mapping, remove upstreamed patches

This commit is contained in:
Colin Walters 2008-11-30 18:43:32 +00:00
parent bff2e9181f
commit 365bfa6d3d
2 changed files with 23 additions and 5 deletions

View File

@ -0,0 +1,14 @@
--- jna-3.0.9/src/com/sun/jna/NativeLibrary.java 2008-10-28 20:30:54.000000000 -0400
+++ jna-3.0.9.orig/src/com/sun/jna/NativeLibrary.java 2008-11-15 18:29:52.000000000 -0500
@@ -374,8 +374,9 @@
return name;
}
else if (Platform.isLinux()) {
- if (isVersionedName(libName)) {
- // A specific version was requested - use as is for search
+ if (isVersionedName(libName) || libName.endsWith(".so")) {
+ // An already mapped name was specified - use as is
+ // for search
return libName;
}
}

View File

@ -1,6 +1,6 @@
Name: jna
Version: 3.0.9
Release: 1%{?dist}
Release: 2%{?dist}
Summary: Pure Java access to native libraries
Group: Development/Libraries
@ -22,10 +22,11 @@ Patch1: jna-3.0.2-loadlibrary.patch
Patch2: jna-tests-headless.patch
# https://jna.dev.java.net/issues/show_bug.cgi?id=90
Patch3: jna-3.0.4-nativemapped-array.patch
# https://jna.dev.java.net/issues/show_bug.cgi?id=XXX
Patch4: jna-stringarray-return.patch
# https://jna.dev.java.net/issues/show_bug.cgi?id=XXX
# Not yet sent upstream - haven't decided whether it's a good idea yet,
# but keeping around here for now.
Patch5: jna-callback-exception.patch
# https://jna.dev.java.net/issues/show_bug.cgi?id=95
Patch6: jna-3.0.9-linux-nomaplibrary.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildRequires: java-devel >= 1.6 ant jpackage-utils ant-nodeps
@ -58,8 +59,8 @@ This package contains the javadocs for %{name}.
sed -e 's|@JNIPATH@|%{_libdir}/%{name}|' %{PATCH1} | patch -p1
%patch2 -p1 -b .tests-headless
%patch3 -p1 -b .nativemapped-array
%patch4 -p1 -b .stringarray-return
#%patch5 -p1 -b .callback-exception
%patch6 -p1 -b .linux-nomaplibrary
# all java binaries must be removed from the sources
find . -name '*.jar' -exec rm -f '{}' \;
@ -113,6 +114,9 @@ rm -rf %{buildroot}
%changelog
* Sun Nov 30 2008 Colin Walters <walters@redhat.com> - 3.0.9-2
- Fix library mapping, remove upstreamed patches
* Fri Oct 31 2008 Colin Walters <walters@redhat.com> - 3.0.9-1
- Rebase on upstream 3.0.9