Alvaro Herrera wrote:
> Hi,
> 
> I just noticed a VPATH problem in the ecpg_config.h file that was just
> set up to be installed:
> 
> $ pwd
> /pgsql/build/80_rel/src/interfaces/ecpg/include
> 
> $ make install
> for i in ecpgerrno.h ecpglib.h ecpgtype.h sqlca.h sql3types.h ecpg_informix.h 
> ecpg_config.h pgtypes_error.h pgtypes_numeric.h pgtypes_timestamp.h 
> pgtypes_date.h pgtypes_interval.h; do /bin/sh 
> /pgsql/source/80_rel/config/install-sh -c -m 644 
> /pgsql/source/80_rel/src/interfaces/ecpg/include/$i 
> '/pgsql/install/80_rel/include' || exit; done
> /pgsql/source/80_rel/config/install-sh: 
> /pgsql/source/80_rel/src/interfaces/ecpg/include/ecpg_config.h does not exist.
> make: *** [install-headers] Error 1
> 
> This is natural, since ecpg_config.h lives in builddir, not in srcdir,
> unlike the rest of the headers.

I think this patch fixes it.

-- 
Alvaro Herrera                                http://www.CommandPrompt.com/
PostgreSQL Replication, Consulting, Custom Development, 24x7 support
Index: Makefile
===================================================================
RCS file: /home/alvherre/Code/cvs/pgsql/src/interfaces/ecpg/include/Makefile,v
retrieving revision 1.29
diff -c -p -r1.29 Makefile
*** Makefile    28 Nov 2006 12:44:06 -0000      1.29
--- Makefile    29 Nov 2006 12:31:44 -0000
*************** override CPPFLAGS := -DFRONTEND \
*** 7,25 ****
        -I$(libpq_srcdir) -I$(top_builddir)/src/port $(CPPFLAGS)
  
  informix_esql_dir = $(pkgincludedir)/informix/esql
  
! all: $(top_builddir)/src/interfaces/ecpg/include/ecpg_config.h 
  
  install: all installdirs install-headers
  
  .PHONY: install-headers
! ecpg_headers = ecpgerrno.h ecpglib.h ecpgtype.h sqlca.h sql3types.h 
ecpg_informix.h ecpg_config.h \
        pgtypes_error.h pgtypes_numeric.h pgtypes_timestamp.h pgtypes_date.h 
pgtypes_interval.h
  informix_headers = datetime.h decimal.h sqltypes.h sqlda.h
  
  install-headers: $(ecpg_headers) $(informix_headers)
        for i in $(ecpg_headers); do $(INSTALL_DATA) $(srcdir)/$$i 
'$(DESTDIR)$(includedir)' || exit; done
        for i in $(informix_headers); do $(INSTALL_DATA) $(srcdir)/$$i 
'$(DESTDIR)$(informix_esql_dir)' || exit; done
  
  installdirs:
        $(mkinstalldirs) '$(DESTDIR)$(includedir)' 
'$(DESTDIR)$(informix_esql_dir)'
--- 7,27 ----
        -I$(libpq_srcdir) -I$(top_builddir)/src/port $(CPPFLAGS)
  
  informix_esql_dir = $(pkgincludedir)/informix/esql
+ ecpg_config_h = $(top_builddir)/src/interfaces/ecpg/include/ecpg_config.h
  
! all: $(ecpg_config_h)
  
  install: all installdirs install-headers
  
  .PHONY: install-headers
! ecpg_headers = ecpgerrno.h ecpglib.h ecpgtype.h sqlca.h sql3types.h 
ecpg_informix.h \
        pgtypes_error.h pgtypes_numeric.h pgtypes_timestamp.h pgtypes_date.h 
pgtypes_interval.h
  informix_headers = datetime.h decimal.h sqltypes.h sqlda.h
  
  install-headers: $(ecpg_headers) $(informix_headers)
        for i in $(ecpg_headers); do $(INSTALL_DATA) $(srcdir)/$$i 
'$(DESTDIR)$(includedir)' || exit; done
        for i in $(informix_headers); do $(INSTALL_DATA) $(srcdir)/$$i 
'$(DESTDIR)$(informix_esql_dir)' || exit; done
+       $(INSTALL_DATA) $(ecpg_config_h) '$(DESTDIR)$(includedir)'
  
  installdirs:
        $(mkinstalldirs) '$(DESTDIR)$(includedir)' 
'$(DESTDIR)$(informix_esql_dir)'
---------------------------(end of broadcast)---------------------------
TIP 3: Have you checked our extensive FAQ?

               http://www.postgresql.org/docs/faq

Reply via email to