Welcome to TalkGraphics.com
Results 1 to 7 of 7
  1. #1
    Join Date
    May 2006
    Posts
    4

    Default Mac OS X build - jpeglib failure

    When I try to build the Xara source on my MacBook Pro, I get errors about jpeglib.h

    In file included from .././Kernel/exjpeg.h:104,
    from maskfilt.cpp:118:
    .././Kernel/jpglib_namespace.h:116:22: error: jpeglib.h: No such file or directory
    .././Kernel/exjpeg.h:144: error: 'J_DCT_METHOD' in namespace 'libJPEG' does not name a type
    .././Kernel/exjpeg.h:145: error: expected unqualified-id before '&' token
    .././Kernel/exjpeg.h:145: error: expected ',' or '...' before '&' token
    .././Kernel/exjpeg.h:145: error: ISO C++ forbids declaration of 'parameter' with no type
    .././Kernel/exjpeg.h:147: error: 'J_COLOR_SPACE' in namespace 'libJPEG' does not name a type
    .././Kernel/exjpeg.h:149: error: expected unqualified-id before '&' token
    .././Kernel/exjpeg.h:149: error: expected ',' or '...' before '&' token
    .././Kernel/exjpeg.h:149: error: ISO C++ forbids declaration of 'parameter' with no type
    .././Kernel/exjpeg.h:173: error: 'J_DCT_METHOD' in namespace 'libJPEG' does not name a type
    .././Kernel/exjpeg.h:174: error: 'J_COLOR_SPACE' in namespace 'libJPEG' does not name a type
    .././Kernel/exjpeg.h:275: error: 'jpeg_compress_struct' in namespace 'libJPEG' does not name a type
    make[2]: *** [maskfilt.o] Error 1
    make[1]: *** [all] Error 2
    make: *** [all-recursive] Error 1


    However, fink list libjpeg reports that the library is installed:

    i libjpeg 6b-16 JPEG image format handling library
    i libjpeg-bin 6b-16 Executables for libjpeg package
    i libjpeg-shlibs 6b-16 Shared libraries for libjpeg package

    Does anyone know what's going on here?
    Any help on this would be greatly appreciated.
    IP

  2. #2
    Join Date
    May 2006
    Posts
    4

    Default Mac OS X - cannot convert String_256 to char*

    Ok, I think I have the jpeglib part figured out from here (http://www.xaraxtreme.org/maillists/.../msg00006.html).

    However, now I get the following:
    impexpop.cpp: In member function 'virtual void OpMenuExport:oWithParam(OpDescriptor*, OpParam*)':
    impexpop.cpp:1228: error: cannot convert 'String_256' to 'char*' in initialization
    impexpop.cpp:1229: error: cannot convert 'String_256' to 'char*' in initialization
    make[1]: *** [impexpop.o] Error 1
    make: *** [all-recursive] Error 1
    IP

  3. #3
    Join Date
    May 2004
    Location
    Xara Group Ltd
    Posts
    415

    Default Re: Mac OS X build - jpeglib failure

    A patch has been checked in that should get rid of this error...

    Gerry Iles
    IP

  4. #4
    Join Date
    May 2006
    Posts
    4

    Default Re: Mac OS X build - jpeglib failure

    Alright, I used svn this time to get the source and that fixed the string_256 compile errors. Now, it appears I have a linker problem with libpng:

    g++ Kernel/*.o wxOil/*.o tools/*.o wxXtra/*.o --debug -L./libs/darwin -L/Users/Chris/XaraLX/wxMac-2.6.3/build-unicode-debug/lib -framework QuickTime -framework IOKit -framework Carbon -framework Cocoa -framework System -lwx_macud-2.6 -L/usr/lib -lxml2 -lz -lpthread -liconv -lm -lCDraw -o XaraLX
    /usr/bin/ld: Undefined symbols:
    _png_error
    _png_get_io_ptr
    _png_create_info_struct
    _png_create_write_struct_2
    _png_destroy_write_struct
    _png_set_bgr
    _png_set_interlace_handling
    _png_set_swap
    _png_set_write_fn
    _png_write_end
    _png_write_info
    _png_write_row
    _png_create_read_struct_2
    _png_destroy_read_struct
    _png_free
    _png_get_IHDR
    _png_get_PLTE
    _png_get_bit_depth
    _png_get_channels
    _png_get_color_type
    _png_get_gAMA
    _png_get_interlace_type
    _png_get_pHYs
    _png_get_rowbytes
    _png_get_sRGB
    _png_get_tRNS
    _png_get_valid
    _png_malloc
    _png_read_end
    _png_read_image
    _png_read_info
    _png_read_update_info
    _png_set_expand
    _png_set_gamma
    _png_set_gray_to_rgb
    _png_set_invert_alpha
    _png_set_read_fn
    _png_set_read_status_fn
    _png_set_sig_bytes
    _png_set_strip_16
    collect2: ld returned 1 exit status
    make[1]: *** [XaraLX] Error 1
    make: *** [all-recursive] Error 1

    I downloaded and compiled libpng 1.2.10, but maybe the linker isn't seeing it?
    IP

  5. #5
    Join Date
    Jun 2004
    Location
    North Tawton, UK
    Posts
    1,152

    Default Re: Mac OS X build - jpeglib failure

    You need to add -lpng to your link command: In the makefile.am file in the root of the project, find the line that starts XaraLX_LDFLAGS = and add " -lpng" to the end (without the quotes).

    We hope to make an Xcode project available which will simplify all these build problems on the Mac (and allow Universal Binaries to be created).

    Phil
    IP

  6. #6
    Join Date
    May 2006
    Posts
    4

    Default Re: Mac OS X build - jpeglib failure

    Thanks, it finally compiled completely :-) Unfortunately, it doesn't do anything at all. I can't click anything except the x/-/+ widgets. The first thing that comes up is a dialog indicating that the fonts data was messed up, but I can't even click the OK button.
    IP

  7. #7
    Join Date
    Jun 2004
    Location
    North Tawton, UK
    Posts
    1,152

    Default Re: Mac OS X build - jpeglib failure

    That sounds like the usual problem that Finder doesn't recognise the executable correctly. There's an empty bundle in the project which you can use:

    In the root of the project you should see a folder called XaraLX.app. Copy (or move) your executable into XaraLX.app/Contents/MacOS and then run XaraLX.app.

    cp XaraLX XaraLX.app/Contents/MacOS
    open XaraLX.app
    IP

 

 

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •