Thread: Re: Glibc2 (was Re: [HACKERS] PostgreSQL - the Linux of Databases...)

Re: Glibc2 (was Re: [HACKERS] PostgreSQL - the Linux of Databases...)

From
plh@opim.uconn.edu
Date:
Tom:

It just occurred to me that, maybe we should ask Cristian which gcc version
was used to build the pgsql rpm at redhat. Like I mentioned, with gcc-2.8.0
and glibc2-2.0.7 rpm, I did get the time problem, but with gcc-2.7.2.3, it
went away. Also with the helpful info Tom (Szybist) provided, this seems to
make sense, that is, a recompile with gcc-2.7.2 cures the problem, if the rpm
was indeed built with gcc-2.8.0 at redhat, that explains it.

hope this helps,
-Pailing

Re: Glibc2 (was Re: [HACKERS] PostgreSQL - the Linux of Databases...)

From
"Thomas G. Lockhart"
Date:
Got a good install from Cristian's latest Postgres rpm and the Feb 24 glibc2
found in his home area. Passed the "one minute" test.

Thanks Cristian! What was the secret? Was it the compiler, or -O setting, or ??

btw, there is a one-line patch you could apply before doing a full release; it
fixes an obscure but occasionally useful feature in the type support code. I
haven't committed it to the source tree yet.

                                                  - Tom
*** ../src/backend/utils/fmgr/fmgr.c.orig    Thu Feb 26 04:37:40 1998
--- ../src/backend/utils/fmgr/fmgr.c    Wed Mar  4 13:44:55 1998
***************
*** 199,204 ****
--- 199,205 ----
                  if (!finfo->fn_addr)
                      elog(ERROR, "fmgr_info: function %s: not in internal table",
                           procedureStruct->proname.data);
+                 finfo->fn_nargs = procedureStruct->pronargs;
                  break;
              case ClanguageId:
                  finfo->fn_addr = fmgr_dynamic(procedureId, &(finfo->fn_nargs));

Re: Glibc2 (was Re: [HACKERS] PostgreSQL - the Linux of Databases...)

From
Cristian Gafton
Date:
On 4 Mar 1998 plh@opim.uconn.edu wrote:

> It just occurred to me that, maybe we should ask Cristian which gcc version
> was used to build the pgsql rpm at redhat. Like I mentioned, with gcc-2.8.0

gcc 2.7.2.3

> and glibc2-2.0.7 rpm, I did get the time problem, but with gcc-2.7.2.3, it
> went away. Also with the helpful info Tom (Szybist) provided, this seems to
> make sense, that is, a recompile with gcc-2.7.2 cures the problem, if the rpm
> was indeed built with gcc-2.8.0 at redhat, that explains it.

I think you "recompile" a newer version than the snapshot included in the
SRPM ?

Cristian
--
----------------------------------------------------------------------
Cristian Gafton   --   gafton@redhat.com   --   Red Hat Software, Inc.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 UNIX is user friendly. It's just selective about who its friends are.




Re: Glibc2 (was Re: [HACKERS] PostgreSQL - the Linux of Databases...)

From
Cristian Gafton
Date:
On Thu, 5 Mar 1998, Thomas G. Lockhart wrote:

> Thanks Cristian! What was the secret? Was it the compiler, or -O setting, or ??

You're welcome !

I just got a newer snapshot and recompiled it.

> btw, there is a one-line patch you could apply before doing a full release; it

Thanks, I'll do new rpms.

Cristian
--
----------------------------------------------------------------------
Cristian Gafton   --   gafton@redhat.com   --   Red Hat Software, Inc.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 UNIX is user friendly. It's just selective about who its friends are.




Re: Glibc2 (was Re: [HACKERS] PostgreSQL - the Linux of Databases...)

From
"Thomas A. Szybist"
Date:
In message <Pine.LNX.3.96.980304224737.24372H-100000@shefu.redhat.com>, Cristian Gafton wr
ites:
> On Thu, 5 Mar 1998, Thomas G. Lockhart wrote:
>
> > Thanks Cristian! What was the secret? Was it the compiler, or -O setting, or ??
>
> You're welcome !
>
> I just got a newer snapshot and recompiled it.

Of what? Glibc?

>
> > btw, there is a one-line patch you could apply before doing a full release; it
>
> Thanks, I'll do new rpms.
>
> Cristian
> --
> ----------------------------------------------------------------------
> Cristian Gafton   --   gafton@redhat.com   --   Red Hat Software, Inc.
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>  UNIX is user friendly. It's just selective about who its friends are.
>
>
>
>

I don't mean to be a party pooper, but... It must be a header file some
place.  I'm just courious as to what the difference is.  Anybody know?

After installing 2.0.7 from Cristian, I went back an installed the
2.0.5 header files, recompiled, and sure enough, it bombed with the 60
sec thing.  Now, that's a 2.0.7 glibc with 2.0.5 header files.

I ran a diff on the header files, and there is only a modest amount of
changes.  I was looking at this when low and behold, my wife went into
labor!  (I was waiting for this before posting my bio :).

This seems simple enough for me.  I'd like to figure it out, but I'm
Mr. Mom with a 2 year old for awhile.

If you're interested in a baby picture, check out http://24.3.148.6.

Tom
szybist@boxhill.com

Re: Glibc2 (was Re: [HACKERS] PostgreSQL - the Linux of Databases...)

From
Cristian Gafton
Date:
On Sat, 7 Mar 1998, Thomas A. Szybist wrote:

> > > Thanks Cristian! What was the secret? Was it the compiler, or -O setting, or ??
> >
> > You're welcome !
> >
> > I just got a newer snapshot and recompiled it.
>
> Of what? Glibc?

No, postgresql, because that is what we were talking about...
Despite the subject of the thread.

Cristian
--
----------------------------------------------------------------------
Cristian Gafton   --   gafton@redhat.com   --   Red Hat Software, Inc.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 UNIX is user friendly. It's just selective about who its friends are.




Re: Glibc2 (was Re: [HACKERS] PostgreSQL - the Linux of Databases...)

From
"Thomas A. Szybist"
Date:
In message <Pine.LNX.3.96.980307231533.20654E-100000@shefu.redhat.com>, Cristian Gafton w
rites:
> On Sat, 7 Mar 1998, Thomas A. Szybist wrote:
>
> > > > Thanks Cristian! What was the secret? Was it the compiler, or -O setting, or ??
> > >
> > > You're welcome !
> > >
> > > I just got a newer snapshot and recompiled it.
> >
> > Of what? Glibc?
>
> No, postgresql, because that is what we were talking about...
> Despite the subject of the thread.
>
> Cristian
> --
> ----------------------------------------------------------------------
> Cristian Gafton   --   gafton@redhat.com   --   Red Hat Software, Inc.
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>  UNIX is user friendly. It's just selective about who its friends are.
>
>
>
>
Sorry, I guess I lost track of the snapshots you were packaging.

I think __math.h is the file.  Here is small diff (cut & paste) from
2.0.5 to 2.0.7:

*** __math.h205 Sun Mar  8 00:00:29 1998
--- __math.h207 Tue Feb 24 16:34:38 1998


<snip>

    ***************
    *** 21,30 ****
      #ifndef __MATH_H
      #define __MATH_H      1

    ! #if defined __GNUG__ && \
    !     (__GNUC__ < 2 || (__GNUC__ == 2 && __GNUC_MINOR__ <= 7))
    ! /* gcc 2.7.2 and 2.7.2.1 have problems with inlining `long double'
    !    functions so we disable this now.  */
      #undef __NO_MATH_INLINES
      #define __NO_MATH_INLINES
      #endif
    --- 21,29 ----
      #ifndef __MATH_H
      #define __MATH_H      1

    ! #if (__GNUC__ < 2 || (__GNUC__ == 2 && __GNUC_MINOR__ <= 7))
    ! /* The gcc, version 2.7 or below, has problems with all this inlining
    !    code.  So disable it for this version of the compiler.  */
      #undef __NO_MATH_INLINES
      #define __NO_MATH_INLINES
      #endif
    ***************
    *** 484,492 ****


It seems __NO_MATH_INLINES must be defined.  2.0.5 tests for __GNUG__.
2.0.7 does not, but only checks for __GNUC_MINOR__ <= 7. This would
explain why 2.8.0 also fails.


Tom Szybist

szybist@boxhill.com

Re: Glibc2 (was Re: [HACKERS] PostgreSQL - the Linux of Databases...)

From
Cristian Gafton
Date:
On Sun, 8 Mar 1998, Thomas A. Szybist wrote:

> Sorry, I guess I lost track of the snapshots you were packaging.
>
> I think __math.h is the file.  Here is small diff (cut & paste) from
> 2.0.5 to 2.0.7:

All I am interested _now_ is if the glibc + postgresql packages from
ftp;//ftp.redhat.com/home/gafton are working okay for everybody...

Cristian
--
----------------------------------------------------------------------
Cristian Gafton   --   gafton@redhat.com   --   Red Hat Software, Inc.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 UNIX is user friendly. It's just selective about who its friends are.




Re: Glibc2 (was Re: [HACKERS] PostgreSQL - the Linux of Databases...)

From
"Thomas A. Szybist"
Date:
In message <Pine.LNX.3.96.980308002949.20654F-100000@shefu.redhat.com>, Cristian Gafton w
rites:
> On Sun, 8 Mar 1998, Thomas A. Szybist wrote:
>
> > Sorry, I guess I lost track of the snapshots you were packaging.
> >
> > I think __math.h is the file.  Here is small diff (cut & paste) from
> > 2.0.5 to 2.0.7:
>
> All I am interested _now_ is if the glibc + postgresql packages from
> ftp;//ftp.redhat.com/home/gafton are working okay for everybody...
>
> Cristian
> --
> ----------------------------------------------------------------------
> Cristian Gafton   --   gafton@redhat.com   --   Red Hat Software, Inc.
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>  UNIX is user friendly. It's just selective about who its friends are.
>
>
Just trying to help... sorry.

Tom Szybist
szybist@boxhill.com