Add new comment

Using LibRaw directly within project

Hi,

I was wondering if it is possible to use the LibRaw sources directly within another project without building a library first, mostly for better debugging purposes (like using GDB).

On my system (win7 with mingw and eclipse cdt) I tried both adding the folders (libraw, src, internal and dcraw) to the source directory and somewhere else and added necessary libraries (-lm and -lws2_32). When adding into source file and to build path, everything gets build in no particular include order so I get errors like

..\src\libraw\internal\wf_filtering.cpp:827:22: error: 'libraw_internal_data' was not declared in this scope
and
..\src\libraw\internal\dcb_demosaicing.c:44:12: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'dcb_ver'
I think because it is not compiled in the order it is included and the things loose their context

But when I do this outside source file (so the things don't get build), including is fine but in the end I get a

undefined reference to `LibRaw::LibRaw(unsigned int)'

Error because the libraw_cxx.cpp file is not build.

Forums: