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

Re: Pg 7.2.3 int8 value out of range

From: Brian Macy <bmacy(at)macykids(dot)net>
To: Lamar Owen <lamar(dot)owen(at)wgcr(dot)org>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, pgsql-bugs(at)postgresql(dot)org
Subject: Re: Pg 7.2.3 int8 value out of range
Date: 2002-10-18 04:19:44
Message-ID: 3DAF8BE0.8060500@macykids.net (view raw or flat)
Thread:
Lists: pgsql-bugs
Debian is 32bit user land.
boaz:~# file /usr/lib/postgresql/bin/postgres
/usr/lib/postgresql/bin/postgres: ELF 32-bit MSB executable, SPARC, 
version 1 (SYSV), for GNU/Linux 2.2.0, dynamically linked (uses shared 
libs), stripped

Since it is debian it's prebuilt but i'll try building it myself....

boaz:~/postgresql-7.2.3# gcc -v
Reading specs from /usr/lib/gcc-lib/sparc-linux/2.95.4/specs
gcc version 2.95.4 20011002 (Debian prerelease)


 From src/lib/pg_config.h
/* Set to 1 if type "long int" works and is 64 bits */
/* #undef HAVE_LONG_INT_64 */

/* Set to 1 if type "long long int" works and is 64 bits */
/* #undef HAVE_LONG_LONG_INT_64 */

/* Set to 1 if type "long long int" constants should be suffixed by LL */
/* #undef HAVE_LL_CONSTANTS */

/* Define this as the appropriate snprintf format for 64-bit ints, if any */
#define INT64_FORMAT "%ld"

/*
  * We need a #define symbol for sizeof(Datum) for use in some #if tests.
  */
#define SIZEOF_DATUM 4



Brian Macy


Lamar Owen wrote:
> On Thursday 17 October 2002 09:28 pm, Tom Lane wrote:
> 
>>Brian Macy <bmacy(at)macykids(dot)net> writes:
>>
>>>Only excepts 32bit values and not 64bit. Endian issue?
>>>This is on sparc linux.
>>
> 
> Specifically Debian.  Aurora SPARC Linux does not suffer from this problem.  
> On Aurora, the userland is 32 bit -- is it possible Debian has a 64 bit 
> userland?  As I detailed in my previous email on this subject, I cannot 
> reproduce the problem on Aurora SPARC Linux build 0.42, which is based on Red 
> Hat 7.3.
> 
> 
>>Hmm, did configure find any working 64bit int type?  Let's see this part
>>of your src/include/pg_config.h file:
> 
> 
>>/* Set to 1 if type "long int" works and is 64 bits */
>>/* #undef HAVE_LONG_INT_64 */
> 
> 
>>/* Set to 1 if type "long long int" works and is 64 bits */
>>#define HAVE_LONG_LONG_INT_64
> 
> 
>>/* Set to 1 if type "long long int" constants should be suffixed by LL */
>>#define HAVE_LL_CONSTANTS 1
> 
> 
>>/* Define this as the appropriate snprintf format for 64-bit ints, if any
>>*/ #define INT64_FORMAT "%lld"
> 
> 
> For Aurora, those lines, along with some others, are:
> /* Set to 1 if type "long int" works and is 64 bits */
> /* #undef HAVE_LONG_INT_64 */
> 
> /* Set to 1 if type "long long int" works and is 64 bits */
> #define HAVE_LONG_LONG_INT_64
> 
> /* Set to 1 if type "long long int" constants should be suffixed by LL */
> #define HAVE_LL_CONSTANTS 1
> 
> /* Define this as the appropriate snprintf format for 64-bit ints, if any */
> #define INT64_FORMAT "%lld"
> 
> /*
>  * We need a #define symbol for sizeof(Datum) for use in some #if tests.
>  */
> #define SIZEOF_DATUM 4
> 
> /*
>  * These must be defined as the alignment requirement (NOT the size) of
>  * each of the basic C data types (except char, which we assume has align 1).
>  * MAXIMUM_ALIGNOF is the largest alignment requirement for any C data type.
>  * ALIGNOF_LONG_LONG_INT need only be defined if HAVE_LONG_LONG_INT_64 is.
>  */
> #define ALIGNOF_SHORT 2
> #define ALIGNOF_INT 4
> #define ALIGNOF_LONG 4
> #define ALIGNOF_LONG_LONG_INT 8
> #define ALIGNOF_DOUBLE 8
> #define MAXIMUM_ALIGNOF 8
> 
> This was built with the RPM spec file using the 'sparc32' utility that builds 
> the sun4 32bit userland executables.


In response to

pgsql-bugs by date

Next:From: Brian MacyDate: 2002-10-18 04:27:33
Subject: Re: Pg 7.2.3 int8 value out of range
Previous:From: Lamar OwenDate: 2002-10-18 03:25:19
Subject: Re: Pg 7.2.3 int8 value out of range

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