cpp header bindings

RCJ rmcjustino at gmail.com
Tue Jul 29 22:33:32 PDT 2008


Rui Justino Wrote:

Well once more sorry for the very long post.
Let me try to clarify the problem. I'm trying to create an interface from cpp to d with the following files.

./bcd/my4/thetest.d
./thetest.h
./thetest.cpp
./thetest.d
./header_tit.d

cpp files are working, but when i try to create bindings to that header file i get to a point were i receive the same error using 2 different approaches. For the binding there are two files, one created by BCD and the other by h2d ("./thetest.d" and "./bcd/my4/thetest.d").
With this 2 different approaches I receive the same exact error message, in 2 different versions of GDC.

I would be grateful if some one could show me my error.
> ----------------------------------------------------------------------------------------
> #gdmd header_tit.d thetest.o -L-lstdc++
> header_tit.o: In function `_Dmain':
> header_tit.d:(.text+0x20): undefined reference to `_D7thetest7TheTest7__ClassZ'
> header_tit.d:(.text+0x2f): undefined reference to `_D7thetest7TheTest5_ctorMUiZC7thetest7TheTest'
> collect2: ld returned 1 exit status
> ----------------------------------------------------------------------------------------


More information about the Digitalmars-d-learn mailing list