<div class="gmail_extra">Bom dia,<br><br><div class="gmail_quote"><div>Estou a tentar instalar o Postgis 2.0 numa máquina com ubuntu 11.10.</div><div><br></div><div>É a primeira vez que tento compilar da fonte.</div><div><br>
</div><div>Consegui fazer o &quot;configure&quot; e o &quot;make&quot; com sucesso, mas ao fazer a verificação (make check) deu o seguinte erro que indico abaixo.</div><div><br></div><div><div>Pelo que consegui procurar encontrei algumas referências a este erro, por exemplo:</div>
<div><a href="http://postgis.refractions.net/pipermail/postgis-devel/2012-March/019607.html" target="_blank">http://postgis.refractions.net/pipermail/postgis-devel/2012-March/019607.html</a></div><div><br></div><div>Terá alguma coisa a ver com mais do que uma versão do GEOS instalada no sistema.</div>
<div><br></div><div>Uma das soluções apresentadas prende-se com alterar a ordem dos <span style="font-family:courier;font-size:10pt">&quot;-L/usr/lib -lgdal1.8.0&quot; e &quot;-L/usr/local/lib</span><span style="font-family:courier;font-size:10pt"> -lgeos_c&quot;</span><span style="font-size:10pt"><font face="&#39;arial narrow&#39;, sans-serif"> </font><font face="arial, helvetica, sans-serif">no makefile.</font></span></div>
<div><span style="font-size:10pt"><font face="arial, helvetica, sans-serif"><br></font></span></div><div><font face="arial, helvetica, sans-serif">Mas em qual? Já alterei uns quantos</font><span style="font-family:arial,helvetica,sans-serif"> (raster\rt_core,raster\test\</span><span style="font-family:arial,helvetica,sans-serif">core), corri o &quot;make clean&quot; e o &quot;make&quot;. Mas volta a dar o mesmo erro, e a ordem não foi alterada.</span></div>
<span class="HOEnZb"><font color="#888888" face="arial, helvetica, sans-serif"><div><br></div><div>Alexandre Neto</div></font></span></div><div><br></div><div><br></div>
<div><br></div><div>-------------------------------</div><div><div>make[1]: Leaving directory `/media/DADOS1/TEMPORARIO/postgis-2.0.0/regress&#39;</div><div>---- Making check in raster</div><div>make[1]: Entering directory `/media/DADOS1/TEMPORARIO/postgis-2.0.0/raster&#39;</div>

<div>make -C test check</div><div>make[2]: Entering directory `/media/DADOS1/TEMPORARIO/postgis-2.0.0/raster/test&#39;</div><div>make -C core check</div><div>make[3]: Entering directory `/media/DADOS1/TEMPORARIO/postgis-2.0.0/raster/test/core&#39;</div>

<div>gcc -g -O2  -fPIC -DPIC  -Wall -Wmissing-prototypes -I../../rt_core -I../../../liblwgeom  -I/usr/include/gdal -I/usr/local/include -c testapi.c</div><div>mode=link gcc -g -O2  -fPIC -DPIC  -Wall -Wmissing-prototypes -I../../rt_core -I../../../liblwgeom  -I/usr/include/gdal -I/usr/local/include testapi.o ../../rt_core/librtcore.a ../../rt_core/librtcore.a ../../../liblwgeom/.libs/liblwgeom.a -L/usr/lib -lgdal1.8.0 -L/usr/local/lib -lgeos_c -lm  -o testapi</div>

<div>../../../liblwgeom/.libs/liblwgeom.a(lwgeom_geos.o): In function `LWGEOM2GEOS&#39;:</div><div>/media/DADOS1/TEMPORARIO/postgis-2.0.0/liblwgeom/lwgeom_geos.c:326: undefined reference to `GEOSGeom_createEmptyPolygon&#39;</div>

</div><div><div>../../../liblwgeom/.libs/liblwgeom.a(lwgeom_geos.o): In function `lwgeom_snap&#39;:</div><div>/media/DADOS1/TEMPORARIO/postgis-2.0.0/liblwgeom/lwgeom_geos.c:972: undefined reference to `GEOSSnap&#39;</div>

</div><div>.</div><div>.</div><div>.</div><div>/media/DADOS1/TEMPORARIO/postgis-2.0.0/liblwgeom/lwgeom_geos_clean.c:864: undefined reference to `GEOSGeom_extractUniquePoints&#39;</div><div>collect2: ld returned 1 exit status</div>

<div>make[3]: [testwkb] Error 1 (ignored)</div><div>./testapi</div><div>make[3]: ./testapi: Command not found</div><div>make[3]: *** [check] Error 127</div><div>make[3]: Leaving directory `/media/DADOS1/TEMPORARIO/postgis-2.0.0/raster/test/core&#39;</div>

<div>make[2]: *** [core-check] Error 2</div><div>make[2]: Leaving directory `/media/DADOS1/TEMPORARIO/postgis-2.0.0/raster/test&#39;</div><div>make[1]: *** [check] Error 2</div><div>make[1]: Leaving directory `/media/DADOS1/TEMPORARIO/postgis-2.0.0/raster&#39;</div>

<div>make: *** [check] Error 1</div><div><br></div><div>---------------------------</div><div><br></div><div>Pelo que consegui procurar</div><div><a href="http://postgis.refractions.net/pipermail/postgis-devel/2012-March/019607.html" target="_blank">http://postgis.refractions.net/pipermail/postgis-devel/2012-March/019607.html</a></div>

<div><br></div><div>Something to do with more than one GEOS installed</div><div><br></div><div>The presented solution would be to change the order of <span style="font-family:courier;font-size:10pt"> &quot;-L/usr/lib -lgdal1.8.0&quot; and &quot;-L/usr/local/lib</span></div>

<div><span style="font-family:courier;font-size:10pt"> -lgeos_c&quot;</span><span style="font-size:10pt"><font face="&#39;arial narrow&#39;, sans-serif"> in the makefile.</font></span></div><div><span style="font-size:10pt"><font face="&#39;arial narrow&#39;, sans-serif"><br>

</font></span></div><div><font face="&#39;arial narrow&#39;, sans-serif">But in witch makefile?</font></div><div><font face="&#39;arial narrow&#39;, sans-serif"><br></font></div><div><font face="&#39;arial narrow&#39;, sans-serif">Have have changed a bunch of them (raster\rt_core,raster\test\core), and used the make command again. But, in the &quot;make check&quot; the order is mantained and gives the same error.</font></div>
<span class="HOEnZb"><font color="#888888">
<div><font face="&#39;arial narrow&#39;, sans-serif"><br></font></div><div><font face="&#39;arial narrow&#39;, sans-serif">Alexandre Neto</font></div>
</font></span></div><br></div>