Discussion:
./configure generated script fails on solaris
Christian Jullien
2018-10-21 09:36:28 UTC
Permalink
Hello maintainers,



Thank you for your efforts to maintains and improve bcurses.

I have an old solaris 10 sparc box where I port many GNU packages.

Trying to compile 6.1 version, if fails on line 1206 probably because a gnu
bash extension. #!/bin/sh is NOT bash on solaris



Trying bash ./configure is little bit better but still fails with:



./config.status: syntax error at line 1178: `(' unexpected



I finally changed the shebang to my local copy of bash but is still failed
call config.status. I patched this file too and ran ./config.status and it
worked this time.



make install fails for the same reason because it uses /bin/sh



This strange! I use many ./configure script and this is the first time I
have to patch those two generated files.



Am I missing something?



C.
vcoxvco
2018-10-21 11:55:05 UTC
Permalink
Post by Christian Jullien
Hello maintainers,
Thank you for your efforts to maintains and improve bcurses.
I have an old solaris 10 sparc box where I port many GNU packages.
Trying to compile 6.1 version, if fails on line 1206 probably because a gnu bash extension.
#!/bin/sh is NOT bash on solaris
That's right - and /bin/sh is not a POSIX-shell (it's in /usr/xpg4/ on older Solaris)
Post by Christian Jullien
./config.status: syntax error at line 1178: `(' unexpected
I finally changed the shebang to my local copy of bash but is still failed call config.status.
I patched this file too and ran ./config.status and it worked this time.
make install fails for the same reason because it uses /bin/sh
This strange! I use many ./configure script and this is the first time I have to patch those
two generated files.
Am I missing something?
You have to change 2 files as follows:

--- configure.orig 2018-09-01 21:37:24.000000000 +0200
+++ configure 2018-10-21 13:51:48.572124164 +0200
@@ -1,4 +1,4 @@
-#! /bin/sh
+#! /bin/ksh
# From configure.in Revision: 1.665 .
# Guess values for system-dependent variables and create Makefiles.
# Generated by Autoconf 2.52.20180819.
@@ -98,7 +98,7 @@
cross_compiling=no
subdirs=
MFLAGS= MAKEFLAGS=
-SHELL=${CONFIG_SHELL-/bin/sh}
+SHELL=${CONFIG_SHELL-/bin/ksh}


--- aclocal.m4.orig 2018-08-18 22:21:21.000000000 +0200
+++ aclocal.m4 2018-10-21 13:51:38.636242999 +0200
@@ -7567,7 +7567,7 @@
dnl But that still does not work properly since the macro is expanded outside
dnl the CF_WITH_LIBTOOL macro:
dnl
-dnl #!/bin/sh
+dnl #!/bin/ksh
dnl ACLOCAL=`aclocal --print-ac-dir`
dnl if test -z "$ACLOCAL" ; then
dnl echo cannot find aclocal directory


This works for me on Solaris.
(I have no idea how to change this in a generic way for all platforms, though)

Regards
Vassili
--
V. Courzakis
email: ***@googlemail.com
Thomas Dickey
2018-10-21 15:40:32 UTC
Permalink
Post by Christian Jullien
Hello maintainers,
Thank you for your efforts to maintains and improve bcurses.
I have an old solaris 10 sparc box where I port many GNU packages.
I do test-compiles on a Solaris 10 x86 machine.
(I've Solaris 11 machines, but it looks like 10 was the high point for Sun).
Post by Christian Jullien
Trying to compile 6.1 version, if fails on line 1206 probably because a gnu
It's in the release notes for 6.0 (August 2015) here:

https://invisible-island.net/ncurses/announce-6.0.html#h3-config-config

with an example after this comment:

This mainly affects Solaris (the other vendor unix systems have
followed the POSIX guidelines for the past twenty years).
Post by Christian Jullien
bash extension. #!/bin/sh is NOT bash on solaris
none of my configure scripts depend on bash features.
--
Thomas E. Dickey <***@invisible-island.net>
https://invisible-island.net
ftp://ftp.invisible-island.net
Christian Jullien
2018-10-21 17:22:50 UTC
Permalink
Many thanks Thomas for your quick reply.
Your script, I missed (sorry), works ROOTB on my solaris box.

May I suggest you to detect this case in configure and propose user to
execute this script?

Have a nice day.

C.

-----Original Message-----
From: Thomas Dickey [mailto:***@his.com]
Sent: dimanche 21 octobre 2018 17:41
To: Christian Jullien
Cc: bug-***@gnu.org
Subject: Re: ./configure generated script fails on solaris
Post by Christian Jullien
Hello maintainers,
Thank you for your efforts to maintains and improve bcurses.
I have an old solaris 10 sparc box where I port many GNU packages.
I do test-compiles on a Solaris 10 x86 machine.
(I've Solaris 11 machines, but it looks like 10 was the high point for Sun).
Post by Christian Jullien
Trying to compile 6.1 version, if fails on line 1206 probably because a gnu
It's in the release notes for 6.0 (August 2015) here:

https://invisible-island.net/ncurses/announce-6.0.html#h3-config-config

with an example after this comment:

This mainly affects Solaris (the other vendor unix systems have
followed the POSIX guidelines for the past twenty years).
Post by Christian Jullien
bash extension. #!/bin/sh is NOT bash on solaris
none of my configure scripts depend on bash features.

--
Thomas E. Dickey <***@invisible-island.net> https://invisible-island.net
ftp://ftp.invisible-island.net

Loading...