|
Home > Archive > PostgreSQL Discussion > April 2006 > Postgres Library natively available for Mac OSX Intel?
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
Postgres Library natively available for Mac OSX Intel?
|
|
| Philipp Ott 2006-03-31, 3:30 am |
| Hello!
I would like to know if somebody already has a Mac OSX Intel 10.4.5
pg-Library (for C, C++, Objective C) or knows how to compile it?
Or even better, a fat-library (powerpc, i386) would be even better :-)
Thanks for any information,
regards
Philipp Ott
---------------------------(end of broadcast)---------------------------
TIP 3: Have you checked our extensive FAQ?
http://www.postgresql.org/docs/faq
| |
| User Roman 2006-04-07, 7:34 am |
| # philipp.ott@avalon.at / 2006-03-31 10:05:06 +0200:
> I would like to know if somebody already has a Mac OSX Intel 10.4.5
> pg-Library (for C, C++, Objective C) or knows how to compile it?
What problems did you have building libpq?
Note: I'm not an OSX user.
--
How many Vietnam vets does it take to screw in a light bulb?
You don't know, man. You don't KNOW.
Cause you weren't THERE. http://bash.org/?255991
---------------------------(end of broadcast)---------------------------
TIP 3: Have you checked our extensive FAQ?
http://www.postgresql.org/docs/faq
| |
| Philipp Ott 2006-04-08, 7:26 am |
| Hello!
Am 07.04.2006 um 13:50 schrieb User Roman:
> # philipp.ott@avalon.at / 2006-03-31 10:05:06 +0200:
>
> What problems did you have building libpq?
>
> Note: I'm not an OSX user.
I just wanted to know - I would like to have universal binaries of
libpg and psql to deploy.
Currently 8.1.3 compiles and runs just fine on OSX 10.4.6 + XCode
2.2.1, but generates binaries just for the current host architecture.
Now when I add -arch i386 -arch ppc to CFLAGS and LDFLAGS for
configure, then it compiles everything just fine, however at linking
stage I get various problems for missing architecture files. Every
generated .o file in the src build tree is actually an universal
binary now, like for example
../src/timezone/SUBSYS.o:
Mach header
magic cputype cpusubtype filetype ncmds sizeofcmds flags
0xfeedface 7 3 1 4 852 0x00002000
Fat headers
fat_magic 0xcafebabe
nfat_arch 2
architecture 0
cputype 7
cpusubtype 3
offset 64
size 48100
align 2^5 (32)
architecture 1
cputype 18
cpusubtype 0
offset 48192
size 69332
align 2^5 (32)
../src/timezone/zic.o:
Mach header
magic cputype cpusubtype filetype ncmds sizeofcmds flags
0xfeedface 7 3 1 3 772 0x00002000
So when make comes to the first linking this happens:
gcc -no-cpp-precomp -arch i386 -arch ppc -Wall -Wmissing-prototypes -
Wpointer-arith -Winline -Wdeclaration-after-statement -Wendif-labels -
fno-strict-aliasing -L../../src/port -arch i386 -arch ppc access/
SUBSYS.o bootstrap/SUBSYS.o catalog/SUBSYS.o parser/SUBSYS.o commands/
SUBSYS.o executor/SUBSYS.o lib/SUBSYS.o libpq/SUBSYS.o main/SUBSYS.o
nodes/SUBSYS.o optimizer/SUBSYS.o port/SUBSYS.o postmaster/SUBSYS.o
regex/SUBSYS.o rewrite/SUBSYS.o storage/SUBSYS.o tcop/SUBSYS.o utils/
SUBSYS.o ../../src/timezone/SUBSYS.o ../../src/port/
libpgport_srv.a -lz -lreadline -lresolv -ldl -lm -o postgres
/usr/bin/ld: for architecture ppc
/usr/bin/ld: warning access/SUBSYS.o cputype (7, architecture i386)
does not match cputype (18) for specified -arch flag: ppc (file not
loaded)
/usr/bin/ld: warning bootstrap/SUBSYS.o cputype (7, architecture
i386) does not match cputype (18) for specified -arch flag: ppc (file
not loaded)
/usr/bin/ld: warning catalog/SUBSYS.o cputype (7, architecture i386)
does not match cputype (18) for specified -arch flag: ppc (file not
loaded)
/usr/bin/ld: warning parser/SUBSYS.o cputype (7, architecture i386)
does not match cputype (18) for specified -arch flag: ppc (file not
loaded)
/usr/bin/ld: warning commands/SUBSYS.o cputype (7, architecture i386)
does not match cputype (18) for specified -arch flag: ppc (file not
loaded)
/usr/bin/ld: warning executor/SUBSYS.o cputype (7, architecture i386)
does not match cputype (18) for specified -arch flag: ppc (file not
loaded)
/usr/bin/ld: warning lib/SUBSYS.o cputype (7, architecture i386) does
not match cputype (18) for specified -arch flag: ppc (file not loaded)
/usr/bin/ld: warning libpq/SUBSYS.o cputype (7, architecture i386)
does not match cputype (18) for specified -arch flag: ppc (file not
loaded)
/usr/bin/ld: warning main/SUBSYS.o cputype (7, architecture i386)
does not match cputype (18) for specified -arch flag: ppc (file not
loaded)
/usr/bin/ld: warning nodes/SUBSYS.o cputype (7, architecture i386)
does not match cputype (18) for specified -arch flag: ppc (file not
loaded)
/usr/bin/ld: warning optimizer/SUBSYS.o cputype (7, architecture
i386) does not match cputype (18) for specified -arch flag: ppc (file
not loaded)
/usr/bin/ld: warning port/SUBSYS.o cputype (7, architecture i386)
does not match cputype (18) for specified -arch flag: ppc (file not
loaded)
/usr/bin/ld: warning postmaster/SUBSYS.o cputype (7, architecture
i386) does not match cputype (18) for specified -arch flag: ppc (file
not loaded)
/usr/bin/ld: warning regex/SUBSYS.o cputype (7, architecture i386)
does not match cputype (18) for specified -arch flag: ppc (file not
loaded)
/usr/bin/ld: warning rewrite/SUBSYS.o cputype (7, architecture i386)
does not match cputype (18) for specified -arch flag: ppc (file not
loaded)
/usr/bin/ld: warning storage/SUBSYS.o cputype (7, architecture i386)
does not match cputype (18) for specified -arch flag: ppc (file not
loaded)
/usr/bin/ld: warning tcop/SUBSYS.o cputype (7, architecture i386)
does not match cputype (18) for specified -arch flag: ppc (file not
loaded)
/usr/bin/ld: warning utils/SUBSYS.o cputype (7, architecture i386)
does not match cputype (18) for specified -arch flag: ppc (file not
loaded)
/usr/bin/ld: warning ../../src/timezone/SUBSYS.o cputype (7,
architecture i386) does not match cputype (18) for specified -arch
flag: ppc (file not loaded)
/usr/bin/ld: Undefined symbols:
_main
collect2: ld returned 1 exit status
lipo: can't open input file: /var/tmp//cc0yANLg.out (No such file or
directory)
make[2]: *** [postgres] Error 1
make[1]: *** [all] Error 2
make: *** [all] Error 2
However all the mentioned .o files in this linking list above are
both architecture 7 and 18.
Did someone else encounter similar problems and could fix this and
let me know please?
I used
configure CFLAGS="-arch i386 -arch ppc" LDFLAGS="-arch i386 -arch ppc"
for the initial configure run.
Thank you
Philipp
---------------------------(end of broadcast)---------------------------
TIP 9: In versions below 8.0, the planner will ignore your desire to
choose an index scan if your joining column's datatypes do not
match
| |
| User Roman 2006-04-08, 11:26 am |
| # philipp.ott@avalon.at / 2006-04-08 14:04:28 +0200:
> Am 07.04.2006 um 13:50 schrieb User Roman:
>
> I just wanted to know - I would like to have universal binaries of
> libpg and psql to deploy.
>
> Currently 8.1.3 compiles and runs just fine on OSX 10.4.6 + XCode
> 2.2.1, but generates binaries just for the current host architecture.
> Now when I add -arch i386 -arch ppc to CFLAGS and LDFLAGS for
> configure, then it compiles everything just fine, however at linking
> stage I get various problems for missing architecture files. Every
> generated .o file in the src build tree is actually an universal
> binary now, like for example
sorry, this is way over my head.
--
How many Vietnam vets does it take to screw in a light bulb?
You don't know, man. You don't KNOW.
Cause you weren't THERE. http://bash.org/?255991
---------------------------(end of broadcast)---------------------------
TIP 4: Have you searched our list archives?
http://archives.postgresql.org
|
|
|
|
|