X-Original-To: pgsql-admin-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 1511C52869 for ; Wed, 8 Jun 2005 20:27:09 -0300 (ADT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 81284-04 for ; Wed, 8 Jun 2005 23:27:07 +0000 (GMT) Received: from ms-smtp-02-eri0.socal.rr.com (ms-smtp-02-qfe0.socal.rr.com [66.75.162.134]) by svr1.postgresql.org (Postfix) with ESMTP id A34CA52899 for ; Wed, 8 Jun 2005 20:27:05 -0300 (ADT) Received: from san.rr.com (cpe-204-210-30-137.san.res.rr.com [204.210.30.137]) by ms-smtp-02-eri0.socal.rr.com (8.12.10/8.12.7) with ESMTP id j58NR3X7012852; Wed, 8 Jun 2005 16:27:04 -0700 (PDT) Message-ID: <42A77E1F.4AA6A98C@san.rr.com> Date: Wed, 08 Jun 2005 16:24:15 -0700 From: Wayne Schroeder X-Mailer: Mozilla 4.77 [en] (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: pgsql-admin@postgresql.org Cc: schroede@sdsc.edu Subject: Re: Is there a way to build 32-bit mode on 64-bit Linux boxes? References: <42A73B13.6112A98A@san.rr.com> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Virus-Scanned: Symantec AntiVirus Scan Engine X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.649 tagged_above=0 required=5 tests=AWL, DNS_FROM_RFC_ABUSE, DNS_FROM_RFC_WHOIS X-Spam-Level: X-Archive-Number: 200506/54 X-Sequence-Number: 17809 I need to back up a bit and explain why I was hoping there was a better way to build everything as 32-bit. On a 64-bit Linux host, if I just try to build as usual, I get errors in my MCAT app since it is not 64-bit compatible yet. If I try to build everything (postgresql, odbc, and mcat) 32-bit, I get different errors, starting with postgresql. If I try to build postgresql 64-bit and odbc 32-bit I get different errors. (To try to build in 32-bit mode, I have my install.pl script set environment variables CFLAGS and LDFLAGS to -m32. This may not be all that is needed, but I figured it was worth a shot.) When trying to build all 3 as 32-bit, I get this when building postgresql: ./configure --prefix=/scratch/slocal/schroede/test2/pgsql --enable-odbc --without-readline gmake /usr/bin/ld: Relocatable linking with relocations from format elf32-i386 (heaptuple.o) to format elf64-x86-64 (SUBSYS.o) is not supported gmake[4]: *** [SUBSYS.o] Error 1 gmake[3]: *** [common-recursive] Error 2 gmake[2]: *** [access-recursive] Error 2 gmake[1]: *** [all] Error 2 gmake: *** [all] Error 2 When I try to build postgresql 64-bit and odbc 32-bit, postgresql builds fine, but I get this when trying odbc: ./configure --prefix=/scratch/slocal/schroede/test2/pgsql --enable-static gmake /usr/bin/ld: warning: i386 architecture of input file `info.lo' is incompatible with i386:x86-64 output /usr/bin/ld: warning: i386 architecture of input file `bind.lo' is incompatible with i386:x86-64 output and the same warning for: columninfo.lo, connection.lo, convert.lo, drvconn.lo, environ.lo, execute.lo, lobj.lo, win_md5.lo, misc.lo options.lo, pgtypes.lo, psqlodbc.lo, qresult.lo, results.lo, socket.lo, parse.lo, statement.lo, tuple.lo, tuplelist.lo, dlg_specific.lo, odbcapi.lo, multibyte.lo, gpps.lo, odbcapi30.lo, pgapi30.lo, and info30.lo. Those are warnings, but apparently it makes the library 64-bit because then when it tries to link my MCAT/SRB app, I get: gmake /usr/bin/ld: skipping incompatible /scratch/slocal/schroede/test2/pgsql/lib/libpsqlodbc.a when searching for -lpsqlodbc /usr/bin/ld: cannot find -lpsqlodbc collect2: ld returned 1 exit status So is this second mode, 64 bit postgresql and 32 bit odbc, that I should try to get working? Or would the all-32-bit have a better chance? Am I the only one with this 32/64-bit problem? We will convert our app to 64-bit sometime, but if there is a fairly easy workaround for now, I'd like to make use of it. Otherwise, we'll just continue to say we can't support MCAT on 64-bit linux boxes (for now). - Wayne -