Thread: problem installing 8.0.0beta5 on OS X 10.3

problem installing 8.0.0beta5 on OS X 10.3

From
Will Arp
Date:
I'm trying to compile beta5 on osx 10.3.6
without success, I have XCode 1.5 installed.

Could you please give me instructions?
I have readline installed from fink.
Bison is there from Apple.

This is from the Terminal.app:
~/Desktop/postgresql-8.0.0beta5 (alpha) ./configure 
--bindir=/usr/local/bin --mandir=/usr/local/share/man/ --enable-recode 
--enable-syslog --enable-unicode-conversion --enable-multibyte 
--with-includes=/sw/include/ --with-libraries=/sw/lib
checking build system type... powerpc-apple-darwin7.6.0
checking host system type... powerpc-apple-darwin7.6.0
checking which template to use... darwin
checking whether to build with 64-bit integer date/time support... no
checking whether NLS is wanted... no
checking for default port number... 5432
checking for gcc... gcc
checking for C compiler default output... a.out
checking whether the C compiler works... configure: error: cannot run C 
compiled programs.
If you meant to cross compile, use `--host'.

After removing line 2050 to 2077 in configure:

#############################
# Check the compiler produces executables we can run.  If not, either
# the compiler is broken, or we cross compile.
echo "$as_me:$LINENO: checking whether the C compiler works" >&5
echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
# FIXME: These cross compiler hacks should be removed for Autoconf 3.0
# If not cross compiling, check that we can run a simple program.
if test "$cross_compiling" != yes; then  if { ac_try='./$ac_file'  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval$ac_try) 2>&5  ac_status=$?  echo "$as_me:$LINENO: \$? = $ac_status" >&5  (exit $ac_status); }; }; then
cross_compiling=no else    if test "$cross_compiling" = maybe; thencross_compiling=yes    else{ { echo "$as_me:$LINENO:
error:cannot run C compiled programs.
 
If you meant to cross compile, use \`--host'." >&5
echo "$as_me: error: cannot run C compiled programs.
If you meant to cross compile, use \`--host'." >&2;}   { (exit 1); exit 1; }; }    fi  fi
fi
echo "$as_me:$LINENO: result: yes" >&5
echo "${ECHO_T}yes" >&6
#############################

I was able to configure, at least I got:
All of PostgreSQL successfully made. Ready to install.

but then:
~/Desktop/postgresql-8.0.0beta5 (user) sudo make install
make -C doc install
for file in man1/*.1 man7/*.7 ; do \  /bin/sh ../config/install-sh -c -m 644 $file 
/usr/local/share/man//$file || exit; \
done
make -C src install
/bin/sh ../config/mkinstalldirs /usr/local/pgsql/lib/pgxs/src
mkdir -p -- /usr/local/pgsql/lib/pgxs/src
/bin/sh ../config/install-sh -c -m 644 Makefile.global 
/usr/local/pgsql/lib/pgxs/src/Makefile.global
/bin/sh ../config/install-sh -c -m 644 Makefile.port 
/usr/local/pgsql/lib/pgxs/src/Makefile.port
/bin/sh ../config/install-sh -c -m 644 ./Makefile.shlib 
/usr/local/pgsql/lib/pgxs/src/Makefile.shlib
/bin/sh ../config/install-sh -c -m 644 ./nls-global.mk 
/usr/local/pgsql/lib/pgxs/src/nls-global.mk
make -C port install
/bin/sh ../../config/install-sh -c -m 644  libpgport.a 
/usr/local/pgsql/lib
make -C timezone install
make -C ../../src/port all
make[3]: Nothing to be done for `all'.
gcc -no-cpp-precomp -O4 -Wall -Wmissing-prototypes -Wpointer-arith 
-Wendif-labels -fno-strict-aliasing zic.o ialloc.o scheck.o localtime.o 
-L../../src/port -L/sw/lib/  -lpgport -lz -lreadline -lresolv -ldl -lm  
-o zic.out
mkdir -p -- /usr/local/pgsql/share
./zic -d /usr/local/pgsql/share/timezone ./data/africa 
./data/antarctica ./data/asia ./data/australasia ./data/europe 
./data/northamerica ./data/southamerica ./data/pacificnew 
./data/etcetera ./data/factory ./data/backward ./data/systemv 
./data/solar87 ./data/solar88 ./data/solar89
make[2]: ./zic: Command not found
make[2]: *** [install] Error 127
make[1]: *** [install] Error 2
make: *** [install] Error 2



I did remove XCode 1.5, installed XCode 1.2, no difference. 8(

Well If you have an idea, I'd welcome it 8)

Have a nice day!

Will



Re: problem installing 8.0.0beta5 on OS X 10.3

From
Adam Witney
Date:
You shouldn't need to edit configure. I compiled 8.0b5 on 10.3.6 with no
problems yesterday

I am no expert, but this error seems to have come up on other platforms...
Here was the response in the mailing lists before

http://archives.postgresql.org/pgsql-ports/2004-07/msg00001.php

You may also want to report back to the list what your gcc version is?


Also, if you installed readline with fink you may need to configure like so:

./configure --with-libs=/sw/lib --with-includes=/sw/include

(if your fink is installing in /sw of course)

HTH

Adam


> I'm trying to compile beta5 on osx 10.3.6
> without success, I have XCode 1.5 installed.
> 
> Could you please give me instructions?
> I have readline installed from fink.
> Bison is there from Apple.
> 
> This is from the Terminal.app:
> ~/Desktop/postgresql-8.0.0beta5 (alpha) ./configure
> --bindir=/usr/local/bin --mandir=/usr/local/share/man/ --enable-recode
> --enable-syslog --enable-unicode-conversion --enable-multibyte
> --with-includes=/sw/include/ --with-libraries=/sw/lib
> checking build system type... powerpc-apple-darwin7.6.0
> checking host system type... powerpc-apple-darwin7.6.0
> checking which template to use... darwin
> checking whether to build with 64-bit integer date/time support... no
> checking whether NLS is wanted... no
> checking for default port number... 5432
> checking for gcc... gcc
> checking for C compiler default output... a.out
> checking whether the C compiler works... configure: error: cannot run C
> compiled programs.
> If you meant to cross compile, use `--host'.
> 
> After removing line 2050 to 2077 in configure:
> 
> #############################
> # Check the compiler produces executables we can run.  If not, either
> # the compiler is broken, or we cross compile.
> echo "$as_me:$LINENO: checking whether the C compiler works" >&5
> echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
> # FIXME: These cross compiler hacks should be removed for Autoconf 3.0
> # If not cross compiling, check that we can run a simple program.
> if test "$cross_compiling" != yes; then
>  if { ac_try='./$ac_file'
>  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
>  (eval $ac_try) 2>&5
>  ac_status=$?
>  echo "$as_me:$LINENO: \$? = $ac_status" >&5
>  (exit $ac_status); }; }; then
>    cross_compiling=no
>  else
>    if test "$cross_compiling" = maybe; then
> cross_compiling=yes
>    else
> { { echo "$as_me:$LINENO: error: cannot run C compiled programs.
> If you meant to cross compile, use \`--host'." >&5
> echo "$as_me: error: cannot run C compiled programs.
> If you meant to cross compile, use \`--host'." >&2;}
>   { (exit 1); exit 1; }; }
>    fi
>  fi
> fi
> echo "$as_me:$LINENO: result: yes" >&5
> echo "${ECHO_T}yes" >&6
> #############################
> 
> I was able to configure, at least I got:
> All of PostgreSQL successfully made. Ready to install.
> 
> but then:
> ~/Desktop/postgresql-8.0.0beta5 (user) sudo make install
> make -C doc install
> for file in man1/*.1 man7/*.7 ; do \
>  /bin/sh ../config/install-sh -c -m 644 $file
> /usr/local/share/man//$file || exit; \
> done
> make -C src install
> /bin/sh ../config/mkinstalldirs /usr/local/pgsql/lib/pgxs/src
> mkdir -p -- /usr/local/pgsql/lib/pgxs/src
> /bin/sh ../config/install-sh -c -m 644 Makefile.global
> /usr/local/pgsql/lib/pgxs/src/Makefile.global
> /bin/sh ../config/install-sh -c -m 644 Makefile.port
> /usr/local/pgsql/lib/pgxs/src/Makefile.port
> /bin/sh ../config/install-sh -c -m 644 ./Makefile.shlib
> /usr/local/pgsql/lib/pgxs/src/Makefile.shlib
> /bin/sh ../config/install-sh -c -m 644 ./nls-global.mk
> /usr/local/pgsql/lib/pgxs/src/nls-global.mk
> make -C port install
> /bin/sh ../../config/install-sh -c -m 644  libpgport.a
> /usr/local/pgsql/lib
> make -C timezone install
> make -C ../../src/port all
> make[3]: Nothing to be done for `all'.
> gcc -no-cpp-precomp -O4 -Wall -Wmissing-prototypes -Wpointer-arith
> -Wendif-labels -fno-strict-aliasing zic.o ialloc.o scheck.o localtime.o
> -L../../src/port -L/sw/lib/  -lpgport -lz -lreadline -lresolv -ldl -lm
> -o zic.out
> mkdir -p -- /usr/local/pgsql/share
> ./zic -d /usr/local/pgsql/share/timezone ./data/africa
> ./data/antarctica ./data/asia ./data/australasia ./data/europe
> ./data/northamerica ./data/southamerica ./data/pacificnew
> ./data/etcetera ./data/factory ./data/backward ./data/systemv
> ./data/solar87 ./data/solar88 ./data/solar89
> make[2]: ./zic: Command not found
> make[2]: *** [install] Error 127
> make[1]: *** [install] Error 2
> make: *** [install] Error 2
> 
> 
> 
> I did remove XCode 1.5, installed XCode 1.2, no difference. 8(
> 
> Well If you have an idea, I'd welcome it 8)
> 
> Have a nice day!
> 
> Will
> 
> 
> ---------------------------(end of broadcast)---------------------------
> TIP 9: the planner will ignore your desire to choose an index scan if your
>     joining column's datatypes do not match


-- 
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.



Re: problem installing 8.0.0beta5 on OS X 10.3

From
Tom Lane
Date:
Will Arp <warp@reboot.ch> writes:
> checking whether the C compiler works... configure: error: cannot run C 
> compiled programs.

You need to fix the problem, not rip out the configure test that told
you there was a problem.

It would be useful to look at the portion of config.log that records
this test step.  My best guess is that there's something broken about
your gcc installation, but the exact cause is not knowable from just
the summary output.
        regards, tom lane


Re: problem installing 8.0.0beta5 on OS X 10.3

From
Tom Lane
Date:
Will Arp <warp@reboot.ch> writes:
> please find attached the config.log

configure:2008: checking for C compiler default output
configure:2011: gcc    conftest.c  >&5
configure:2014: $? = 0
configure:2047: result: a.out
configure:2052: checking whether the C compiler works
configure:2058: ./a.out
./configure: line 1: ./a.out: No such file or directory
configure:2061: $? = 127
configure:2069: error: cannot run C compiled programs.
If you meant to cross compile, use `--host'.

Wow, that's an interesting spelling of "a.out" ;-)

Apparently you've got "ls" hacked up in such a way that it puts some
highlighting escape sequences into its output even when it's invoked
by a script.  This is a bad idea, because it will break lots more
stuff than just configure scripts.
        regards, tom lane


Re: problem installing 8.0.0beta5 on OS X 10.3

From
Tom Lane
Date:
Will Arp <warp@reboot.ch> writes:
> removing my custom csh.cshrc file did the trick,
> probably color syntax code I've found here:
> http://www.macosxhints.com/article.php?story=20031027145026892
> Thank you!
> Here is my csh.cshrc file, maybe you can spot the culprit,
> and point me to some doc so I can understand.

This is what burnt you:

>    setenv CLICOLOR_FORCE 1

That's an incredibly dangerous setting; whoever suggested making it
a system-wide default is an idiot.  See "man ls":
    CLICOLOR_FORCE  Color sequences are normally disabled if the output isn't                    directed to a
terminal. This can be overridden by set-                    ting this flag.  The TERM variable still needs to refer-
               ence a color capable terminal however otherwise it is not                    possible to determine which
colorsequences to use.
 
        regards, tom lane