Re: gnome-utils on HPUX - compile issues
- From: Bert Driehuis <bert_driehuis nl compuware com>
- To: Dan Newcombe <Newcombe mordor clayton edu>
- cc: gnome-list gnome org
- Subject: Re: gnome-utils on HPUX - compile issues
- Date: Sun, 3 Jan 1999 04:47:48 +0100 (MET)
On Thu, 31 Dec 1998, Dan Newcombe wrote:
> On hpux 10.20, two parts of gnome-utils had issues: ghex and gdialog
>
> On gdialog, _ACS_COMPAT_CODE needs to be defined before including
> curses.h, otherwise it can't find a bunch of stuff in linking.
>
> On ghex, it includes getopt. On HPUX, there is not getopt.h, however, the
> code compiled just fine by removing the include getopt.h in ghex/main.c
> and ghex/gnome-support.h
I didn't touch the gdialog thing, but the attached diff will get ghex
going on BSD/OS whilst probably fixing HP-UX as well. It adds autoconf
detection of getopt.h's existance.
Cheers,
-- Bert
Bert Driehuis, MIS -- bert_driehuis@nl.compuware.com -- +31-20-3116119
The grand leap of the whale up the Fall of Niagara is esteemed, by all
who have seen it, as one of the finest spectacles in nature.
-- Benjamin Franklin.
diff -rc2 ref/gnome-utils-0.99.0/config.h.in gnome-utils-0.99.0/config.h.in
*** ref/gnome-utils-0.99.0/config.h.in Thu Dec 10 05:45:15 1998
--- gnome-utils-0.99.0/config.h.in Sun Jan 3 03:57:35 1999
***************
*** 71,74 ****
--- 71,75 ----
#undef YYTEXT_POINTER
+ #undef HAVE_GETOPT_H
#undef HAVE_LC_MESSAGES
#undef HAVE_STPCPY
diff -rc2 ref/gnome-utils-0.99.0/configure gnome-utils-0.99.0/configure
*** ref/gnome-utils-0.99.0/configure Wed Dec 16 22:58:35 1998
--- gnome-utils-0.99.0/configure Sun Jan 3 03:49:31 1999
***************
*** 5995,6006 ****
echo $ac_n "checking for u_int64_t""... $ac_c" 1>&6
! echo "configure:6000: checking for u_int64_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_u_int64_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
! #line 6005 "configure"
#include "confdefs.h"
#include <sys/types.h>
--- 5995,6052 ----
+ for ac_hdr in getopt.h
+ do
+ ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
+ echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
+ echo "configure:6002: checking for $ac_hdr" >&5
+ if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+ else
+ cat > conftest.$ac_ext <<EOF
+ #line 6007 "configure"
+ #include "confdefs.h"
+ #include <$ac_hdr>
+ EOF
+ ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
+ { (eval echo configure:6012: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+ ac_err=`grep -v '^ *+' conftest.out`
+ if test -z "$ac_err"; then
+ rm -rf conftest*
+ eval "ac_cv_header_$ac_safe=yes"
+ else
+ echo "$ac_err" >&5
+ echo "configure: failed program was:" >&5
+ cat conftest.$ac_ext >&5
+ rm -rf conftest*
+ eval "ac_cv_header_$ac_safe=no"
+ fi
+ rm -f conftest*
+ fi
+ if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
+ echo "$ac_t""yes" 1>&6
+ ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
+ cat >> confdefs.h <<EOF
+ #define $ac_tr_hdr 1
+ EOF
+
+ cat >> confdefs.h <<\EOF
+ #define HAVE_GETOPT_H 1
+ EOF
+
+
+ else
+ echo "$ac_t""no" 1>&6
+ fi
+ done
+
+
echo $ac_n "checking for u_int64_t""... $ac_c" 1>&6
! echo "configure:6046: checking for u_int64_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_u_int64_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
! #line 6051 "configure"
#include "confdefs.h"
#include <sys/types.h>
***************
*** 6030,6039 ****
echo $ac_n "checking for int64_t""... $ac_c" 1>&6
! echo "configure:6033: checking for int64_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_int64_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
! #line 6038 "configure"
#include "confdefs.h"
#include <sys/types.h>
--- 6076,6085 ----
echo $ac_n "checking for int64_t""... $ac_c" 1>&6
! echo "configure:6079: checking for int64_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_int64_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
! #line 6084 "configure"
#include "confdefs.h"
#include <sys/types.h>
***************
*** 6122,6126 ****
set dummy libgtop-config; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
! echo "configure:6125: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_LIBGTOP_CONFIG'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
--- 6168,6172 ----
set dummy libgtop-config; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
! echo "configure:6171: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_LIBGTOP_CONFIG'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
***************
*** 6183,6187 ****
min_libgtop_version="$min_libgtop_major.$min_libgtop_minor.$min_libgtop_micro"
echo $ac_n "checking for libgtop - version >= $min_libgtop_version""... $ac_c" 1>&6
! echo "configure:6186: checking for libgtop - version >= $min_libgtop_version" >&5
no_libgtop=""
if test "$LIBGTOP_CONFIG" = "no" ; then
--- 6229,6233 ----
min_libgtop_version="$min_libgtop_major.$min_libgtop_minor.$min_libgtop_micro"
echo $ac_n "checking for libgtop - version >= $min_libgtop_version""... $ac_c" 1>&6
! echo "configure:6232: checking for libgtop - version >= $min_libgtop_version" >&5
no_libgtop=""
if test "$LIBGTOP_CONFIG" = "no" ; then
***************
*** 6397,6401 ****
echo "checking "location of ncurses.h file"" 1>&6
! echo "configure:6400: checking "location of ncurses.h file"" >&5
--- 6443,6447 ----
echo "checking "location of ncurses.h file"" 1>&6
! echo "configure:6446: checking "location of ncurses.h file"" >&5
***************
*** 6537,6541 ****
then
cat > conftest.$ac_ext <<EOF
! #line 6540 "configure"
#include "confdefs.h"
#include </usr/include/curses.h>
--- 6583,6587 ----
then
cat > conftest.$ac_ext <<EOF
! #line 6586 "configure"
#include "confdefs.h"
#include </usr/include/curses.h>
***************
*** 6563,6567 ****
cat > conftest.$ac_ext <<EOF
! #line 6566 "configure"
#include "confdefs.h"
--- 6609,6613 ----
cat > conftest.$ac_ext <<EOF
! #line 6612 "configure"
#include "confdefs.h"
***************
*** 6628,6635 ****
# check for ncurses version, to properly ifdef mouse-fix
echo $ac_n "checking for ncurses version""... $ac_c" 1>&6
! echo "configure:6631: checking for ncurses version" >&5
ncurses_version=unknown
cat > conftest.$ac_ext <<EOF
! #line 6634 "configure"
#include "confdefs.h"
#ifdef RENAMED_NCURSES
--- 6674,6681 ----
# check for ncurses version, to properly ifdef mouse-fix
echo $ac_n "checking for ncurses version""... $ac_c" 1>&6
! echo "configure:6677: checking for ncurses version" >&5
ncurses_version=unknown
cat > conftest.$ac_ext <<EOF
! #line 6680 "configure"
#include "confdefs.h"
#ifdef RENAMED_NCURSES
diff -rc2 ref/gnome-utils-0.99.0/configure.in gnome-utils-0.99.0/configure.in
*** ref/gnome-utils-0.99.0/configure.in Tue Dec 15 20:42:31 1998
--- gnome-utils-0.99.0/configure.in Sun Jan 3 03:49:20 1999
***************
*** 84,87 ****
--- 84,91 ----
dnl gsu end.
+ AC_CHECK_HEADERS(getopt.h, [
+ AC_DEFINE(HAVE_GETOPT_H)
+ ])
+
dnl Check for libgtop
GNOME_INIT_LIBGTOP
diff -rc2 ref/gnome-utils-0.99.0/ghex/gnome-support.h gnome-utils-0.99.0/ghex/gnome-support.h
*** ref/gnome-utils-0.99.0/ghex/gnome-support.h Mon Nov 2 21:42:06 1998
--- gnome-utils-0.99.0/ghex/gnome-support.h Sun Jan 3 04:03:31 1999
***************
*** 26,30 ****
--- 26,32 ----
#include <gnome.h>
+ #ifdef HAVE_GETOPT_H
#include <getopt.h>
+ #endif
extern int restarted;
diff -rc2 ref/gnome-utils-0.99.0/ghex/main.c gnome-utils-0.99.0/ghex/main.c
*** ref/gnome-utils-0.99.0/ghex/main.c Mon Dec 14 02:58:48 1998
--- gnome-utils-0.99.0/ghex/main.c Sun Jan 3 04:03:41 1999
***************
*** 24,28 ****
--- 24,30 ----
#include <config.h>
#include <gnome.h>
+ #ifdef HAVE_GETOPT_H
#include <getopt.h>
+ #endif
#include "gnome-support.h"
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]