[R-SIG-Mac] rimage doesn't install on Mac OS X 10.4

Waichler, Scott R Scott.Waichler at pnl.gov
Wed Nov 12 22:44:27 CET 2008


Simon,

> Please make sure you're using Apple's gcc: run "which g++" 
> and make sure it's showing /usr/bin/g++ (in fact it's worth 
> running system("which g++") in R to make sure R doesn't add 
> anything). If that's not the case, please fix your PATH to 
> /usr/bin before any other paths and/or move any rogue 
> compilers aside. If that is not the issue, let me know.

The g++ compiler path was ok in both instances.  I also prepended
/usr/bin to my PATH as indicated below.  Still no luck.  If I try to
install using install.packages(), the process dies at trying to find
jpeglib.h (it's in /usr/local/include, and placing this in the PATH
doesn't seem to help).  If I execute setenv C_INCLUDE_PATH
/usr/local/include and setenv MACOSX_DEPLOYMENT_TARGET 10.4, then I am
able to run the R CMD INSTALL command as far as is shown below.

Thanks for the advice about sudo; I think I'm already locked in to using
it.

Thanks for your help,
Scott

[ice:~] waichler% echo $PATH
.:/usr/bin:/usr/local/include:/sw/bin:/sw/sbin:/bin:/sbin:/usr/bin:/usr/
sbin:/usr/X11R6/bin:/usr/office52:/usr/bin:/usr/unsupported/gnu/bin:/usr
/software/bin:/usr/unsupported/teTeX/bin:/usr/unsupported/bin:/usr/local
:/usr/local/bin:/usr/lib/R/bin:/home/waichler:/home/waichler/scripts:/ho
me/waichler/rpm:/usr/X11R6/bin:/bin:/opt:/opt/SUNWspro/bin:/usr/absoft/b
in:/opt/intel/compiler81/bin:/opt/intel_cc_80/bin:/usr/software/intel/co
mpiler81/bin:/usr/software/intel/compiler70/ia32/bin:/usr/local/intel-8.
1/mpich-1.2.6/bin:/home/waichler/f2jsrc/bin:/usr/java/:/usr/java/bin:/pr
ojects/dhsvm/code/dhsvm:/usr/pgi/linux86/bin

My attempt using install.packages():

> install.packages("rimage", lib="/usr/lib/R/library", repos =
"http://cran.fhcrc.org/", type="source")
trying URL 'http://cran.fhcrc.org/src/contrib/rimage_0.5-7.tar.gz'
Content type 'application/x-gzip' length 331029 bytes (323 Kb)
opened URL
==================================================
downloaded 323 Kb

* Installing *source* package 'rimage' ...
checking for g++... g++
checking for C++ compiler default output... a.out
checking whether the C++ compiler works... yes
checking whether we are cross compiling... no
checking for suffix of executables...
checking for suffix of object files... o
checking whether we are using the GNU C++ compiler... yes
checking whether g++ accepts -g... yes
checking for gcc... gcc
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ANSI C... none needed
checking how to run the C preprocessor... gcc -E
checking for egrep... grep -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking fftw.h usability... yes
checking fftw.h presence... yes
checking for fftw.h... yes
checking jpeglib.h usability... no
checking jpeglib.h presence... no
checking for jpeglib.h... no
configure: error: Sorry, can't find jpeglib header
ERROR: configuration failed for package 'rimage'
** Removing '/usr/lib/R/library/rimage'
The downloaded packages are in
        /tmp_mnt/snow/files0/waichler/tmp/RtmpFvBbXT/downloaded_packages
Warning message:
In install.packages("rimage", lib = "/usr/lib/R/library", repos =
"http://cran.fhcrc.org/",  :
  installation of package 'rimage' had non-zero exit status


My attempt using R CMD INSTALL from the shell command line:

[ice:~] waichler% sudo R CMD INSTALL --configure-vars='LDFLAGS=-L/sw/lib
CPPFLAGS=-I/sw/include' /Users/ladmin/rimage_0.5-7.tar.gz
Password:
* Installing to library
'/Library/Frameworks/R.framework/Resources/library'
* Installing *source* package 'rimage' ...
checking for g++... g++
checking for C++ compiler default output... a.out
checking whether the C++ compiler works... yes
checking whether we are cross compiling... no
checking for suffix of executables...
checking for suffix of object files... o
checking whether we are using the GNU C++ compiler... yes
checking whether g++ accepts -g... yes
checking for gcc... gcc
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ANSI C... none needed
checking how to run the C preprocessor... gcc -E
checking for egrep... grep -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking fftw.h usability... yes
checking fftw.h presence... yes
checking for fftw.h... yes
checking jpeglib.h usability... yes
checking jpeglib.h presence... yes
checking for jpeglib.h... yes
checking for inline... inline
checking for stdlib.h... (cached) yes
checking for GNU libc compatible malloc... yes
configure: creating ./config.status
config.status: creating src/Makevars
** libs
** arch - ppc
g++ -arch ppc -I/Library/Frameworks/R.framework/Resources/include
-I/Library/Frameworks/R.framework/Resources/include/ppc -g -O2
-I/sw/include  -I/usr/local/include    -fPIC  -g -O2 -c equalize.cpp -o
equalize.o
gcc -arch ppc -std=gnu99
-I/Library/Frameworks/R.framework/Resources/include
-I/Library/Frameworks/R.framework/Resources/include/ppc -g -O2
-I/sw/include-I/usr/local/include    -fPIC  -g -O2 -c fftw_access_func.c
-o fftw_access_func.o
g++ -arch ppc -I/Library/Frameworks/R.framework/Resources/include
-I/Library/Frameworks/R.framework/Resources/include/ppc -g -O2
-I/sw/include  -I/usr/local/include    -fPIC  -g -O2 -c freqfilters.cpp
-o freqfilters.o
g++ -arch ppc -I/Library/Frameworks/R.framework/Resources/include
-I/Library/Frameworks/R.framework/Resources/include/ppc -g -O2
-I/sw/include  -I/usr/local/include    -fPIC  -g -O2 -c interface.cpp -o
interface.o
gcc -arch ppc -std=gnu99
-I/Library/Frameworks/R.framework/Resources/include
-I/Library/Frameworks/R.framework/Resources/include/ppc -g -O2
-I/sw/include-I/usr/local/include    -fPIC  -g -O2 -c jpegio.c -o
jpegio.o
jpegio.c: In function 'read_JPEG_file':
jpegio.c:108: warning: pointer targets in assignment differ in
signedness
gcc -arch ppc -std=gnu99
-I/Library/Frameworks/R.framework/Resources/include
-I/Library/Frameworks/R.framework/Resources/include/ppc -g -O2
-I/sw/include-I/usr/local/include    -fPIC  -g -O2 -c laplacian.c -o
laplacian.o
laplacian.c: In function 'laplacian':
laplacian.c:14: warning: implicit declaration of function 'clearFrame'
g++ -arch ppc -I/Library/Frameworks/R.framework/Resources/include
-I/Library/Frameworks/R.framework/Resources/include/ppc -g -O2
-I/sw/include  -I/usr/local/include    -fPIC  -g -O2 -c matrix.cpp -o
matrix.o
gcc -arch ppc -std=gnu99
-I/Library/Frameworks/R.framework/Resources/include
-I/Library/Frameworks/R.framework/Resources/include/ppc -g -O2
-I/sw/include-I/usr/local/include    -fPIC  -g -O2 -c smooth.c -o
smooth.o
gcc -arch ppc -std=gnu99
-I/Library/Frameworks/R.framework/Resources/include
-I/Library/Frameworks/R.framework/Resources/include/ppc -g -O2
-I/sw/include-I/usr/local/include    -fPIC  -g -O2 -c sobel.c -o sobel.o
g++ -arch ppc -dynamiclib -Wl,-headerpad_max_install_names
-mmacosx-version-min=10.4 -undefined dynamic_lookup -single_module
-multiply_defined suppress -L/usr/local/lib -o rimage.so equalize.o
fftw_access_func.o freqfilters.o interface.o jpegio.o laplacian.o
matrix.o smooth.o sobel.o -L/sw/lib -ljpeg -lfftw
-F/Library/Frameworks/R.framework/.. -framework R -Wl,-framework
-Wl,CoreFoundation
ld: /Library/Frameworks/R.framework/../R.framework/R load command 14
unknown cmd field
/usr/bin/libtool: internal link edit command failed
make: *** [rimage.so] Error 1
chmod:
/Library/Frameworks/R.framework/Versions/2.8/Resources/library/rimage/li
bs/ppc/*: No such file or directory
ERROR: compilation failed for package 'rimage'
** Removing
'/Library/Frameworks/R.framework/Versions/2.8/Resources/library/rimage'
[ice:~] waichler%   



More information about the R-SIG-Mac mailing list