Need admin help with unsubscribe

2011-01-09 Thread Imre András
Hello all,

Sorry for posting this, but unsubscribe did not work for me. Please refer to my 
second attempt below. The first was on 01/12/2010.


Thanks,
  András


--Eredeti üzenet--
Dátum:2010. december 7., kedd, 02:16:57
Feladó:   Imre András ia...@freemail.hu
Tárgy:unsubscribe
Címzett:  pylucene-dev-unsubscr...@lucene.apache.org
unsubscribe



Re: Unresolved external symbol errors when linking example native c++ code that uses jcc

2010-10-27 Thread Imre András


Andi Vajda va...@apache.org írta:

Using JCC in your project is a two-step process. First get JCC to generate 
the C++ wraper code for the Java code you want access to. This is, 
hopefully, well documented on the JCC site [1]. Then take that generated 
code tree and the necessary JCC runtime source files [2] and add them to 
your project's build. Any file that includes Python.h unconditionally is 
not part of the code you should include.

This step is ok.



The last problem you found has to do with the fact that the env global 
variable is declared in a file only needed by the Python runtime; jcc.cpp 
should not be included in your project and you need to declare that global 
in code of yours instead.


In addition to files mentioned under [2], it seems that JArray.h is also needed.
As I see JCCEnv.h dllexports JCCEnv *env (_jcc_shared is not defined). The link 
target for my code is an exe, and I keep getting unresolved external symbol 
errors for class JCCEnv * env.

At first I tried to hack around, and modify the *env ptr definition (strip the 
dll export), but that resulted in already defined errors. I guess the last 
chance is to create a separate project for jcc runtime and its generated code 
with a dll target. Then I would use that with dllimport in the code that uses 
that layer.


Regards,
  András

...
Cheers !

Andi..

[1] http://lucene.apache.org/pylucene/jcc/documentation/readme.html
[2] JObject.cpp, JCCEnv.cpp, JCCEnv.h
[3] http://java.sun.com/docs/books/jni/html/invoke.html


Re: Unresolved external symbol errors when linking example native c++ code that uses jcc

2010-10-24 Thread Imre András
Hi Andi,

Sorry, I do not get your point. There was no error for jcc generating the code 
that wraps Native2Java.class. The problem occurs during linking some client 
code which uses this generated wrapper. Do I miss something here?

Any tips where these symbols may emerge from? I really could not track or see 
them referenced in JCCEnv.cpp, really.

Thanks,
  András


Andi Vajda va...@apache.org írta:

On Oct 21, 2010, at 4:39, Imre András ia...@freemail.hu wrote:

 Hi list,

 I intend to use jcc to ease calling Java code from native code. I  
 managed to build and install it. Now I try to build my first test  
 code from within MS VS 2010 Win32 console app project. Despite  
 setting up the libs and includes I still get linker errors:

I'm not sure this link line makes sense. To get an idea of what the  
correct link line looks like, get jcc to build a python extension and  
take a close look at the link line it generates as an example for your  
C++ only case.

Andi..



 --
 Link:
 C:\Program Files\Microsoft Visual Studio 10.0\VC\bin\link.exe / 
 ERRORREPORT:PROMPT /OUT:C:\out\app\PeldaProgram\ZipBe\bin\test\src 
 \Debug\jcc.exe /INCREMENTAL /NOLOGO python27.lib _jcc.lib jvm.lib  
 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib  
 advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib  
 odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib  
 comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib  
 uuid.lib odbc32.lib odbccp32.lib /MANIFEST /ManifestFile:Debug 
 \jcc.exe.intermediate.manifest /MANIFESTUAC:level='asInvoker'  
 uiAccess='false' /DEBUG /PDB:C:\out\app\PeldaProgram\ZipBe\bin\test 
 \src\Debug\jcc.pdb /SUBSYSTEM:CONSOLE /TLBID:1 /DYNAMICBASE / 
 NXCOMPAT /IMPLIB:C:\out\app\PeldaProgram\ZipBe\bin\test\src\Debug 
 \jcc.lib /MACHINE:X86 Debug\jcc.exe.embed.manifest.res
 Debug\jcc.obj
 Debug\stdafx.obj
 Debug\__wrap__.obj
 Creating library C:\out\app\PeldaProgram\ZipBe\bin\test\src\Debug 
 \jcc.lib and object C:\out\app\PeldaProgram\ZipBe\bin\test\src\Debug 
 \jcc.exp
 1jcc.obj : error LNK2001: unresolved external symbol unsigned long  
 VM_ENV (?VM_ENV@@3KA)
 1stdafx.obj : error LNK2001: unresolved external symbol unsigned  
 long VM_ENV (?VM_ENV@@3KA)
 1__wrap__.obj : error LNK2001: unresolved external symbol unsigned  
 long VM_ENV (?VM_ENV@@3KA)
 1jcc.obj : error LNK2001: unresolved external symbol class JCCEnv  
 * env (?env@@3PAVJCCEnv@@A)
 1stdafx.obj : error LNK2001: unresolved external symbol class  
 JCCEnv * env (?env@@3PAVJCCEnv@@A)
 1__wrap__.obj : error LNK2001: unresolved external symbol class  
 JCCEnv * env (?env@@3PAVJCCEnv@@A)
 1C:\out\app\PeldaProgram\ZipBe\bin\test\src\Debug\jcc.exe : fatal  
 error LNK1120: 2 unresolved externals
 1Done Building Project C:\out\app\PeldaProgram\ZipBe\bin\test\jcc 
 \jcc.vcxproj (rebuild target(s)) -- FAILED.

 Build FAILED.

 Time Elapsed 00:00:12.60
 --


 jni.h and Native2Java.h (jcc generated from the java class I intend  
 to use in native c++ code) is added to stdafx.h. Now I have no idea  
 where the above symbols come from, and how should I resolve them.


 Regards,
 András




Unresolved external symbol errors when linking example native c++ code that uses jcc

2010-10-21 Thread Imre András
Hi list,

I intend to use jcc to ease calling Java code from native code. I managed to 
build and install it. Now I try to build my first test code from within MS VS 
2010 Win32 console app project. Despite setting up the libs and includes I 
still get linker errors:

--
Link:
C:\Program Files\Microsoft Visual Studio 10.0\VC\bin\link.exe 
/ERRORREPORT:PROMPT 
/OUT:C:\out\app\PeldaProgram\ZipBe\bin\test\src\Debug\jcc.exe /INCREMENTAL 
/NOLOGO python27.lib _jcc.lib jvm.lib kernel32.lib user32.lib gdi32.lib 
winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib 
uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib 
comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib 
odbc32.lib odbccp32.lib /MANIFEST 
/ManifestFile:Debug\jcc.exe.intermediate.manifest 
/MANIFESTUAC:level='asInvoker' uiAccess='false' /DEBUG 
/PDB:C:\out\app\PeldaProgram\ZipBe\bin\test\src\Debug\jcc.pdb 
/SUBSYSTEM:CONSOLE /TLBID:1 /DYNAMICBASE /NXCOMPAT 
/IMPLIB:C:\out\app\PeldaProgram\ZipBe\bin\test\src\Debug\jcc.lib /MACHINE:X86 
Debug\jcc.exe.embed.manifest.res
Debug\jcc.obj
Debug\stdafx.obj
Debug\__wrap__.obj
Creating library C:\out\app\PeldaProgram\ZipBe\bin\test\src\Debug\jcc.lib and 
object C:\out\app\PeldaProgram\ZipBe\bin\test\src\Debug\jcc.exp
1jcc.obj : error LNK2001: unresolved external symbol unsigned long VM_ENV 
(?VM_ENV@@3KA)
1stdafx.obj : error LNK2001: unresolved external symbol unsigned long VM_ENV 
(?VM_ENV@@3KA)
1__wrap__.obj : error LNK2001: unresolved external symbol unsigned long 
VM_ENV (?VM_ENV@@3KA)
1jcc.obj : error LNK2001: unresolved external symbol class JCCEnv * env 
(?env@@3PAVJCCEnv@@A)
1stdafx.obj : error LNK2001: unresolved external symbol class JCCEnv * env 
(?env@@3PAVJCCEnv@@A)
1__wrap__.obj : error LNK2001: unresolved external symbol class JCCEnv * env 
(?env@@3PAVJCCEnv@@A)
1C:\out\app\PeldaProgram\ZipBe\bin\test\src\Debug\jcc.exe : fatal error 
LNK1120: 2 unresolved externals
1Done Building Project 
C:\out\app\PeldaProgram\ZipBe\bin\test\jcc\jcc.vcxproj (rebuild target(s)) -- 
FAILED.

Build FAILED.

Time Elapsed 00:00:12.60
--


jni.h and Native2Java.h (jcc generated from the java class I intend to use in 
native c++ code) is added to stdafx.h. Now I have no idea where the above 
symbols come from, and how should I resolve them.


Regards,
András



Re: Unresolved external symbol errors when linking example native c++ code that uses jcc

2010-10-21 Thread Imre András
Hi Chris,

I did it on MS VS 2008, too. class JCCEnv * env still can not be resolved.

Regards,
  András

Christian Heimes li...@cheimes.de írta:
Am 21.10.2010 13:39, schrieb Imre András:
 Hi list,
 
 I intend to use jcc to ease calling Java code from native code. I managed to 
 build and install it. Now I try to build my first test code from within MS VS 
 2010 Win32 console app project. Despite setting up the libs and includes I 
 still get linker errors:

This may not be related to your problem but MS VS 2010 is not supported
by any current Python release. You have to use VS 2008.

Christian



Re: Unresolved external symbol errors when linking example native c++ code that uses jcc

2010-10-21 Thread Imre András
JCCEnv.h has the following:

...
#ifdef _jcc_shared
_DLL_IMPORT extern JCCEnv *env;
_DLL_IMPORT extern DWORD VM_ENV;
#else
_DLL_EXPORT extern JCCEnv *env;
_DLL_EXPORT extern DWORD VM_ENV;
#endif
...

I suspect here is the root of my linker problem. Where should this *env get 
resolved?


Thanks,
  András


Imre András ia...@freemail.hu írta:
Hi list,

I intend to use jcc to ease calling Java code from native code. I managed to 
build and install it. Now I try to build my first test code from within MS VS 
2010 Win32 console app project. Despite setting up the libs and includes I 
still get linker errors:

--
Link:
C:\Program Files\Microsoft Visual Studio 10.0\VC\bin\link.exe 
/ERRORREPORT:PROMPT 
/OUT:C:\out\app\PeldaProgram\ZipBe\bin\test\src\Debug\jcc.exe /INCREMENTAL 
/NOLOGO python27.lib _jcc.lib jvm.lib kernel32.lib user32.lib gdi32.lib 
winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib 
uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib 
comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib 
odbc32.lib odbccp32.lib /MANIFEST 
/ManifestFile:Debug\jcc.exe.intermediate.manifest 
/MANIFESTUAC:level='asInvoker' uiAccess='false' /DEBUG 
/PDB:C:\out\app\PeldaProgram\ZipBe\bin\test\src\Debug\jcc.pdb 
/SUBSYSTEM:CONSOLE /TLBID:1 /DYNAMICBASE /NXCOMPAT 
/IMPLIB:C:\out\app\PeldaProgram\ZipBe\bin\test\src\Debug\jcc.lib /MACHINE:X86 
Debug\jcc.exe.embed.manifest.res
Debug\jcc.obj
Debug\stdafx.obj
Debug\__wrap__.obj
Creating library C:\out\app\PeldaProgram\ZipBe\bin\test\src\Debug\jcc.lib and 
object C:\out\app\PeldaProgram\ZipBe\bin\test\src\Debug\jcc.exp
1jcc.obj : error LNK2001: unresolved external symbol unsigned long VM_ENV 
(?VM_ENV@@3KA)
1stdafx.obj : error LNK2001: unresolved external symbol unsigned long VM_ENV 
(?VM_ENV@@3KA)
1__wrap__.obj : error LNK2001: unresolved external symbol unsigned long 
VM_ENV (?VM_ENV@@3KA)
1jcc.obj : error LNK2001: unresolved external symbol class JCCEnv * env 
(?env@@3PAVJCCEnv@@A)
1stdafx.obj : error LNK2001: unresolved external symbol class JCCEnv * env 
(?env@@3PAVJCCEnv@@A)
1__wrap__.obj : error LNK2001: unresolved external symbol class JCCEnv * env 
(?env@@3PAVJCCEnv@@A)
1C:\out\app\PeldaProgram\ZipBe\bin\test\src\Debug\jcc.exe : fatal error 
LNK1120: 2 unresolved externals
1Done Building Project 
C:\out\app\PeldaProgram\ZipBe\bin\test\jcc\jcc.vcxproj (rebuild target(s)) -- 
FAILED.

Build FAILED.

Time Elapsed 00:00:12.60
--


jni.h and Native2Java.h (jcc generated from the java class I intend to use in 
native c++ code) is added to stdafx.h. Now I have no idea where the above 
symbols come from, and how should I resolve them.


Regards,
András