From a54bf0a93da789c7b9c6e8c7d5b47761c225e61b Mon Sep 17 00:00:00 2001 From: William Deegan Date: Tue, 2 Oct 2018 10:27:23 -0700 Subject: Changed to allow scons java logic to find install for win32. Also add declspec in c file which is sole object in DLL to ensure mslink creates the expected .LIB file. --- test/Java/multi-step.py | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/test/Java/multi-step.py b/test/Java/multi-step.py index 01a3163..33e2a5f 100644 --- a/test/Java/multi-step.py +++ b/test/Java/multi-step.py @@ -35,6 +35,7 @@ import os import TestSCons test = TestSCons.TestSCons() +# test.verbose_set(1) where_javac, java_version = test.java_where_javac() where_javah = test.java_where_javah() @@ -50,9 +51,6 @@ if not swig: if test.javac_is_gcj: test.skip_test('Test not valid for gcj (gnu java); skipping test(s).\n') - - - test.subdir(['src'], ['src', 'HelloApplet'], ['src', 'HelloApplet', 'com'], @@ -75,9 +73,7 @@ test.subdir(['src'], test.write(['SConstruct'], """\ import os,sys env=Environment(tools = ['default', 'javac', 'javah', 'swig'], - CPPPATH=%(where_java_include)s, - JAVAC = r'%(where_javac)s', - JAVAH = r'%(where_javah)s') + CPPPATH=["$JAVAINCLUDES"]) Export('env') env.PrependENVPath('PATH',os.environ.get('PATH',[])) env['INCPREFIX']='-I' @@ -154,6 +150,9 @@ public class Hello extends Applet { test.write(['src', 'javah', 'MyID.cc'], """\ #include "MyID.h" +#ifdef _MSC_VER +__declspec(dllexport) +#endif int getMyID() { return 0; -- cgit v0.12