How to load the jna jar file before cffi?
Mark Evenson
evenson at panix.com
Sat May 13 20:21:17 UTC 2017
On 5/12/17 15:36, Mirko Vukovic wrote:
[…]
> I don't have jna.asd anywhere on my computer
It is packaged as part of `abcl-contrib.jar`.
[…]
> I looked at abcl-asdf in the provided link and did some checking from
> within ABCL.
> The outputs of abcl-asdf::find-mvn, abcl-asdf::mvn-version were OK.
> Interestingly, I don't have abcl-asdf:mvn-home defined. Is my asdf
> 3.1.7.27 obsolete?
It shouldn't be obsolete, as it is packaged as part of `abcl.jar`.
>
>
>> 2. Without trying to load CFFI, does the following form load JNA from a
>> fresh REPL?
>>
>> (require :abcl-contrib)
>>
> returns NIL
This indicates that for some reason your installation cannot locate
abcl-contrib.jar.
For an ABCL installed via MacPorts, one can show the following details
of the setup that may give a bit of insight into what a "healthy"
version might look like:
--
illin:~$ which abcl
/opt/local/bin/abcl
illin:~$ cat /opt/local/bin/abcl
#!/bin/sh
# abcl.in
# Copyright (C) 2004 Peter Graves
# Copyright (C) 2009 Erik Huelsmann
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
USA.
exec
/Library/Java/JavaVirtualMachines/jdk1.8.0_102.jdk/Contents/Home/jre/bin/java
\
-cp /opt/local/share/java/abcl/abcl.jar:"$CLASSPATH" \
\
org.armedbear.lisp.Main \
"$@"
illin:~$ ls -l /opt/local/share/java/abcl/
total 20688
drwxr-xr-x 5 root admin 170 Oct 9 2016 ./
drwxr-xr-x 11 root admin 374 May 7 08:10 ../
-rwxr-xr-x 1 root admin 978 Oct 9 2016 abcl*
-rw-r--r-- 1 root admin 53291 Oct 9 2016 abcl-contrib.jar
-rw-r--r-- 1 root admin 10530809 Oct 9 2016 abcl.jar
illin:~$ abcl --noinit
Armed Bear Common Lisp 1.4.0
Java 1.8.0_102 Oracle Corporation
Java HotSpot(TM) 64-Bit Server VM
Low-level initialization completed in 0.251 seconds.
Startup completed in 1.171 seconds.
Type ":help" for a list of available commands.
CL-USER(1): (require :abcl-contrib)
Using probed value of abcl-contrib:
'/opt/local/share/java/abcl/abcl-contrib.jar'.
Added jar:file:/opt/local/share/java/abcl/abcl-contrib.jar!/quicklisp/
to ASDF.
Added jar:file:/opt/local/share/java/abcl/abcl-contrib.jar!/mvn/ to ASDF.
Added jar:file:/opt/local/share/java/abcl/abcl-contrib.jar!/jss/ to ASDF.
Added jar:file:/opt/local/share/java/abcl/abcl-contrib.jar!/jfli/ to ASDF.
Added jar:file:/opt/local/share/java/abcl/abcl-contrib.jar!/asdf-jar/ to
ASDF.
Added jar:file:/opt/local/share/java/abcl/abcl-contrib.jar!/abcl-asdf/
to ASDF.
("uiop" "UIOP" "LOOP" "asdf" "ASDF" "ABCL-CONTRIB")
Cl-USER(2):
--
How did you install ABCL? There should be two jar files, 'abcl.jar' and
'abcl-contrib.jar' which should both be located in the same directory.
At runtime, when satisfying the "(require :abcl-contrib)", ABCL
introspects the classpath on which it is launched to probe for
'abcl-contrib.jar'
Maybe you are using a custom invocation script?
A few more details on how you have installed ABCL locally and how you
are invoking it would be helpful (i.e. "I downloaded abcl-1.4.0-bin.zip;
unzipped in a directory, and I invoke it with this command").
--
"A screaming comes across the sky. It has happened before, but there
is nothing to compare to it now."
More information about the armedbear-devel
mailing list