Opened 16 years ago

Closed 16 years ago

Last modified 16 years ago

#17553 closed defect (fixed)

camlimages fails to build universal

Reported by: jeremyhu (Jeremy Huddleston Sequoia) Owned by: reilles@…
Priority: Normal Milestone:
Component: ports Version: 1.6.0
Keywords: universal Cc: reilles@…
Port: camlimages

Description

ocamlmklib -oc ci_jpeg -L/opt/local/lib -arch ppc -arch i386 -mmacosx-version-min=10.5 jpegread.o jpegwrite.o -ljpeg
ocamlc.opt  -I ../corelib -c jpeg.mli
Unknown option -arch
Don't know what to do with ppc
Usage: ocamlmklib [options] <.cmo|.cma|.cmx|.cmxa|.ml|.mli|.o|.a|.obj|.lib files>
Options are:
  -cclib <lib>   C library passed to ocamlc -a or ocamlopt -a only
  -ccopt <opt>   C option passed to ocamlc -a or ocamlopt -a only
  -custom        disable dynamic loading
  -dllpath <dir> Add <dir> to the run-time search path for DLLs
  -I <dir>       Add <dir> to the path searched for Caml object files
  -failsafe      fall back to static linking if DLL construction failed
  -ldopt <opt>   C option passed to the shared linker only
  -linkall       Build Caml archive with link-all behavior
  -l<lib>        Specify a dependent C library
  -L<dir>        Add <dir> to the path searched for C libraries
  -ocamlc <cmd>  Use <cmd> in place of "ocamlc"
  -ocamlopt <cmd> Use <cmd> in place of "ocamlopt"
  -o <name>      Generated Caml library is named <name>.cma or <name>.cmxa
  -oc <name>     Generated C library is named dll<name>.so or lib<name>.a
  -rpath <dir>   Same as -dllpath <dir>
  -R<dir>        Same as -rpath
  -verbose       Print commands before executing them
  -Wl,-rpath,<dir>     Same as -dllpath <dir>
  -Wl,-rpath -Wl,<dir> Same as -dllpath <dir>
  -Wl,-R<dir>          Same as -dllpath <dir>
  -F<dir>        Specify a framework directory (MacOSX)
  -framework <name>    Use framework <name> (MacOSX)
  -version       Print version and exit
make[1]: *** [libci_jpeg.a] Error 4
make[1]: *** Waiting for unfinished jobs....
make: *** [opt] Error 2

When not universal, we fail with:

		   jpeg.cmo oJpeg.cmo -L/opt/local/lib -ljpeg; \
	  fi
ocamlc.opt  -ccopt "-I.. -O2 -I/opt/local/include" -c tiffread.c 
tiffread.c:24:1: warning: "int16" redefined
In file included from /opt/local/lib/ocaml/caml/mlvalues.h:20,
                 from tiffread.c:16:
/opt/local/lib/ocaml/caml/compatibility.h:312:1: warning: this is the location of the previous definition
tiffread.c:25:1: warning: "uint16" redefined
/opt/local/lib/ocaml/caml/compatibility.h:313:1: warning: this is the location of the previous definition
tiffread.c: In function 'open_tiff_file_for_read':
tiffread.c:55: error: 'uint32_t' undeclared (first use in this function)
tiffread.c:55: error: (Each undeclared identifier is reported only once
tiffread.c:55: error: for each function it appears in.)
tiffread.c:55: error: syntax error before 'imagelength'
tiffread.c:57: error: 'uint16_t' undeclared (first use in this function)
tiffread.c:61: error: syntax error before 'runit'
tiffread.c:63: error: syntax error before 'photometric'
tiffread.c:65: error: 'imagelength' undeclared (first use in this function)
tiffread.c:66: error: 'imagewidth' undeclared (first use in this function)
tiffread.c:67: error: 'imagebits' undeclared (first use in this function)
tiffread.c:68: error: 'imagesample' undeclared (first use in this function)
tiffread.c:69: error: 'runit' undeclared (first use in this function)
tiffread.c:72: error: 'photometric' undeclared (first use in this function)
make[1]: *** [tiffread.o] Error 2
make: *** [byt] Error 2

Attachments (1)

patch-aa (309 bytes) - added by reilles@… 16 years ago.

Download all attachments as: .zip

Change History (4)

Changed 16 years ago by reilles@…

Attachment: patch-aa added

comment:1 Changed 16 years ago by reilles@…

The attached patch should fix the issue in the non-universal case.

comment:2 Changed 16 years ago by jeremyhu (Jeremy Huddleston Sequoia)

Resolution: fixed
Status: newclosed

comment:3 Changed 16 years ago by (none)

Milestone: Port Bugs

Milestone Port Bugs deleted

Note: See TracTickets for help on using tickets.