[R-SIG-Mac] Problems installing rgdal from source
sj
saimon at student.ethz.ch
Thu Jun 8 12:22:23 CEST 2006
Dear list
I tried to install rgdal from source and was running into troubles.
System: OS X 10.4.6, PPC
R version: 2.3.0
GDAL version: 1.3.1.0 (installed from fink)
PROJ.4 version: 4.4.8-4 (installed from fink)
proj_api.h exists in /sw/include
libproj.a exists in /sw/lib
therefor I used the following commands to install:
export CPPFLAGS="-I/sw/include"
export LDFLAGS="-L/sw/lib"
R CMD INSTALL rgdal_0.4-4.tar.gz
what produced:
-------------------------------------------------------------------------------------------------------------------------
* Installing *source* package 'rgdal' ...
checking for gcc... gcc
checking for C compiler default output file name... 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 gcc accepts -g... yes
checking for gcc option to accept ANSI C... none needed
checking for pj_init_plus in -lproj... yes
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 proj_api.h usability... yes
checking proj_api.h presence... yes
checking for proj_api.h... yes
configure: creating ./config.status
config.status: creating src/Makevars
** libs
** arch - ppc
g++-4.0 -arch ppc -I/Library/Frameworks/R.framework/Resources/include
-I/Library/Frameworks/R.framework/Resources/include/ppc
-I/sw/include/gdal1 -g -DRGDALDEBUG -I/usr/local/include -fPIC
-fno-common -g -O2 -c gdal-bindings.cpp -o gdal-bindings.o
g++-4.0 -arch ppc -I/Library/Frameworks/R.framework/Resources/include
-I/Library/Frameworks/R.framework/Resources/include/ppc
-I/sw/include/gdal1 -g -DRGDALDEBUG -I/usr/local/include -fPIC
-fno-common -g -O2 -c ogr_geom.cpp -o ogr_geom.o
g++-4.0 -arch ppc -I/Library/Frameworks/R.framework/Resources/include
-I/Library/Frameworks/R.framework/Resources/include/ppc
-I/sw/include/gdal1 -g -DRGDALDEBUG -I/usr/local/include -fPIC
-fno-common -g -O2 -c ogr_proj.cpp -o ogr_proj.o
g++-4.0 -arch ppc -I/Library/Frameworks/R.framework/Resources/include
-I/Library/Frameworks/R.framework/Resources/include/ppc
-I/sw/include/gdal1 -g -DRGDALDEBUG -I/usr/local/include -fPIC
-fno-common -g -O2 -c ogrsource.cpp -o ogrsource.o
gcc-4.0 -arch ppc -I/Library/Frameworks/R.framework/Resources/include
-I/Library/Frameworks/R.framework/Resources/include/ppc
-I/sw/include/gdal1 -g -DRGDALDEBUG -I/usr/local/include -fPIC
-fno-common -g -O2 -std=gnu99 -c projectit.c -o projectit.o
projectit.c:6:22: error: proj_api.h: No such file or directory
projectit.c: In function 'project':
projectit.c:16: error: 'projUV' undeclared (first use in this function)
projectit.c:16: error: (Each undeclared identifier is reported only once
projectit.c:16: error: for each function it appears in.)
projectit.c:16: error: syntax error before 'p'
projectit.c:17: error: 'projPJ' undeclared (first use in this function)
projectit.c:19: error: 'pj' undeclared (first use in this function)
projectit.c:19: warning: implicit declaration of function 'pj_init_plus'
projectit.c:20: warning: implicit declaration of function 'pj_strerrno'
projectit.c:20: warning: implicit declaration of function 'pj_get_errno_ref'
projectit.c:20: error: invalid type argument of 'unary *'
projectit.c:20: warning: passing argument 1 of 'Rf_error' makes pointer
from integer without a cast
projectit.c:29: error: 'p' undeclared (first use in this function)
projectit.c:31: error: 'DEG_TO_RAD' undeclared (first use in this function)
projectit.c:33: warning: implicit declaration of function 'pj_fwd'
projectit.c:35: warning: implicit declaration of function 'pj_free'
projectit.c:36: error: invalid type argument of 'unary *'
projectit.c:36: warning: passing argument 1 of 'Rf_error' makes pointer
from integer without a cast
projectit.c: In function 'project_inv':
projectit.c:54: error: 'projUV' undeclared (first use in this function)
projectit.c:54: error: syntax error before 'p'
projectit.c:55: error: 'projPJ' undeclared (first use in this function)
projectit.c:57: error: 'pj' undeclared (first use in this function)
projectit.c:58: error: invalid type argument of 'unary *'
projectit.c:58: warning: passing argument 1 of 'Rf_error' makes pointer
from integer without a cast
projectit.c:66: error: 'p' undeclared (first use in this function)
projectit.c:68: warning: implicit declaration of function 'pj_inv'
projectit.c:71: error: invalid type argument of 'unary *'
projectit.c:71: warning: passing argument 1 of 'Rf_error' makes pointer
from integer without a cast
projectit.c:73: error: 'RAD_TO_DEG' undeclared (first use in this function)
projectit.c: In function 'transform':
projectit.c:88: error: 'projUV' undeclared (first use in this function)
projectit.c:88: error: syntax error before 'p'
projectit.c:89: error: 'projPJ' undeclared (first use in this function)
projectit.c:92: error: 'fromPJ' undeclared (first use in this function)
projectit.c:93: error: invalid type argument of 'unary *'
projectit.c:93: warning: passing argument 1 of 'Rf_error' makes pointer
from integer without a cast
projectit.c:95: error: 'toPJ' undeclared (first use in this function)
projectit.c:96: error: invalid type argument of 'unary *'
projectit.c:96: warning: passing argument 1 of 'Rf_error' makes pointer
from integer without a cast
projectit.c:105: warning: implicit declaration of function 'pj_get_def'
projectit.c:105: warning: passing argument 1 of 'Rf_mkChar' makes
pointer from integer without a cast
projectit.c:108: warning: passing argument 1 of 'Rf_mkChar' makes
pointer from integer without a cast
projectit.c:115: error: 'p' undeclared (first use in this function)
projectit.c:120: warning: implicit declaration of function 'pj_is_latlong'
projectit.c:121: error: 'DEG_TO_RAD' undeclared (first use in this function)
projectit.c:125: warning: implicit declaration of function 'pj_transform'
projectit.c:134: error: invalid type argument of 'unary *'
projectit.c:134: warning: passing argument 1 of 'Rf_error' makes pointer
from integer without a cast
projectit.c:137: error: 'RAD_TO_DEG' undeclared (first use in this function)
projectit.c: In function 'checkCRSArgs':
projectit.c:153: error: 'projPJ' undeclared (first use in this function)
projectit.c:153: error: syntax error before 'pj'
projectit.c:159: error: 'pj' undeclared (first use in this function)
projectit.c:162: error: invalid type argument of 'unary *'
projectit.c:162: warning: passing argument 1 of 'Rf_mkChar' makes
pointer from integer without a cast
projectit.c:169: warning: passing argument 1 of 'Rf_mkChar' makes
pointer from integer without a cast
make: *** [projectit.o] Error 1
chmod: getting attributes of
`/Library/Frameworks/R.framework/Versions/2.3/Resources/library/rgdal/libs/ppc/*':
No such file or directory
ERROR: compilation failed for package 'rgdal'
** Removing
'/Library/Frameworks/R.framework/Versions/2.3/Resources/library/rgdal'
-------------------------------------------------------------------------------------------------------------------------
Apparently it still cannot find the proj_api.h, although the checks were
ok. Any hints what I do wrong?
Thanks and regards
Simon
PS: Is there a possibility or function to search the mail archive?
More information about the R-SIG-Mac
mailing list