Hi!
I'm trying to build the JNI example, but the linker informs me that it
cannot open 'TEMPFILE'. I've tried to find out if the %TMP% or %TEMP%
variables are changed using an ant echo goal, but no luck just yet (it
won't run the task if the jar's not present). Any hints to solve this
would be most appreciated.
I might add that I'm not running as an Administrator, nor do I have
access to C:\WINDOWS\Temp, which of course is where the system vars are
pointing.
Here's a snippet of the build run:
D:\Eclipse\VersionTesting\jni-example>mvn -Dplatform=win32 -Ddebug
compile
[INFO] Scanning for projects...
[INFO] Reactor build order:
[INFO] JNI Example
[INFO] JNI - Java
[INFO] JNI - Natives
[INFO] JNI - DLL
[INFO]
------------------------------------------------------------------------
----
[INFO] Building JNI Example
[INFO] task-segment: [compile]
[INFO]
------------------------------------------------------------------------
----
[INFO] No goals needed for project - skipping
[INFO]
------------------------------------------------------------------------
----
[INFO] Building JNI - Java
[INFO] task-segment: [compile]
[INFO]
------------------------------------------------------------------------
----
[INFO] [resources:resources]
[INFO] Using default encoding to copy filtered resources.
[INFO] [compiler:compile]
[INFO] Nothing to compile - all classes are up to date
[INFO]
------------------------------------------------------------------------
----
[INFO] Building JNI - Natives
[INFO] task-segment: [compile]
[INFO]
------------------------------------------------------------------------
----
[INFO] No goals needed for project - skipping
[INFO]
------------------------------------------------------------------------
----
[INFO] Building JNI - DLL
[INFO] task-segment: [compile]
[INFO]
------------------------------------------------------------------------
----
[INFO] [native:initialize]
[INFO] [native:javah {execution: javah}]
[INFO] javah -o
D:\Eclipse\VersionTesting\jni-example\native\win32\target\custom-javah\H
2\target\classes;D:\Eclipse\VersionTesting\jni-example\java\target\class
es HelloWorld
[INFO] [native:resource-compile {execution: resource-compile}]
[INFO]
D:\Eclipse\VersionTesting\jni-example\native\win32\..\src\main\native\he
llo.rc is
[INFO] [native:compile]
[INFO] [native:link]
[INFO] link.exe /DEBUG /INCREMENTAL:NO /DLL oldnames.lib kernel32.lib
/out:D:\Eclipse\Ve
target\HelloWorld.obj
Microsoft (R) Incremental Linker Version 7.10.6030
Copyright (C) Microsoft Corporation. All rights reserved.
LINK : warning LNK4068: /MACHINE not specified; defaulting to X86
LINK : fatal error LNK1104: cannot open file 'TEMPFILE'
[INFO]
------------------------------------------------------------------------
[ERROR] BUILD ERROR
[INFO]
------------------------------------------------------------------------
[INFO] Error executing command line. Exit code:1104
Sincerely
Hans-Gunnar Vold