[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-devel
Subject:    [PATCH] MacOSX fixes for admin/
From:       Benjamin Reed <ranger () befunk ! com>
Date:       2003-02-26 5:04:20
[Download RAW message or body]

Here is the first in a coming set of patches for MacOSX over the next 
few weeks (hopefully).  I've got the admin dir cleaned up, next up is arts.

A summary of the changes to acinclude.m4.in:

- use -Xlinker for passing Apple framework stuff through libtool
- change -pedantic-errors to -pedantic in the get* checks (see earlier
   thread "problem with -pedantic-errors in KDE_CHECK_FUNC_EXT")
- add a check for pam headers in /usr/include/pam instead of
   /usr/include/security (Apple has a "Security" framework that conflicts
   with "security" if you are on a case-insensitive filesystem like
   HFS+, so they renamed their PAM dir... grr.)
- add a check for the OSX Java framework -- MacOSX's java stuff is
   strangely laid out, it would probably be possible to make it match up
   with the rest of the java tests, but it really doesn't make much sense
   to do so.
- add the default qt3 doc dir from Fink to the QTDOCDIR search path
- fix a non-macosx-related "kdelibstuff" misspelling in the SSL checks;
   I'm not really sure what that stuff is for but I can't assume it's
   doing what it's supposed to be doing as is

...and in am_edit:

- false is in /usr/bin on darwin -- is there any reason not to assume
   it's in the path?


If there are no objections, could someone with enough karma check these 
changes into admin/?  This patch was generated from HEAD admin dir as of 
an hour or so ago.

The other thing this does not include that is necessary to make KDE apps 
(in general) build on MacOSX is that libtool needs updates.  Previously 
I'd been sitting on my admin patches because you guys (understandably) 
need things to be submitted upstream to libtool CVS before they're 
accepted into the KDE admin directory.  Libtool 1.5 will contain all 
required patches to make KDE happy on MacOSX.  I have tested replacing 
admin/libtool.m4.in and admin/ltmain.sh with their libtool CVS 
counterparts and everything builds perfectly now.  Are there any plans 
to update to libtool 1.5 (upon it's release) for KDE 3.2?  As is, things 
will still not build properly out-of-the-box from the KDE admin dir, 
even with the supplied patch, because of libtool 1.4's various 
incompatibilities with MacOSX.

Anyways, thanks, and hopefully I'll have more patches shortly.  Please 
let me know if you have any objections to these changes, I'll look into 
fixing any problems.  I'm still pretty new to submitting stuff to you 
guys.  =)

["kde-admindir-macosx.patch" (text/plain)]

Index: acinclude.m4.in
===================================================================
RCS file: /home/kde/kde-common/admin/acinclude.m4.in,v
retrieving revision 2.342
diff -u -r2.342 acinclude.m4.in
--- acinclude.m4.in	24 Feb 2003 12:29:46 -0000	2.342
+++ acinclude.m4.in	26 Feb 2003 04:43:16 -0000
@@ -716,7 +716,7 @@
    # CoreAudio framework
    AC_CHECK_HEADER(CoreAudio/CoreAudio.h, [
      AC_DEFINE(HAVE_COREAUDIO, 1, [Define if you have the CoreAudio API])
-     FRAMEWORK_COREAUDIO="-framework CoreAudio"
+     FRAMEWORK_COREAUDIO="-Xlinker -framework -Xlinker CoreAudio"
    ])
 
    AC_CHECK_RES_INIT
@@ -1989,7 +1989,7 @@
 kde_safe_LIBS="$LIBS"
 LIBS="$LIBS $X_EXTRA_LIBS"
 if test "$GXX" = "yes"; then
-CXXFLAGS="$CXXFLAGS -pedantic-errors"
+CXXFLAGS="$CXXFLAGS -pedantic"
 fi
 AC_TRY_COMPILE([
 $2
@@ -3517,13 +3517,23 @@
           AC_CHECK_LIB(pam, pam_start,
             [ AC_CHECK_HEADER(security/pam_appl.h,
                 [ use_pam=yes
-                  pam_service=kde ]) 
+		  pam_header=security/pam_appl.h
+                  pam_service=kde ],
+		[ AC_CHECK_HEADER(pam/pam_appl.h,
+			[ use_pam=yes
+			  pam_header=pam/pam_appl.h
+			  pam_service=kde ])
+		]) 
             ], , $LIBDL)
           ac_cv_path_pam="use_pam=$use_pam pam_service=$pam_service"
         ])
     ])
   eval "$ac_cv_path_pam"
 
+  if test "$pam_header" = "pam/pam_appl.h"; then
+    AC_DEFINE(PAM_HEADER_IN_PAM, 1, [Define if your pam headers are in pam/ instead \
of security/]) +  fi
+
   AC_MSG_CHECKING(for PAM)
   if test "x$use_pam" = xno; then
     AC_MSG_RESULT(no)
@@ -3533,10 +3543,12 @@
     AC_DEFINE(HAVE_PAM, 1, [Defines if you have PAM (Pluggable Authentication \
Modules)])  PAMLIBS="$PAM_MISC_LIB -lpam $LIBDL"
 
+    AC_CHECK_HEADERS([pam/pam_appl.h])
+
     dnl test whether struct pam_message is const (Linux) or not (Sun)
     AC_MSG_CHECKING(for const pam_message)
-    AC_EGREP_HEADER([struct pam_message], security/pam_appl.h,
-      [ AC_EGREP_HEADER([const struct pam_message], security/pam_appl.h,
+    AC_EGREP_HEADER([struct pam_message], $pam_header,
+      [ AC_EGREP_HEADER([const struct pam_message], $pam_header,
                         [AC_MSG_RESULT([const: Linux-type PAM])],
                         [AC_MSG_RESULT([nonconst: Sun-type PAM])
                         AC_DEFINE(PAM_MESSAGE_NONCONST, 1, [Define if your PAM \
support takes non-const arguments (Solaris)])] @@ -4865,7 +4877,18 @@
       AC_DEFINE_UNQUOTED(PATH_JAVA, "$kde_java_bindir/java", [Define where your java \
executable is])  AC_MSG_RESULT([java JRE in $kde_java_bindir])
   fi
-else # no
+elif test -d "/Library/Java/Home"; then
+  kde_java_bindir="/Library/Java/Home/bin"
+  jni_includes="-I/Library/Java/Home/include"
+
+  JAVAC=$kde_java_bindir/javac
+  JAVAH=$kde_java_bindir/javah
+  JAR=$kde_java_bindir/jar
+  JVMLIBS="-Xlinker -framework -Xlinker JavaVM"
+
+  AC_DEFINE_UNQUOTED(PATH_JAVA, "$kde_java_bindir/java", [Define where your java \
executable is]) +  AC_MSG_RESULT([Apple Java Framework])
+else
   AC_MSG_RESULT([none found])
 fi
 
@@ -5020,7 +5043,7 @@
   kde_qtdir="$with_qt_dir"
 fi
 
-AC_FIND_FILE(qsql.html, [ $kde_qtdir/doc/html $QTDIR/doc/html \
/usr/share/doc/packages/qt3/html /usr/lib/qt/doc /usr/lib/qt3/doc \
/usr/lib/qt3/doc/html /usr/doc/qt3/html /usr/doc/qt3 /usr/share/doc/qt3-doc], \
QTDOCDIR) +AC_FIND_FILE(qsql.html, [ $kde_qtdir/doc/html $QTDIR/doc/html \
/usr/share/doc/packages/qt3/html /usr/lib/qt/doc /usr/lib/qt3/doc \
/usr/lib/qt3/doc/html /usr/doc/qt3/html /usr/doc/qt3 /usr/share/doc/qt3-doc \
$prefix/share/doc/qt3/html], QTDOCDIR)  AC_MSG_RESULT($QTDOCDIR)
 
 AC_SUBST(QTDOCDIR)
@@ -5145,7 +5168,7 @@
 AC_ARG_WITH(ssl-dir,
     [  --with-ssl-dir=DIR      where the root of OpenSSL is installed],
     [  ac_ssl_includes="$withval"/include
-       ac_ssl_libraries="$withval"/lib$kdelibsuff
+       ac_ssl_libraries="$withval"/lib$kdelibstuff
     ])
 
 want_ssl=yes
Index: am_edit
===================================================================
RCS file: /home/kde/kde-common/admin/am_edit,v
retrieving revision 1.358
diff -u -r1.358 am_edit
--- am_edit	24 Feb 2003 16:58:27 -0000	1.358
+++ am_edit	26 Feb 2003 04:43:17 -0000
@@ -1042,7 +1042,7 @@
             if ($allidls !~ /$source\_kidl/) {
                 
                 $dep_lines .= "$source.kidl: $sourcedir$source.h \
                \$(DCOP_DEPENDENCIES)\n";
-                $dep_lines .= "\t\$(DCOPIDL) $sourcedir$source.h > $source.kidl || ( \
rm -f $source.kidl ; /bin/false )\n"; +                $dep_lines .= "\t\$(DCOPIDL) \
$sourcedir$source.h > $source.kidl || ( rm -f $source.kidl ; false )\n";  
                 $allidls .= $source . "_kidl ";
             }


>> Visit http://mail.kde.org/mailman/listinfo/kde-devel#unsub to unsubscribe <<

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic