Darn, I got nothing. It seems like a MakeMaker issue at this point. Anybody else? David
On Tue, Mar 20, 2012 at 3:59 PM, Michael Roberts <mich...@vivtek.com> wrote: > On 3/20/2012 4:39 PM, David Mertens wrote: > > Fixed in under an hour. Go open source! :-D > ALMOST fixed. The INC works, but LIBS doesn't. Here's the current code > - note that I'm actually specifying the LIBS explicitly, just to > eliminate all possibility of confusion. > > > BEGIN { > > $INCLUDES = '-Ic:\\Program Files\\ImageMagick-6.7.5-Q16\\include'; > > $LIBRARIES = '"-LC:\\Program Files\\ImageMagick-6.7.5-Q16\\lib" > -lwand'; > > } > > > > # Configure Inline::C and define all the C functions we'll be calling > in the Perl part of the module. > > use Inline C => Config => LIBS => '"-LC:\\Program > Files\\ImageMagick-6.7.5-Q16\\lib" -lwand' => INC => $INCLUDES; > #$LIBRARIES; > > use Inline C => <<'END_OF_C_CODE'; > > > > #include <wand/magick_wand.h> > > > > void Genesis (void) { MagickWandGenesis(); } > > [snip] > > END_OF_C_CODE > > But no dice: > > > # dlltool --def Wand_829d.def --output-exp dll.exp > > # g++ -o blib\arch\auto\Image\Magick\Wand_829d\Wand_829d.dll > -Wl,--base-file -Wl > > ,dll.base -mdll -s -L"C:\strawberry\perl\lib\CORE" > -L"C:\strawberry\c\lib" Wand_ > > 829d.o -Wl,--image-base,0x8590000 > C:\strawberry\perl\lib\CORE\libperl510.a C:\s > > trawberry\c\lib\libmoldname.a C:\strawberry\c\lib\libkernel32.a > C:\strawberry\c\ > > lib\libuser32.a C:\strawberry\c\lib\libgdi32.a > C:\strawberry\c\lib\libwinspool.a > > C:\strawberry\c\lib\libcomdlg32.a C:\strawberry\c\lib\libadvapi32.a > C:\strawber > > ry\c\lib\libshell32.a C:\strawberry\c\lib\libole32.a > C:\strawberry\c\lib\libolea > > ut32.a C:\strawberry\c\lib\libnetapi32.a C:\strawberry\c\lib\libuuid.a > C:\strawb > > erry\c\lib\libws2_32.a C:\strawberry\c\lib\libmpr.a > C:\strawberry\c\lib\libwinmm > > .a C:\strawberry\c\lib\libversion.a C:\strawberry\c\lib\libodbc32.a > C:\strawberr > > y\c\lib\libodbccp32.a dll.exp > > # Wand_829d.o:Wand_829d.c:(.text+0x28): undefined reference to > `NewMagickWand' > > # Wand_829d.o:Wand_829d.c:(.text+0x5): undefined reference to > `MagickWandGenesis > > ' > ... etc. > > Looking at Inline's Makefile.PL and Makefile, the LIBS parameter is > built and passed OK, and even appears in the Makefile comments - but > doesn't actually appear in the Makefile elsewhere. I've got to be > missing something obvious... > > -- "Debugging is twice as hard as writing the code in the first place. Therefore, if you write the code as cleverly as possible, you are, by definition, not smart enough to debug it." -- Brian Kernighan