Skip site navigation (1) Skip section navigation (2)

Re: build annoyences

From: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
To: Michiel Ephraim <ephraim(at)euph1(dot)xs4all(dot)nl>
Cc: pgsql-hackers-win32(at)postgresql(dot)org,PostgreSQL-patches <pgsql-patches(at)postgresql(dot)org>
Subject: Re: build annoyences
Date: 2004-04-26 17:42:24
Message-ID: 200404261742.i3QHgOe15855@candle.pha.pa.us (view raw or flat)
Thread:
Lists: pgsql-hackers-win32pgsql-patches
Michiel Ephraim wrote:
> On Tuesday 20 April 2004 00:32, Bruce Momjian wrote:
> > Michiel Ephraim wrote:
> > > dear hackers-win32 list,
> > >
> > > When building today's CVS version for win32, i found a few little things
> > > which stopped a clean "gmake && gmake install". Most of them are missing
> > > .exe extensions in the makefiles.
> > >
> > > A diff is attached to this mail. Changes to
> > > "src/makefiles/Makefile.win32" were only necessary for cross-compilation.
> > >
> > > My setup is
> > > 	compiler: mingw32-gcc (GCC) 3.3.1 (mingw special 20030804-1)
> > > 	host: FreeBSD euph4 5.2-RELEASE
> > > 	configure options used: --host=mingw32 --prefix=/opt/postgres-mingw32
> > > --without-readline --without-zlib
> > >
> > > The gcc is setup as a cross-compiler for mingw32, and is simply installed
> > > from ports.
> >
> > Interesting.  I am confused why others didn't need these changes.  In
> > psql's Makefile I see:
> >
> > 	psql: $(OBJS) $(libpq_builddir)/libpq.a
> > 	        $(CC) $(CFLAGS) $(OBJS) $(libpq) $(LDFLAGS) $(LIBS) -o $@
> > 	...
> >
> > 	install: all installdirs
> > 	        $(INSTALL_PROGRAM) psql$(X) $(DESTDIR)$(bindir)/psql$(X)
> >
> > Why do other compilers output .exe from CC?  Is it because you are
> > cross-compiling?  Also, why did you need to change the #include in
> > snprintf?
> 
> Hi Bruce,
> 
> Thanks for the response.
> 
> Most likely you are right about the cross-compiling. In that case the compiler 
> doesn't add the .exe by itself. Actually in one case, there was already a 
> $(X) in the link line. So, I guess, it doesn't hurt.

Yes, I see that backend/Makefile already had the $(X) for link lines so
it seems it is necessary.  I applied the attached patch that adds $(X)
to the other links.

I don't think we have a lot of folks using a mingw compiler on Unix
systems, yet.  :-)

Thanks.


-- 
  Bruce Momjian                        |  http://candle.pha.pa.us
  pgman(at)candle(dot)pha(dot)pa(dot)us               |  (610) 359-1001
  +  If your life is a hard drive,     |  13 Roberts Road
  +  Christ can be your backup.        |  Newtown Square, Pennsylvania 19073

In response to

pgsql-patches by date

Next:From: Bruce MomjianDate: 2004-04-27 02:16:19
Subject: Re: [BUGS] BUG #1134: ALTER USER ... RENAME breaks md5 passwords
Previous:From: Bruce MomjianDate: 2004-04-26 17:09:34
Subject: Re: aclitem accessor functions

pgsql-hackers-win32 by date

Next:From: Merlin MoncureDate: 2004-04-28 16:26:29
Subject: PostgreSQL #1
Previous:From: Tom LaneDate: 2004-04-24 03:15:52
Subject: Re: Build error

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group