Обсуждение: 7.3 Beta 1 Build Error on Cygwin

Поиск
Список
Период
Сортировка

7.3 Beta 1 Build Error on Cygwin

От
"Dave Page"
Дата:
I get the following error when building beta 1 on CYGWIN_NT-5.1 PC9
1.3.10(0.51/3/2) 2002-02-25 11:14 i686 unknown:

make[3]: Entering directory
`/usr/local/src/postgresql-7.3b1/src/backend/utils/mb/conversion_procs/c
yrillic_and_mic'
gcc -O2 -Wall -Wmissing-prototypes -Wmissing-declarations
-I../../../../../../src/include -I/usr/local/include -DBUILDING_DLL=1
-c -o cyrillic_and_mic.o cyrillic_and_mic.c
dlltool --export-all --output-def cyrillic_and_mic.def
cyrillic_and_mic.o
dllwrap -o cyrillic_and_mic.dll --dllname cyrillic_and_mic.dll --def
cyrillic_and_mic.def cyrillic_and_mic.o
../../../../../../src/utils/dllinit.o -lcygipc -lcrypt -L/usr/local/lib
-L../../../../../../src/backend -lpostgres
Warning: resolving _CurrentMemoryContext by linking to
__imp__CurrentMemoryContext (auto-import)
fu000001.o(.idata$3+0xc): undefined reference to `libpostgres_a_iname'
fu000002.o(.idata$3+0xc): undefined reference to `libpostgres_a_iname'
fu000003.o(.idata$3+0xc): undefined reference to `libpostgres_a_iname'
fu000004.o(.idata$3+0xc): undefined reference to `libpostgres_a_iname'
fu000005.o(.idata$3+0xc): undefined reference to `libpostgres_a_iname'
fu000006.o(.idata$3+0xc): more undefined references to
`libpostgres_a_iname' follow
nmth000000.o(.idata$4+0x0): undefined reference to
`_nm__CurrentMemoryContext'
collect2: ld returned 1 exit status
dllwrap: gcc exited with status 1
make[3]: *** [cyrillic_and_mic.dll] Error 1
make[3]: Leaving directory
`/usr/local/src/postgresql-7.3b1/src/backend/utils/mb
/conversion_procs/cyrillic_and_mic'
make[2]: *** [all] Error 2
make[2]: Leaving directory
`/usr/local/src/postgresql-7.3b1/src/backend/utils/mb
/conversion_procs'
make[1]: *** [all] Error 2
make[1]: Leaving directory `/usr/local/src/postgresql-7.3b1/src'
make: *** [all] Error 2
PC9 $

Regards, Dave

Re: 7.3 Beta 1 Build Error on Cygwin

От
Jason Tishler
Дата:
Dave,

On Thu, Sep 05, 2002 at 12:54:50PM +0100, Dave Page wrote:
> I get the following error when building beta 1 on CYGWIN_NT-5.1 PC9
> 1.3.10(0.51/3/2) 2002-02-25 11:14 i686 unknown:
>
> make[3]: Entering directory `/usr/local/src/postgresql-7.3b1/src/backend/utils/mb/conversion_procs/cyrillic_and_mic'
> gcc -O2 -Wall -Wmissing-prototypes -Wmissing-declarations -I../../../../../../src/include -I/usr/local/include
-DBUILDING_DLL=1-c -o cyrillic_and_mic.o cyrillic_and_mic.c 
> [snip]
> dllwrap -o cyrillic_and_mic.dll --dllname cyrillic_and_mic.dll --def cyrillic_and_mic.def cyrillic_and_mic.o
../../../../../../src/utils/dllinit.o-lcygipc -lcrypt -L/usr/local/lib -L../../../../../../src/backend -lpostgres 
> Warning: resolving _CurrentMemoryContext by linking to __imp__CurrentMemoryContext (auto-import)
> [snip]
> nmth000000.o(.idata$4+0x0): undefined reference to `_nm__CurrentMemoryContext'

I just submitted a patch to pgsql-patches to fix the above and to add a
couple of missing DLLIMPORTs to src/include/miscadmin.h.

FYI, plperl no longer builds cleanly against Cygwin Perl 5.6.1 because
PostgreSQL no longer uses the Perl extension infrastructure.  However,
upgrading Cygwin Perl to 5.8.0 solves the problem because this version
uses the conventional name for libperl.a instead of one that has the
version embedded in it.

Thanks again for the heads up.

Jason

Re: 7.3 Beta 1 Build Error on Cygwin

От
"Dave Page"
Дата:

> -----Original Message-----
> From: Jason Tishler [mailto:jason@tishler.net]
> Sent: 05 September 2002 16:30
> To: Dave Page
> Cc: pgsql-hackers; pgsql-cygwin
> Subject: Re: [CYGWIN] 7.3 Beta 1 Build Error on Cygwin
>
>
> I just submitted a patch to pgsql-patches to fix the above
> and to add a couple of missing DLLIMPORTs to src/include/miscadmin.h.

Yup, saw that, thanks.

> FYI, plperl no longer builds cleanly against Cygwin Perl
> 5.6.1 because PostgreSQL no longer uses the Perl extension
> infrastructure.  However, upgrading Cygwin Perl to 5.8.0
> solves the problem because this version uses the conventional
> name for libperl.a instead of one that has the version embedded in it.

I'll bear that in mind, though I don't normally use Perl.

> Thanks again for the heads up.

You're welcome, just trying to get a headstart on the testing of pgAdmin
for 7.3 and the 7.3 regression testing...

> Jason
>

Re: [HACKERS] 7.3 Beta 1 Build Error on Cygwin

От
Peter Eisentraut
Дата:
Dave Page writes:

> I get the following error when building beta 1 on CYGWIN_NT-5.1 PC9
> 1.3.10(0.51/3/2) 2002-02-25 11:14 i686 unknown:

Should all be fixed now.

--
Peter Eisentraut   peter_e@gmx.net


Re: [HACKERS] 7.3 Beta 1 Build Error on Cygwin

От
Jason Tishler
Дата:
Peter,

On Thu, Sep 05, 2002 at 08:33:20PM +0200, Peter Eisentraut wrote:
> Dave Page writes:
>
> > I get the following error when building beta 1 on CYGWIN_NT-5.1 PC9
> > 1.3.10(0.51/3/2) 2002-02-25 11:14 i686 unknown:
>
> Should all be fixed now.

Huh?  I don't see any recent CVS commits to indicate this.

Jason

Re: [HACKERS] 7.3 Beta 1 Build Error on Cygwin

От
Bruce Momjian
Дата:
Jason Tishler wrote:
> Peter,
>
> On Thu, Sep 05, 2002 at 08:33:20PM +0200, Peter Eisentraut wrote:
> > Dave Page writes:
> >
> > > I get the following error when building beta 1 on CYGWIN_NT-5.1 PC9
> > > 1.3.10(0.51/3/2) 2002-02-25 11:14 i686 unknown:
> >
> > Should all be fixed now.
>
> Huh?  I don't see any recent CVS commits to indicate this.

I see as a commit:

        Assorted fixes for Cygwin:

        Eliminate the mysterious games that the Cygwin build plays with the linker
        flag variables.  DLLLIBS is gone, use SHLIB_LINK like everyone else.
        Detect cygipc in configure, after the linker flags are set up, otherwise
        configure might not work at all.

        Make sure everything is covered by make clean.

        Fix the build of the new conversion procedure modules.

        Add new DLLIMPORT markers where required.

        Finally, the compiler complains if we use an explicit
        -I/usr/local/include, so don't do that.  Curiously, -L/usr/local/lib is
        still necessary.

I assume it was in there.

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

Re: [HACKERS] 7.3 Beta 1 Build Error on Cygwin

От
Jason Tishler
Дата:
Peter,

On Thu, Sep 05, 2002 at 02:51:31PM -0400, Bruce Momjian wrote:
> Jason Tishler wrote:
> > On Thu, Sep 05, 2002 at 08:33:20PM +0200, Peter Eisentraut wrote:
> > > Should all be fixed now.
> >
> > Huh?  I don't see any recent CVS commits to indicate this.
>
> I see as a commit:
>
> [snip]
>
> I assume it was in there.

Sorry for the noise, but at the time:

    cvs status include/miscadmin.h makefiles/Makefile.win

did *not* indicate any recent commits.  Maybe you sent the above email
before you committed your changes?

Anyway, I just tried a:

    make distclean
    rm include/miscadmin.h makefiles/Makefile.win # remove my patch
    cvs update
    make

and got the following error:

    [snip]
    make[3]: Leaving directory `/home/jt/src/pgsql/src/backend/utils'
    dlltool --dllname postgres.exe --output-exp postgres.exp --def postgres.def
    gcc -L/usr/local/lib  -o postgres.exe -Wl,--base-file,postgres.base postgres.exp access/SUBSYS.o bootstrap/SUBSYS.o
catalog/SUBSYS.oparser/SUBSYS.o commands/SUBSYS.o executor/SUBSYS.o lib/SUBSYS.o libpq/SUBSYS.o main/SUBSYS.o
nodes/SUBSYS.ooptimizer/SUBSYS.o port/SUBSYS.o postmaster/SUBSYS.o regex/SUBSYS.o rewrite/SUBSYS.o storage/SUBSYS.o
tcop/SUBSYS.outils/SUBSYS.o  
    libpq/SUBSYS.o(.text+0x1c84):crypt.c: undefined reference to `crypt'
    port/SUBSYS.o(.text+0x262):pg_sema.c: undefined reference to `semget'
    [snip]

I can get postgres.exe to successfully link by manually appending
"-lcrypt -lcygipc" to the end of the above gcc command line.

Since you are already working on this, would you be willing to fix this
problem?

Thanks,
Jason