Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

JNAerator won't compile any source files #105

Open
DevCybran opened this issue Oct 23, 2015 · 0 comments
Open

JNAerator won't compile any source files #105

DevCybran opened this issue Oct 23, 2015 · 0 comments

Comments

@DevCybran
Copy link

Using JNAerator 0.12 on Windows 7 x64 with Visual Studio 2013, I am trying to generate a JAR with bindings for the libsodium library. I am using the following command line: "C:\Program Files\Java\jdk1.8.0_60\bin\java.exe" -jar jnaerator-0.12-shaded.jar -library sodium sodium.h libsodium.dll -mode Jar -preferJavac -runtime JNA > jnaerator.log 2>&1

This is the output JNAerator shows:

Okt 23, 2015 6:06:51 PM com.ochafik.admin.visualstudio.VisualStudioUtils getProp
INFORMATION: [environment] ProgramFiles(x86)=C:\Program Files (x86)
Okt 23, 2015 6:06:51 PM com.ochafik.admin.visualstudio.VisualStudioUtils getProp
INFORMATION: [environment] VISUAL_STUDIO_HOME=C:\Program Files (x86)\Microsoft Visual Studio 12.0
Okt 23, 2015 6:06:51 PM com.ochafik.admin.visualstudio.VisualStudioUtils getProp
INFORMATION: [environment] ProgramFiles(x86)=C:\Program Files (x86)
Okt 23, 2015 6:06:51 PM com.ochafik.admin.visualstudio.VisualStudioUtils getProp
INFORMATION: [environment] WINDOWS_SDK_HOME=C:\Program Files (x86)\Microsoft SDKs\Windows\v6.0A
Okt 23, 2015 6:06:51 PM com.ochafik.admin.visualstudio.VisualStudioUtils getProp
INFORMATION: [environment] VISUAL_STUDIO_INCLUDES=C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\include;C:\Program Files (x86)\Microsoft SDKs\Windows\v6.0A\Include
Auto-configuring parser...
Parsing native headers...
Normalizing parsed code...
Generating libraries...
Compiling JNAerated files...
java.lang.IllegalStateException: no source files
    at com.sun.tools.javac.main.Main.error(Main.java:186)
    at com.sun.tools.javac.main.Main.compile(Main.java:428)
    at com.sun.tools.javac.api.JavacTaskImpl.doCall(JavacTaskImpl.java:129)
    at com.sun.tools.javac.api.JavacTaskImpl.call(JavacTaskImpl.java:138)
    at com.ochafik.lang.compiler.CompilerUtils.compile(CompilerUtils.java:199)
    at com.ochafik.lang.jnaerator.JNAerator.jnaerate(JNAerator.java:1030)
    at com.ochafik.lang.jnaerator.JNAerator$1.finished(JNAerator.java:786)
    at com.ochafik.lang.jnaerator.JNAeratorCommandLineArgs$ArgsParser.parse(JNAeratorCommandLineArgs.java:162)
    at com.ochafik.lang.jnaerator.JNAerator.main(JNAerator.java:791)
    at com.ochafik.lang.jnaerator.JNAerator.main(JNAerator.java:203)
java.lang.IllegalStateException: no source files
    at com.ochafik.lang.jnaerator.JNAerator$1$2.setFinished(JNAerator.java:753)
    at com.ochafik.lang.jnaerator.JNAerator.jnaerate(JNAerator.java:1066)
    at com.ochafik.lang.jnaerator.JNAerator$1.finished(JNAerator.java:786)
    at com.ochafik.lang.jnaerator.JNAeratorCommandLineArgs$ArgsParser.parse(JNAeratorCommandLineArgs.java:162)
    at com.ochafik.lang.jnaerator.JNAerator.main(JNAerator.java:791)
    at com.ochafik.lang.jnaerator.JNAerator.main(JNAerator.java:203)
#
# ERROR: JNAeration failed !
#
#   java.lang.IllegalStateException: no source files
#

Afterwards, no JAR is present. The following files have been created: _jnaerator.choices, _jnaerator.macros.cpp, _jnaerator.normalizedParsed.cpp, _jnaerator.preprocessed.c, _jnaerator.rawParsed.cpp; where _jnaerator.choices is empty.

Using alternative modes or runtimes won't change anything. When using the eclipse compiler, only a usage help page is displayed and nothing compiled either.

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant