DevelopmentPanda / spatialite-android

Automatically exported from code.google.com/p/spatialite-android
0 stars 0 forks source link

'error: geos_c.h: No such file or directory' when running ndk-build #4

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Downloaded, unzipped source & configured as per the instructions on the 
project home page (everything went ok)
2. Ran ndk-build from jni folder

What is the expected output? What do you see instead?

Expected ndk-build to compile and complete.
Instead, the following was output:

user@hostname:~/path/to/project/jni$ /tools/android-ndk-r7/ndk-build 
Gdbserver      : [arm-linux-androideabi-4.4.3] libs/armeabi/gdbserver
Gdbsetup       : libs/armeabi/gdb.setup
Compile thumb  : spatialite <= spatialite.c
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:102:20: 
error: geos_c.h: No such file or directory
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c: In 
function 'gaiaGeomCollEquals':
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24519: 
error: 'GEOSGeometry' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24519: 
error: (Each undeclared identifier is reported only once
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24519: 
error: for each function it appears in.)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24519: 
error: 'g1' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24520: 
error: 'g2' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c: In 
function 'gaiaGeomCollIntersects':
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24536: 
error: 'GEOSGeometry' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24536: 
error: 'g1' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24537: 
error: 'g2' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c: In 
function 'gaiaGeomCollDisjoint':
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24553: 
error: 'GEOSGeometry' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24553: 
error: 'g1' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24554: 
error: 'g2' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c: In 
function 'gaiaGeomCollOverlaps':
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24570: 
error: 'GEOSGeometry' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24570: 
error: 'g1' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24571: 
error: 'g2' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c: In 
function 'gaiaGeomCollCrosses':
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24587: 
error: 'GEOSGeometry' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24587: 
error: 'g1' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24588: 
error: 'g2' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c: In 
function 'gaiaGeomCollTouches':
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24604: 
error: 'GEOSGeometry' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24604: 
error: 'g1' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24605: 
error: 'g2' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c: In 
function 'gaiaGeomCollWithin':
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24621: 
error: 'GEOSGeometry' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24621: 
error: 'g1' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24622: 
error: 'g2' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c: In 
function 'gaiaGeomCollContains':
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24638: 
error: 'GEOSGeometry' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24638: 
error: 'g1' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24639: 
error: 'g2' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c: In 
function 'gaiaGeomCollRelate':
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24656: 
error: 'GEOSGeometry' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24656: 
error: 'g1' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24657: 
error: 'g2' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c: In 
function 'gaiaGeomCollLength':
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24674: 
error: 'GEOSGeometry' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24674: 
error: 'g' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c: In 
function 'gaiaGeomCollArea':
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24691: 
error: 'GEOSGeometry' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24691: 
error: 'g' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c: In 
function 'gaiaGeomCollDistance':
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24709: 
error: 'GEOSGeometry' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24709: 
error: 'g1' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24710: 
error: 'g2' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c: In 
function 'gaiaGeometryIntersection':
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24728: 
error: 'GEOSGeometry' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24728: 
error: 'g1' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24729: 
error: 'g2' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24730: 
error: 'g3' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c: In 
function 'gaiaGeometryUnion':
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24760: 
error: 'GEOSGeometry' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24760: 
error: 'g1' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24761: 
error: 'g2' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24762: 
error: 'g3' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c: In 
function 'gaiaGeometryDifference':
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24799: 
error: 'GEOSGeometry' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24799: 
error: 'g1' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24800: 
error: 'g2' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24801: 
error: 'g3' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c: In 
function 'gaiaGeometrySymDifference':
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24831: 
error: 'GEOSGeometry' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24831: 
error: 'g1' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24832: 
error: 'g2' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24833: 
error: 'g3' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c: In 
function 'gaiaBoundary':
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24863: 
error: 'GEOSGeometry' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24863: 
error: 'g1' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24864: 
error: 'g2' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c: In 
function 'gaiaGeomCollCentroid':
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24892: 
error: 'GEOSGeometry' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24892: 
error: 'g1' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24893: 
error: 'g2' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c: In 
function 'gaiaGetPointOnSurface':
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24928: 
error: 'GEOSGeometry' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24928: 
error: 'g1' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24929: 
error: 'g2' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c: In 
function 'gaiaIsSimple':
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24964: 
error: 'GEOSGeometry' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24964: 
error: 'g' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c: In 
function 'gaiaIsRing':
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24989: 
error: 'GEOSGeometry' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:24989: 
error: 'g' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c: In 
function 'gaiaIsValid':
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:25052: 
error: 'GEOSGeometry' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:25052: 
error: 'g' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c: In 
function 'gaiaGeomCollSimplify':
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:25071: 
error: 'GEOSGeometry' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:25071: 
error: 'g1' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:25072: 
error: 'g2' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c: In 
function 'gaiaGeomCollSimplifyPreserveTopology':
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:25100: 
error: 'GEOSGeometry' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:25100: 
error: 'g1' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:25101: 
error: 'g2' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c: In 
function 'gaiaConvexHull':
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:25129: 
error: 'GEOSGeometry' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:25129: 
error: 'g1' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:25130: 
error: 'g2' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c: In 
function 'gaiaGeomCollBuffer':
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:25158: 
error: 'GEOSGeometry' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:25158: 
error: 'g1' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:25159: 
error: 'g2' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c: At top 
level:
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:28056: 
error: expected '=', ',', ';', 'asm' or '__attribute__' before '*' token
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:28476: 
error: expected ';', ',' or ')' before '*' token
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c: In 
function 'gaiaToGeos':
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:28912: 
warning: return makes pointer from integer without a cast
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c: In 
function 'gaiaFromGeos_XY':
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:28919: 
error: expected '=', ',', ';', 'asm' or '__attribute__' before '*' token
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:28919: 
error: 'geos' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c: In 
function 'gaiaFromGeos_XYZ':
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:28927: 
error: expected '=', ',', ';', 'asm' or '__attribute__' before '*' token
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:28927: 
error: 'geos' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c: In 
function 'gaiaFromGeos_XYM':
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:28935: 
error: expected '=', ',', ';', 'asm' or '__attribute__' before '*' token
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:28935: 
error: 'geos' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c: In 
function 'gaiaFromGeos_XYZM':
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:28943: 
error: expected '=', ',', ';', 'asm' or '__attribute__' before '*' token
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:28943: 
error: 'geos' undeclared (first use in this function)
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c: In 
function 'fnct_geos_version':
/path/to/project/jni/./libspatialite-amalgamation-3.0.1/spatialite.c:41748: 
warning: initialization makes pointer from integer without a cast
make: *** 
[/path/to/project/obj/local/armeabi/objs-debug/spatialite/./libspatialite-amalga
mation-3.0.1/spatialite.o] Error 1

What version of the product are you using? On what operating system?
android-ndk-r7 on Ubuntu 11.10 (64-bit)

Please provide any additional information below.
Any help greatly appreciated!

Original issue reported on code.google.com by smithers...@gmail.com on 9 Feb 2012 at 9:19

GoogleCodeExporter commented 9 years ago
There is an error in the Android.mk file.  Line 467 should be geos-3.2.2/capi.  
Source has been updated.  Let me know if there are any other issues.

Original comment by efroh...@gmail.com on 10 Feb 2012 at 1:41

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
i run ndk-buil in JNI folder, the output is:

D:\git\sample-android-spatialite\jni>ndk-build
/usr/bin/sh: -c: línea 1: error sintáctico: no se esperaba el final del 
fichero
make: *** [D:/git/sample-android-spatialite//obj/local/armeabi/objs/spatialite/.
/libspatialite-amalgamation-2.3.1/spatialite.o] Error 1

please helpme..

i´m in Winxp SP3 

Original comment by jwcace...@gmail.com on 21 Mar 2012 at 3:05