aboutsummaryrefslogtreecommitdiffstats
path: root/macros
diff options
context:
space:
mode:
Diffstat (limited to 'macros')
-rw-r--r--macros/ChangeLog3
-rw-r--r--macros/gnome-objc-checks.m450
2 files changed, 28 insertions, 25 deletions
diff --git a/macros/ChangeLog b/macros/ChangeLog
index eeb926811e..bcfd9ec64f 100644
--- a/macros/ChangeLog
+++ b/macros/ChangeLog
@@ -1,5 +1,8 @@
1998-02-13 Raja R Harinath <harinath@cs.umn.edu>
+ * gnome-objc-checks.m4 (GNOME_INIT_OBJC): Solaris /bin/sh doesn't
+ understand `test -e'.
+
* autogen.sh: New file.
* gnome.m4 (GNOME_INIT): Look for gnomeConf.sh in $libdir, where
diff --git a/macros/gnome-objc-checks.m4 b/macros/gnome-objc-checks.m4
index ac8bdf5ca5..472e46d891 100644
--- a/macros/gnome-objc-checks.m4
+++ b/macros/gnome-objc-checks.m4
@@ -2,20 +2,19 @@ AC_DEFUN([GNOME_CHECK_OBJC],
[
dnl Look for an ObjC compiler.
dnl FIXME: extend list of possible names of ObjC compilers.
- AC_CHECK_PROGS(OBJC, $OBJC gcc, "")
+ AC_CHECK_PROGS(OBJC, $OBJC gcc, "")
+ oLIBS=$LIBS
+ LIBS="$LIBS $PTHREAD_LIB"
+ AC_SUBST(PTHREAD_LIB)
+ AC_CHECK_FUNC(sched_yield,,[
+ AC_CHECK_LIB(posix4,sched_yield,PTHREAD_LIB="$PTHREAD_LIB -lposix4")])
+ LIBS=$oLIBS
- oLIBS=$LIBS
- LIBS="$LIBS $PTHREAD_LIB"
- AC_SUBST(PTHREAD_LIB)
- AC_CHECK_FUNC(sched_yield,,[
- AC_CHECK_LIB(posix4,sched_yield,PTHREAD_LIB="$PTHREAD_LIB -lposix4")])
- LIBS=$oLIBS
-
- AC_CACHE_CHECK([if Objective C compiler ($OBJC) works],
- ac_cv_prog_objc_works, [
- if test -n "$OBJC"; then
- cat > conftest.m <<EOF
+ AC_CACHE_CHECK([if Objective C compiler ($OBJC) works],
+ ac_cv_prog_objc_works, [
+ if test -n "$OBJC"; then
+ cat > conftest.m <<EOF
#include <objc/Object.h>
@interface myRandomObj : Object
{
@@ -32,28 +31,29 @@ int main () {
}
EOF
- $OBJC -o conftest $LDFLAGS conftest.m -lobjc $PTHREAD_LIB 1>&AC_FD_CC 2>&1
- result=$?
- rm -f conftest*
+ $OBJC -o conftest $LDFLAGS conftest.m -lobjc $PTHREAD_LIB 1>&AC_FD_CC 2>&1
+ result=$?
+ rm -f conftest*
- if test $result -eq 0; then
- ac_cv_prog_objc_works=yes
- fi
- else
- ac_cv_prog_objc_works=no
- fi
- ])
+ if test $result -eq 0; then
+ ac_cv_prog_objc_works=yes
+ fi
+ else
+ ac_cv_prog_objc_works=no
+ fi
+ ])
- AM_CONDITIONAL(OBJECTIVE_C, test x$ac_cv_prog_objc_works = xyes)
+ AM_CONDITIONAL(OBJECTIVE_C, test x$ac_cv_prog_objc_works = xyes)
])
AC_DEFUN([GNOME_INIT_OBJC],
[
- AC_MSG_CHECKING(Loading obGnomeConf.sh values)
- if test -e $gnome_prefix/obGnomeConf.sh; then
+ AC_MSG_CHECKING(for obGnomeConf.sh file in $gnome_prefix)
+ if test -f $gnome_prefix/obGnomeConf.sh; then
. $gnome_prefix/obGnomeConf.sh
AC_MSG_RESULT(found)
else
+ AC_MSG_RESULT(not found)
AC_MSG_ERROR(Could not find the obGnomeConf.sh file that is generated by gnome-objc install)
fi
AC_SUBST(OBGNOME_LIBS)