Skip to content

Commit

Permalink
add java-17-openjdk (#5610)
Browse files Browse the repository at this point in the history
* add java-17-openjdk

* update to v17.0.6+7
* comcerto2k is not supported (toolchain has gcc 4.9.3)
* fix freetype dependency
* update build properties
- remove obsolete x-libraries
- fix build for 32-bit arm archs (shenandoahgc not supported)
- remove configure warnings: move arguments from environment to command line
- fix build of ARMv7
- remove build of jvm variant zero

* adjust build configuration
* update to java release 10
* change code optimization from -Os to -O2
- this gives a little bit more performance (2% with SciMark 2.0a)

* Added Debian patches and hotspot target build
(cherry picked from commit 79c239d)

* update license information

---------

Co-authored-by: Bjarne Saltbæk <arnebjarne72@hotmail.com>
  • Loading branch information
hgy59 and arnebjarne authored Feb 24, 2023
1 parent 19af0ec commit 5a59224
Show file tree
Hide file tree
Showing 39 changed files with 2,695 additions and 0 deletions.
123 changes: 123 additions & 0 deletions cross/java-17-openjdk/Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,123 @@
PKG_NAME = java-17-openjdk
JAVA_REPO_NAME = jdk17u
JAVA_NAME = jdk
JAVA_RELEASE = 10
JAVA_VERSION = 17.0.6
PKG_VERS = $(JAVA_VERSION).$(JAVA_RELEASE)
PKG_EXT = tar.gz
PKG_DIST_NAME = $(JAVA_NAME)-$(JAVA_VERSION)+$(JAVA_RELEASE).$(PKG_EXT)
PKG_DIST_SITE = https://github.com/openjdk/$(JAVA_REPO_NAME)/archive
PKG_DIR = $(JAVA_REPO_NAME)-$(JAVA_NAME)-$(JAVA_VERSION)-$(JAVA_RELEASE)

# build instructions:
# https://openjdk.java.net/groups/build/doc/building.html

BUILD_DEPENDS = native/openjdk-17 native/zip
# Dependencies required at build time only:
BUILD_DEPENDS += cross/cups
BUILD_DEPENDS += cross/alsa-lib
BUILD_DEPENDS += cross/libX11
BUILD_DEPENDS += cross/libXrender

# Dependencies used as system dependencies:
DEPENDS = cross/alsa-lib
DEPENDS += cross/fontconfig
DEPENDS += cross/libffi
DEPENDS += cross/zlib
DEPENDS += cross/libpng
DEPENDS += cross/libjpeg
DEPENDS += cross/giflib
DEPENDS += cross/lcms2

ZIP_BIN_DIR = $(realpath $(WORK_DIR)/../../../native/zip/work-native/install/usr/local/bin)
ENV += PATH=$$PATH:$(ZIP_BIN_DIR)

HOMEPAGE = https://openjdk.org/projects/jdk/17/
COMMENT = OpenJDK 17 is the open-source reference implementation of version 17 of the Java SE Platform as specified by JSR 390 in the Java Community Process.
LICENSE = GPLv2 with the Classpath Exception

# Use our own configure since the one supplied by openjdk has no shebang
CONFIGURE_TARGET = java-17-openjdk_configure

# Force openjdk to install into the package install folder
PRE_COMPILE_TARGET = java-17-openjdk_pre_compile

# Fix symlinks
POST_INSTALL_TARGET = java-17-openjdk_post_compile

CONFIGURE_ARGS = --openjdk-target=$(TC_TARGET)
CONFIGURE_ARGS += --with-boot-jdk=$(WORK_DIR)/../../../native/openjdk-17/work-native/jdk-17
CONFIGURE_ARGS += --with-version-build=$(JAVA_RELEASE)
CONFIGURE_ARGS += --with-version-pre=
CONFIGURE_ARGS += --with-version-opt=LTS
CONFIGURE_ARGS += --with-native-debug-symbols=none
CONFIGURE_ARGS += --prefix=$(INSTALL_PREFIX)
CONFIGURE_ARGS += --with-zlib=system
CONFIGURE_ARGS += --with-libjpeg=system
CONFIGURE_ARGS += --with-giflib=system
CONFIGURE_ARGS += --with-libpng=system
CONFIGURE_ARGS += --with-lcms=system
CONFIGURE_ARGS += --with-alsa=$(INSTALL_DIR)/$(INSTALL_PREFIX)
CONFIGURE_ARGS += --with-stdc++lib=dynamic
CONFIGURE_ARGS += --disable-javac-server
CONFIGURE_ARGS += --disable-warnings-as-errors
CONFIGURE_ARGS += --with-cups=$(INSTALL_DIR)/$(INSTALL_PREFIX)
CONFIGURE_ARGS += --with-fontconfig=$(INSTALL_DIR)/$(INSTALL_PREFIX)
CONFIGURE_ARGS += --with-freetype=system
CONFIGURE_ARGS += --with-freetype-include=$(INSTALL_DIR)/$(INSTALL_PREFIX)/include/freetype2
CONFIGURE_ARGS += --with-freetype-lib=$(INSTALL_DIR)/$(INSTALL_PREFIX)/lib
CONFIGURE_ARGS += --with-extra-cflags="$(CFLAGS) -fno-stack-protector -Wno-deprecated-declarations"
CONFIGURE_ARGS += --with-extra-cxxflags="$(CPPFLAGS) -fno-stack-protector -Wno-deprecated-declarations"
CONFIGURE_ARGS += --with-extra-ldflags="$(LDFLAGS) -Xlinker -z -Xlinker relro -Xlinker -Bsymbolic-functions"
CONFIGURE_ARGS += --with-libffi=$(INSTALL_DIR)/$(INSTALL_PREFIX)
CONFIGURE_ARGS += --disable-manpages
CONFIGURE_ARGS += --with-cacerts-file=/etc/ssl/certs/ca-certificates.crt
CONFIGURE_ARGS += --with-cacerts-src=/etc/ssl/certs
# Disable all GUI related
CONFIGURE_ARGS += --enable-headless-only
# customize for SynoCommunity
CONFIGURE_ARGS += --with-vendor-name=SynoCommunity
CONFIGURE_ARGS += --with-vendor-url=https://synocommunity.com/package/java-17-openjdk
CONFIGURE_ARGS += --with-vendor-bug-url=https://github.com/SynoCommunity/spksrc/issues
CONFIGURE_ARGS += --with-vendor-vm-bug-url=https://github.com/SynoCommunity/spksrc/issues

# arguments not taken from environment
CONFIGURE_ARGS += READELF=$(READELF)
CONFIGURE_ARGS += AR=$(AR)
CONFIGURE_ARGS += STRIP=$(STRIP)
CONFIGURE_ARGS += NM=$(NM)
CONFIGURE_ARGS += OBJCOPY=$(OBJCOPY)
CONFIGURE_ARGS += OBJDUMP=$(OBJDUMP)

# Build images twice, second time with newly built JDK
COMPILE_MAKE_OPTIONS += product-images

PATCHES_LEVEL = 1

ADDITIONAL_CFLAGS = -O2

# Filter out any -jN since java's configure will autodetect number of CPU's
# Use make JOBS=N to set number of CPU's in this package
DISABLE_PARALLEL_MAKE = 1
COMPILE_MAKE_OPTIONS += JOBS=$(NCPUS)

include ../../mk/spksrc.cross-cc.mk

.PHONY: java-17-openjdk_configure
# Use CONFIGURE_ARGS instead of REAL_CONFIGURE_ARGS to ignore TC_CONFIGURE_ARGS
# Disable the normal host build target triplets since openjdk uses its own openjdk-target
# Avoid the use of $(RUN) since configure complains about env variables
java-17-openjdk_configure:
cd $(WORK_DIR)/$(PKG_DIR) && PATH=$$PATH:$(ZIP_BIN_DIR) && bash ./configure $(CONFIGURE_ARGS)

.PHONY: java-17-openjdk_pre_compile
# As DESTDIR is not supported we must patch the make file for make install.
java-17-openjdk_pre_compile:
sed -i -e "s|\$$(INSTALL_PREFIX)|$(STAGING_INSTALL_PREFIX)|g" $(WORK_DIR)/$(PKG_DIR)/make/Install.gmk

.PHONY: java-17-openjdk_post_compile
java-17-openjdk_post_compile:
@cd $(STAGING_INSTALL_PREFIX)/bin && ln -sf ../jvm/openjdk-$(JAVA_VERSION)/bin/* .
@cp -pf $(WORK_DIR)/$(PKG_DIR)/LICENSE $(STAGING_INSTALL_PREFIX)/jvm/openjdk-$(JAVA_VERSION)/
@cp -pf $(WORK_DIR)/$(PKG_DIR)/ADDITIONAL_LICENSE_INFO $(STAGING_INSTALL_PREFIX)/jvm/openjdk-$(JAVA_VERSION)/
@cp -pf $(WORK_DIR)/$(PKG_DIR)/ASSEMBLY_EXCEPTION $(STAGING_INSTALL_PREFIX)/jvm/openjdk-$(JAVA_VERSION)/
157 changes: 157 additions & 0 deletions cross/java-17-openjdk/PLIST
Original file line number Diff line number Diff line change
@@ -0,0 +1,157 @@
lnk:bin/jar
lnk:bin/jarsigner
lnk:bin/java
lnk:bin/javac
lnk:bin/javadoc
lnk:bin/javap
lnk:bin/jcmd
lnk:bin/jconsole
lnk:bin/jdb
lnk:bin/jdeprscan
lnk:bin/jdeps
lnk:bin/jfr
lnk:bin/jimage
lnk:bin/jinfo
lnk:bin/jlink
lnk:bin/jmap
lnk:bin/jmod
lnk:bin/jpackage
lnk:bin/jps
lnk:bin/jrunscript
lnk:bin/jshell
lnk:bin/jstack
lnk:bin/jstat
lnk:bin/jstatd
lnk:bin/keytool
lnk:bin/rmiregistry
lnk:bin/serialver
bin:jvm/openjdk-17.0.6/bin/*
rsc:jvm/openjdk-17.0.6/conf/
rsc:jvm/openjdk-17.0.6/include/classfile_constants.h
rsc:jvm/openjdk-17.0.6/include/jawt.h
rsc:jvm/openjdk-17.0.6/include/jdwpTransport.h
rsc:jvm/openjdk-17.0.6/include/jni.h
rsc:jvm/openjdk-17.0.6/include/jvmti.h
rsc:jvm/openjdk-17.0.6/include/jvmticmlr.h
rsc:jvm/openjdk-17.0.6/include/linux/jawt_md.h
rsc:jvm/openjdk-17.0.6/include/linux/jni_md.h
rsc:jvm/openjdk-17.0.6/jmods/java.base.jmod
rsc:jvm/openjdk-17.0.6/jmods/java.compiler.jmod
rsc:jvm/openjdk-17.0.6/jmods/java.datatransfer.jmod
rsc:jvm/openjdk-17.0.6/jmods/java.desktop.jmod
rsc:jvm/openjdk-17.0.6/jmods/java.instrument.jmod
rsc:jvm/openjdk-17.0.6/jmods/java.logging.jmod
rsc:jvm/openjdk-17.0.6/jmods/java.management.jmod
rsc:jvm/openjdk-17.0.6/jmods/java.management.rmi.jmod
rsc:jvm/openjdk-17.0.6/jmods/java.naming.jmod
rsc:jvm/openjdk-17.0.6/jmods/java.net.http.jmod
rsc:jvm/openjdk-17.0.6/jmods/java.prefs.jmod
rsc:jvm/openjdk-17.0.6/jmods/java.rmi.jmod
rsc:jvm/openjdk-17.0.6/jmods/java.scripting.jmod
rsc:jvm/openjdk-17.0.6/jmods/java.se.jmod
rsc:jvm/openjdk-17.0.6/jmods/java.security.jgss.jmod
rsc:jvm/openjdk-17.0.6/jmods/java.security.sasl.jmod
rsc:jvm/openjdk-17.0.6/jmods/java.smartcardio.jmod
rsc:jvm/openjdk-17.0.6/jmods/java.sql.jmod
rsc:jvm/openjdk-17.0.6/jmods/java.sql.rowset.jmod
rsc:jvm/openjdk-17.0.6/jmods/java.transaction.xa.jmod
rsc:jvm/openjdk-17.0.6/jmods/java.xml.crypto.jmod
rsc:jvm/openjdk-17.0.6/jmods/java.xml.jmod
rsc:jvm/openjdk-17.0.6/jmods/jdk.accessibility.jmod
rsc:jvm/openjdk-17.0.6/jmods/jdk.attach.jmod
rsc:jvm/openjdk-17.0.6/jmods/jdk.charsets.jmod
rsc:jvm/openjdk-17.0.6/jmods/jdk.compiler.jmod
rsc:jvm/openjdk-17.0.6/jmods/jdk.crypto.cryptoki.jmod
rsc:jvm/openjdk-17.0.6/jmods/jdk.crypto.ec.jmod
rsc:jvm/openjdk-17.0.6/jmods/jdk.dynalink.jmod
rsc:jvm/openjdk-17.0.6/jmods/jdk.editpad.jmod
rsc:jvm/openjdk-17.0.6/jmods/jdk.httpserver.jmod
rsc:jvm/openjdk-17.0.6/jmods/jdk.incubator.foreign.jmod
rsc:jvm/openjdk-17.0.6/jmods/jdk.incubator.vector.jmod
rsc:jvm/openjdk-17.0.6/jmods/jdk.internal.ed.jmod
rsc:jvm/openjdk-17.0.6/jmods/jdk.internal.jvmstat.jmod
rsc:jvm/openjdk-17.0.6/jmods/jdk.internal.le.jmod
rsc:jvm/openjdk-17.0.6/jmods/jdk.internal.opt.jmod
rsc:jvm/openjdk-17.0.6/jmods/jdk.jartool.jmod
rsc:jvm/openjdk-17.0.6/jmods/jdk.javadoc.jmod
rsc:jvm/openjdk-17.0.6/jmods/jdk.jcmd.jmod
rsc:jvm/openjdk-17.0.6/jmods/jdk.jconsole.jmod
rsc:jvm/openjdk-17.0.6/jmods/jdk.jdeps.jmod
rsc:jvm/openjdk-17.0.6/jmods/jdk.jdi.jmod
rsc:jvm/openjdk-17.0.6/jmods/jdk.jdwp.agent.jmod
rsc:jvm/openjdk-17.0.6/jmods/jdk.jfr.jmod
rsc:jvm/openjdk-17.0.6/jmods/jdk.jlink.jmod
rsc:jvm/openjdk-17.0.6/jmods/jdk.jpackage.jmod
rsc:jvm/openjdk-17.0.6/jmods/jdk.jshell.jmod
rsc:jvm/openjdk-17.0.6/jmods/jdk.jsobject.jmod
rsc:jvm/openjdk-17.0.6/jmods/jdk.jstatd.jmod
rsc:jvm/openjdk-17.0.6/jmods/jdk.localedata.jmod
rsc:jvm/openjdk-17.0.6/jmods/jdk.management.agent.jmod
rsc:jvm/openjdk-17.0.6/jmods/jdk.management.jfr.jmod
rsc:jvm/openjdk-17.0.6/jmods/jdk.management.jmod
rsc:jvm/openjdk-17.0.6/jmods/jdk.naming.dns.jmod
rsc:jvm/openjdk-17.0.6/jmods/jdk.naming.rmi.jmod
rsc:jvm/openjdk-17.0.6/jmods/jdk.net.jmod
rsc:jvm/openjdk-17.0.6/jmods/jdk.nio.mapmode.jmod
rsc:jvm/openjdk-17.0.6/jmods/jdk.random.jmod
rsc:jvm/openjdk-17.0.6/jmods/jdk.sctp.jmod
rsc:jvm/openjdk-17.0.6/jmods/jdk.security.auth.jmod
rsc:jvm/openjdk-17.0.6/jmods/jdk.security.jgss.jmod
rsc:jvm/openjdk-17.0.6/jmods/jdk.unsupported.desktop.jmod
rsc:jvm/openjdk-17.0.6/jmods/jdk.unsupported.jmod
rsc:jvm/openjdk-17.0.6/jmods/jdk.xml.dom.jmod
rsc:jvm/openjdk-17.0.6/jmods/jdk.zipfs.jmod
rsc:jvm/openjdk-17.0.6/legal/
rsc:jvm/openjdk-17.0.6/lib/ct.sym
bin:jvm/openjdk-17.0.6/lib/jexec
rsc:jvm/openjdk-17.0.6/lib/jfr/default.jfc
rsc:jvm/openjdk-17.0.6/lib/jfr/profile.jfc
rsc:jvm/openjdk-17.0.6/lib/jrt-fs.jar
bin:jvm/openjdk-17.0.6/lib/jspawnhelper
rsc:jvm/openjdk-17.0.6/lib/jvm.cfg
lib:jvm/openjdk-17.0.6/lib/libattach.so
lib:jvm/openjdk-17.0.6/lib/libawt.so
lib:jvm/openjdk-17.0.6/lib/libawt_headless.so
lib:jvm/openjdk-17.0.6/lib/libdt_socket.so
lib:jvm/openjdk-17.0.6/lib/libextnet.so
lib:jvm/openjdk-17.0.6/lib/libfontmanager.so
lib:jvm/openjdk-17.0.6/lib/libinstrument.so
lib:jvm/openjdk-17.0.6/lib/libj2gss.so
lib:jvm/openjdk-17.0.6/lib/libj2pcsc.so
lib:jvm/openjdk-17.0.6/lib/libj2pkcs11.so
lib:jvm/openjdk-17.0.6/lib/libjaas.so
lib:jvm/openjdk-17.0.6/lib/libjava.so
lib:jvm/openjdk-17.0.6/lib/libjavajpeg.so
lib:jvm/openjdk-17.0.6/lib/libjawt.so
lib:jvm/openjdk-17.0.6/lib/libjdwp.so
lib:jvm/openjdk-17.0.6/lib/libjimage.so
lib:jvm/openjdk-17.0.6/lib/libjli.so
lib:jvm/openjdk-17.0.6/lib/libjsig.so
lib:jvm/openjdk-17.0.6/lib/libjsound.so
lib:jvm/openjdk-17.0.6/lib/liblcms.so
lib:jvm/openjdk-17.0.6/lib/libmanagement.so
lib:jvm/openjdk-17.0.6/lib/libmanagement_agent.so
lib:jvm/openjdk-17.0.6/lib/libmanagement_ext.so
lib:jvm/openjdk-17.0.6/lib/libmlib_image.so
lib:jvm/openjdk-17.0.6/lib/libnet.so
lib:jvm/openjdk-17.0.6/lib/libnio.so
lib:jvm/openjdk-17.0.6/lib/libprefs.so
lib:jvm/openjdk-17.0.6/lib/librmi.so
lib:jvm/openjdk-17.0.6/lib/libsctp.so
lib:jvm/openjdk-17.0.6/lib/libsyslookup.so
lib:jvm/openjdk-17.0.6/lib/libverify.so
lib:jvm/openjdk-17.0.6/lib/libzip.so
rsc:jvm/openjdk-17.0.6/lib/modules
rsc:jvm/openjdk-17.0.6/lib/psfont.properties.ja
rsc:jvm/openjdk-17.0.6/lib/psfontj2d.properties
rsc:jvm/openjdk-17.0.6/lib/security/blocked.certs
rsc:jvm/openjdk-17.0.6/lib/security/cacerts
rsc:jvm/openjdk-17.0.6/lib/security/default.policy
rsc:jvm/openjdk-17.0.6/lib/security/public_suffix_list.dat
lib:jvm/openjdk-17.0.6/lib/server/libjsig.so
lib:jvm/openjdk-17.0.6/lib/server/libjvm.so
rsc:jvm/openjdk-17.0.6/lib/tzdb.dat
rsc:jvm/openjdk-17.0.6/release
rsc:jvm/openjdk-17.0.6/LICENSE
rsc:jvm/openjdk-17.0.6/ADDITIONAL_LICENSE_INFO
rsc:jvm/openjdk-17.0.6/ASSEMBLY_EXCEPTION
3 changes: 3 additions & 0 deletions cross/java-17-openjdk/digests
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
jdk-17.0.6+10.tar.gz SHA1 356707bdb2b4bc6811d6392295cb7b6522dbf6ab
jdk-17.0.6+10.tar.gz SHA256 331bad1f80e98761eb9692863146fec647db573db5a5efa5b9bd6326d53a3472
jdk-17.0.6+10.tar.gz MD5 ab73f8d93b1529dd6e4b4b0caf72adda
11 changes: 11 additions & 0 deletions cross/java-17-openjdk/patches/002.hotspot-mips-align.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
--- a/src/hotspot/cpu/zero/zeroInterpreter_zero.cpp
+++ b/src/hotspot/cpu/zero/zeroInterpreter_zero.cpp
@@ -418,7 +418,7 @@ int ZeroInterpreter::native_entry(Method
ThreadStateTransition::transition_from_java(thread, _thread_in_native);

// Make the call
- intptr_t result[4 - LogBytesPerWord];
+ intptr_t result[4 - LogBytesPerWord] __attribute__((__aligned__(__alignof__(double))));
ffi_call(handler->cif(), (void (*)()) function, result, arguments);

// Change the thread state back to _thread_in_Java and ensure it
12 changes: 12 additions & 0 deletions cross/java-17-openjdk/patches/003.icc_loading_with_symlink.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
--- a/src/java.desktop/share/classes/java/awt/color/ICC_Profile.java
+++ b/src/java.desktop/share/classes/java/awt/color/ICC_Profile.java
@@ -1327,9 +1327,6 @@ public class ICC_Profile implements Seri
dir = st.nextToken();
fullPath = dir + File.separatorChar + fileName;
f = new File(fullPath);
- if (!isChildOf(f, dir)) {
- f = null;
- }
}
}

Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
Index: b/src/java.desktop/unix/classes/sun/awt/X11/XWindowPeer.java
===================================================================
--- a/src/java.desktop/unix/classes/sun/awt/X11/XWindowPeer.java
+++ b/src/java.desktop/unix/classes/sun/awt/X11/XWindowPeer.java
@@ -1260,6 +1260,7 @@ class XWindowPeer extends XPanelPeer imp

boolean isOverrideRedirect() {
return XWM.getWMID() == XWM.OPENLOOK_WM ||
+ XWM.getWMID() == XWM.COMPIZ_WM ||
Window.Type.POPUP.equals(getWindowType());
}

54 changes: 54 additions & 0 deletions cross/java-17-openjdk/patches/005.libpcsclite-dlopen.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
--- a/src/java.smartcardio/unix/classes/sun/security/smartcardio/PlatformPCSC.java
+++ b/src/java.smartcardio/unix/classes/sun/security/smartcardio/PlatformPCSC.java
@@ -46,6 +46,7 @@ class PlatformPCSC {

private final static String PROP_NAME = "sun.security.smartcardio.library";

+ private final static String LIB0 = "libpcsclite.so.1";
private final static String LIB1 = "/usr/$LIBISA/libpcsclite.so";
private final static String LIB2 = "/usr/local/$LIBISA/libpcsclite.so";
private final static String PCSC_FRAMEWORK = "/System/Library/Frameworks/PCSC.framework/Versions/Current/PCSC";
@@ -98,40 +99,9 @@ class PlatformPCSC {
if (lib.length() != 0) {
return lib;
}
- lib = expand(LIB1);
- if (new File(lib).isFile()) {
- // if LIB1 exists, use that
- return lib;
- }
- lib = expand(LIB2);
- if (new File(lib).isFile()) {
- // if LIB2 exists, use that
- return lib;
- }
-
- // As of macos 11, framework libraries have been removed from the file
- // system, but in such a way that they can still be dlopen()ed, even
- // though they can no longer be open()ed.
- //
- // https://developer.apple.com/documentation/macos-release-notes/macos-big-sur-11_0_1-release-notes
- //
- // """New in macOS Big Sur 11.0.1, the system ships with a built-in
- // dynamic linker cache of all system-provided libraries. As part of
- // this change, copies of dynamic libraries are no longer present on
- // the filesystem. Code that attempts to check for dynamic library
- // presence by looking for a file at a path or enumerating a directory
- // will fail. Instead, check for library presence by attempting to
- // dlopen() the path, which will correctly check for the library in the
- // cache."""
- //
- // The directory structure remains otherwise intact, so check for
- // existence of the containing directory instead of the file.
- lib = PCSC_FRAMEWORK;
- if (new File(lib).getParentFile().isDirectory()) {
- // if PCSC.framework exists, use that
- return lib;
- }
- throw new IOException("No PC/SC library found on this system");
+ // let dlopen do the work
+ lib = LIB0;
+ return lib;
}

private static native void initialize(String libraryName);
Loading

0 comments on commit 5a59224

Please sign in to comment.