Thread: switch for disabling ecpg & pgeasy

switch for disabling ecpg & pgeasy

From
Marko Kreen
Date:
* configure switches for disabling ECPG and libpgeasy
  compile, as they are not used always

--
marko


Index: configure.in
===================================================================
RCS file: /home/projects/pgsql/cvsroot/pgsql/configure.in,v
retrieving revision 1.129
diff -u -c -r1.129 configure.in
*** configure.in    2001/06/11 22:12:48    1.129
--- configure.in    2001/06/15 16:25:03
***************
*** 363,368 ****
--- 363,384 ----
  done
  IFS=$ac_save_IFS

+ #
+ # Optionally build ECPG interface module
+ #
+ AC_MSG_CHECKING([whether to build ecpg])
+ PGAC_ARG_BOOL(with, ecpg, yes, [  --without-ecpg          do not build ecpg interface])
+ AC_MSG_RESULT([$with_ecpg])
+ AC_SUBST(with_ecpg)
+
+ #
+ # Optionally build PGEASY interface module
+ #
+ AC_MSG_CHECKING([whether to build libpgeasy])
+ PGAC_ARG_BOOL(with, pgeasy, yes, [  --without-pgeasy        do not build libpgeasy interface])
+ AC_MSG_RESULT([$with_pgeasy])
+ AC_SUBST(with_pgeasy)
+

  #
  # Tcl/Tk
Index: src/interfaces/Makefile
===================================================================
RCS file: /home/projects/pgsql/cvsroot/pgsql/src/interfaces/Makefile,v
retrieving revision 1.45
diff -u -c -r1.45 Makefile
*** src/interfaces/Makefile    2001/03/09 21:50:27    1.45
--- src/interfaces/Makefile    2001/06/15 16:25:03
***************
*** 12,20 ****
  top_builddir = ../..
  include $(top_builddir)/src/Makefile.global

! DIRS := libpq ecpg libpgeasy

! ALLDIRS := $(DIRS) odbc libpq++ libpgtcl perl5 python jdbc

  ifeq ($(enable_odbc), yes)
  DIRS += odbc
--- 12,28 ----
  top_builddir = ../..
  include $(top_builddir)/src/Makefile.global

! DIRS := libpq

! ALLDIRS := $(DIRS) ecpg libpgeasy odbc libpq++ libpgtcl perl5 python jdbc
!
! ifeq ($(enable_ecpg), yes)
! DIRS += ecpg
! endif
!
! ifeq ($(enable_pgeasy), yes)
! DIRS += libpgeasy
! endif

  ifeq ($(enable_odbc), yes)
  DIRS += odbc

Re: switch for disabling ecpg & pgeasy

From
Peter Eisentraut
Date:
Marko Kreen writes:

> * configure switches for disabling ECPG and libpgeasy
>   compile, as they are not used always

I'm positive the patch as posted does not work.

Anyway, I don't think "not always used" is a good reason to add even more
switches to configure.

--
Peter Eisentraut   peter_e@gmx.net   http://funkturm.homeip.net/~peter


Re: switch for disabling ecpg & pgeasy

From
Tom Lane
Date:
Marko Kreen <marko@l-t.ee> writes:
> * configure switches for disabling ECPG and libpgeasy
>   compile, as they are not used always

Why bother?  They don't take long to compile, and if we make them
optional they'll just get less testing coverage.  (Admittedly,
finding out whether something compiles doesn't prove it will work,
but it's a lot better than no testing at all.)

More to the point, if we start making bits and pieces optionally
compiled "just because", we will soon have a list of configure options
so long that you can't find the important stuff.  I think we should keep
the configure options to the minimum.

            regards, tom lane

Re: switch for disabling ecpg & pgeasy

From
Marko Kreen
Date:
On Fri, Jun 15, 2001 at 07:59:08PM +0200, Peter Eisentraut wrote:
> Marko Kreen writes:
>
> > * configure switches for disabling ECPG and libpgeasy
> >   compile, as they are not used always
>
> I'm positive the patch as posted does not work.

Oh.  Damn.  Wrong var name and I did not update
Makefile.global.in...  Actually, it _did_ work - it
definitely disabled compiling both... ;)

> Anyway, I don't think "not always used" is a good reason to add even more
> switches to configure.

As Tom also opposed it, I guess I better forget it too.

--
marko


Re: switch for disabling ecpg & pgeasy

From
Bruce Momjian
Date:
> On Fri, Jun 15, 2001 at 07:59:08PM +0200, Peter Eisentraut wrote:
> > Marko Kreen writes:
> >
> > > * configure switches for disabling ECPG and libpgeasy
> > >   compile, as they are not used always
> >
> > I'm positive the patch as posted does not work.
>
> Oh.  Damn.  Wrong var name and I did not update
> Makefile.global.in...  Actually, it _did_ work - it
> definitely disabled compiling both... ;)
>
> > Anyway, I don't think "not always used" is a good reason to add even more
> > switches to configure.
>
> As Tom also opposed it, I guess I better forget it too.

On a related topic, is libpgeasy useful?  I wrote it because I liked how
easy it was to write stuff in C and eventually moved it from /contrib
to /interfaces.  Is it useful for anyone else or should I move it back
to /contrib?

--
  Bruce Momjian                        |  http://candle.pha.pa.us
  pgman@candle.pha.pa.us               |  (610) 853-3000
  +  If your life is a hard drive,     |  830 Blythe Avenue
  +  Christ can be your backup.        |  Drexel Hill, Pennsylvania 19026