Hi Devrim,
Mark will be able to explain the change to the Makefile in more detail,
but in short, as of 1.4 PostGIS no longer uses the --prefix option
during configure so there is no DESTDIR. Rather, it installs in the
same directory as the detected (or specified) PostgreSQL directory. The
CPPFLAGS are not hard coded as you perceive. There is a Makefile.in
file that configure uses to generate the actual Makefile.
http://trac.osgeo.org/postgis/browser/branches/1.4/loader/Makefile.in#L22The /usr/local/pgsql/8.3/ path you have is the location of your detected
(or specified) postgresql installation. I don't know why the the shape
loader program is trying to install to /usr/bin/, that looks like a bug
... you should see it go to /usr/local/pgsql/8.3/bin.
Clear as mud?
Cheers,
Kevin
Devrim GÜNDÜZ wrote:
> Hi,
>
> loader/Makefile is broken AFAICS. It does not honor DESTDIR , as it used
> to do in 1.3.6. Here is a diff between 1.3.6 Makefile and 1.4.0rc1 one:
>
> install: all
> - @mkdir -p $(DESTDIR)$(bindir)
> - $(INSTALL_BIN) pgsql2shp$(EXE) $(DESTDIR)$(bindir)/pgsql2shp$(EXE)
> - $(INSTALL_BIN) shp2pgsql$(EXE) $(DESTDIR)$(bindir)/shp2pgsql$(EXE)
> + @cp $(PGSQL2SHP) $(PGSQL_BINDIR)/$(PGSQL2SHP)
> + @cp $(SHP2PGSQL) $(PGSQL_BINDIR)/$(SHP2PGSQL)
>
>
> which results in:
>
> make[2]: Leaving directory `/home/devrim/rpm/BUILD/postgis-1.4.0rc1/postgis'
> make -C loader install
> make[2]: Entering directory `/home/devrim/rpm/BUILD/postgis-1.4.0rc1/loader'
> cp: cannot create regular file `/usr/bin/pgsql2shp': Permission denied
> make[2]: *** [install] Error 1
> make[2]: Leaving directory `/home/devrim/rpm/BUILD/postgis-1.4.0rc1/loader'
> make[1]: *** [loaderdumper-install] Error 2
> make[1]: Leaving directory `/home/devrim/rpm/BUILD/postgis-1.4.0rc1'
> error: Bad exit status from /var/tmp/rpm-tmp.MmIpx5 (%install)
>
> See cp part -- it does not honor DESTDIR parameter.
>
> Also, why are these hardcoded in the same Makefile?
>
> # PostgreSQL frontend CPPFLAGS and LDFLAGS (for compiling and linking with libpq)
> PGSQL_FE_CPPFLAGS=-I/usr/local/pgsql/8.3/include
> PGSQL_FE_LDFLAGS=-L/usr/local/pgsql/8.3/lib -lpq
>
> # PostgreSQL executable directory
> PGSQL_BINDIR=/usr/local/pgsql/8.3/bin
>
> Regards,
>
>
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> postgis-devel mailing list
>
postgis-devel@...
>
http://postgis.refractions.net/mailman/listinfo/postgis-devel>
_______________________________________________
postgis-devel mailing list
postgis-devel@...
http://postgis.refractions.net/mailman/listinfo/postgis-devel