You are not logged in.

#1 2010-10-02 01:58:54

schroeder
Member
From: Northern Colorado
Registered: 2010-05-20
Posts: 2

Problems cross-compiling imagemagick with mingw32

I am trying to cross-compile imagemagick dlls for Windows with mingw32.

I installed the mingw32 package and ran

./configure --host=i486-mingw32 --with-perl=no --enable-static=no

The output shows something like this:

JPEG v1           --with-jpeg=yes        no (failed tests)
JPEG-2000         --with-jp2=yes        no (failed tests)
LCMS v1           --with-lcms=yes        no (failed tests)
LCMS v2           --with-lcms2=yes        no
LQR               --with-lqr=yes        no
Magick++          --with-magick-plus-plus=yes    yes
OpenEXR           --with-openexr=yes        no
PERL              --with-perl=no        no
PNG               --with-png=yes        no (failed tests)
RSVG              --with-rsvg=yes        yes
TIFF              --with-tiff=yes        no (failed tests)

In config.log the test failures are shown as follows:

configure:27841: checking for jpeg_read_header in -ljpeg
configure:27866: i486-mingw32-gcc -std=gnu99 -std=gnu99 -o conftest.exe   -g -O2 -Wall -I/usr/include/freetype2    -D_DLL -D_MT  -I/usr/include   -L/usr/lib conftest.c -ljpeg     -lX11   -lm   >&5
/usr/lib/gcc/i486-mingw32/4.5.0/../../../../i486-mingw32/bin/ld: cannot find -lX11
collect2: ld returned 1 exit status

The compiler/linker configuration looks correct to me:

X11 Configuration:
      X_CFLAGS        = -I/usr/include
      X_PRE_LIBS      =
      X_LIBS          = -L/usr/lib
      X_EXTRA_LIBS    =

Options used to compile and link:
  PREFIX          = /usr/local
  EXEC-PREFIX     = /usr/local
  VERSION         = 6.6.4
  CC              = i486-mingw32-gcc -std=gnu99 -std=gnu99
  CFLAGS          = -g -O2 -Wall
  CPPFLAGS        = -I/usr/local/include/ImageMagick -D_DLL -D_MT
  PCFLAGS         = -D_DLL -D_MT
  DEFS            = -DHAVE_CONFIG_H
  LDFLAGS         = -L/usr/lib
  MAGICK_LDFLAGS  = -L/usr/local/lib -L/usr/lib
  LIBS            = -lMagickCore -lfontconfig -lX11 -pthread -lrsvg-2 -lm -lgdk_pixbuf-2.0 -lcairo -lgobject-2.0 -lgmodule-2.0 -lgthread-2.0 -lrt -lglib-2.0 -lgdi32 -lm
  CXX             = i486-mingw32-g++
  CXXFLAGS        = -g -O2
  FEATURES        =


Why can't it find the X11 library?

Offline

Board footer

Powered by FluxBB