]> git.michaelhowe.org Git - packages/o/openafs.git/commitdiff
Unix: Fix objdir builds
authorSimon Wilkinson <sxw@your-file-system.com>
Wed, 17 Feb 2010 13:46:23 +0000 (13:46 +0000)
committerDerrick Brashear <shadow@dementia.org>
Thu, 18 Feb 2010 03:58:47 +0000 (19:58 -0800)
Make some changes to the Unix build system so that object directory
builds work again. In particular, change the way that we call
xcodebuild on Darwin, so that source and binary can live in different
places.

Change-Id: Ib2ab6182deaf7f344603cb5618707d3f212a5b86
Reviewed-on: http://gerrit.openafs.org/1339
Reviewed-by: Derrick Brashear <shadow@dementia.org>
Tested-by: Derrick Brashear <shadow@dementia.org>
src/platform/DARWIN/Makefile.in
src/rxkad/crc.c
src/rxkad/md4.c
src/rxkad/md5.c
src/shlibafsrpc/Makefile.in

index a472af6bc3d5d96cae6b566d3440ac3ba17d6299..96fe1bd7f7ba63ae0f71bf0dc768839b55472e2a 100644 (file)
@@ -23,20 +23,20 @@ afscell/InstallerSections.plist: afscell
 OpenAFS.prefPane:
        @case ${SYS_NAME} in \
        *_darwin_100 ) \
-               xcodebuild -sdk macosx10.6 -project AFSPreference/OpenAFS.xcodeproj ;; \
+               xcodebuild -sdk macosx10.6 -project ${srcdir}/AFSPreference/OpenAFS.xcodeproj SYMDIR=`pwd`/AFSPreference/build;; \
        *_darwin_90 ) \
-               xcodebuild -sdk macosx10.5 -project AFSPreference/OpenAFS.xcodeproj ;; \
+               xcodebuild -sdk macosx10.5 -project ${srcdir}/AFSPreference/OpenAFS.xcodeproj SYMDIR=`pwd`/AFSPreference/build;; \
        *_darwin_80 ) \
-               xcodebuild -sdk macosx10.4 -project AFSPreference/OpenAFS.xcodeproj ;; \
+               xcodebuild -sdk macosx10.4 -project ${srcdor}/AFSPreference/OpenAFS.xcodeproj SYMDIR=`pwd`/AFSPreference/build;; \
        * ) \
                echo Not building AFS prefPane for ${SYS_NAME} ;; \
        esac
 
 afscell:
-       cd afscell && xcodebuild
+       xcodebuild -project ${srcdir}/afscell/afscell.xcodeproj SYMROOT=`pwd`/afscell/build
 
 afssettings: afssettings.m 
-       ${CC} ${CFLAGS} -o afssettings afssettings.m -framework Foundation
+       ${CC} ${CFLAGS} -o afssettings $? -framework Foundation
 
 install: \
        ${DESTDIR}${sbindir}/afssettings
@@ -69,5 +69,5 @@ ${DEST}/tools/OpenAFS.prefPane: AFSPreference/build/Release/OpenAFS.prefPane
 clean:
        $(RM) -rf OpenAFS.prefPane
        $(RM) -rf AFSPreference/build
+       $(RM) -rf afscell/build
        $(RM) -f *.o core afssettings AFS_component_version_number.c
-       @cd afscell && xcodebuild clean
index de9cf4dd2f34c33b04a45301b1c0d1506b96f7ab..e9f5d78fe4b3920096622446a5c16d334ce06665 100644 (file)
@@ -61,9 +61,9 @@
 #include <string.h>
 #include <rx/xdr.h>
 #include <rx/rx.h>
+#include <rx/rxkad.h>
 #include <des.h>
 #include "lifetimes.h"
-#include "rxkad.h"
 #endif /* defined(UKERNEL) */
 
 static u_long table[256];
index 890426dd42213987c3a6388504efe40e22d60495..1738b90470512c466be810ae5056177250e5b3a2 100644 (file)
@@ -58,9 +58,9 @@
 #include <string.h>
 #include <rx/xdr.h>
 #include <rx/rx.h>
+#include <rx/rxkad.h>
 #include <des.h>
 #include "lifetimes.h"
-#include "rxkad.h"
 #endif /* defined(UKERNEL) */
 
 
index d699c1932a41458720a19122f251ce36a3d5b7de..0910063c5ae18ba3b2108cf76befd9f68ef16cfc 100644 (file)
@@ -57,9 +57,9 @@
 #endif
 #include <string.h>
 #include <rx/rx.h>
+#include <rx/rxkad.h>
 #include <des.h>
 #include "lifetimes.h"
-#include "rxkad.h"
 #endif /* defined(UKERNEL) */
 
 
index f396403592087c434b50d5e799bbc3fb5242e2c6..b5d37161e24a7a4fe9f116199725467f7a195f2f 100644 (file)
@@ -27,7 +27,7 @@ SFLAGS=-P -I${TOP_INCDIR}
 
 RX = ../rx
 CCRULE = ${CC} ${CFLAGS} -c $?
-RXKAD = ../rxkad
+RXKAD = $(srcdir)/../rxkad
 RXSTAT = ../rxstat
 FSINT = ../fsint
 DES = ../des
@@ -209,16 +209,16 @@ rx_multi.o: ${RX}/rx_multi.c
        ${CCRULE}
 
 rxkad_client.o: ${RXKAD}/rxkad_client.c
-       ${CCRULE}
+       ${CCRULE} -I../rxkad
 
 rxkad_server.o: ${RXKAD}/rxkad_server.c
-       ${CCRULE}
+       ${CCRULE} -I../rxkad
 
 rxkad_common.o: ${RXKAD}/rxkad_common.c
-       ${CCRULE}
+       ${CCRULE} -I../rxkad
 
 ticket.o: ${RXKAD}/ticket.c
-       ${CCRULE}
+       ${CCRULE} -I ../rxkad
 
 ticket5.o: ${RXKAD}/ticket5.c
        ${CCRULE} -I../rxkad -I${RXKAD}
@@ -236,7 +236,7 @@ fcrypt.o: ${RXKAD}/domestic/fcrypt.c
        ${CCRULE} -I../rxkad -I${RXKAD}
 
 crypt_conn.o: ${RXKAD}/domestic/crypt_conn.c
-       ${CCRULE}
+       ${CCRULE} -I../rxkad -I${RXKAD}
 
 AFS_component_version_number.o: ${RX}/AFS_component_version_number.c
        ${CCRULE}
@@ -311,10 +311,10 @@ des.o: ${DES}/des.c
        case ${SYS_NAME} in \
        hp_ux11*) \
                set X `echo ${CCRULE} | sed s/-g//`; shift; \
-               "$$@" \
+               "-I../des $$@" \
                ;; \
        *) \
-               ${CCRULE} \
+               ${CCRULE} -I../des \
                ;; \
        esac
 
@@ -334,7 +334,7 @@ new_rnd_key.o: ${DES}/new_rnd_key.c
        ${CCRULE}
 
 key_sched.o: ${DES}/key_sched.c
-       ${CCRULE}
+       ${CCRULE} -I../des
 
 debug_decl.o: ${DES}/debug_decl.c
        ${CCRULE}
@@ -343,7 +343,7 @@ quad_cksum.o: ${DES}/quad_cksum.c
        ${CCRULE}
 
 key_parity.o: ${DES}/key_parity.c
-       ${CCRULE}
+       ${CCRULE} -I../des
 
 weak_key.o: ${DES}/weak_key.c
        ${CCRULE}
@@ -430,7 +430,7 @@ afscbint.xdr.o: ${FSINT}/afscbint.xdr.c
        ${CCRULE}
 
 afsaux.o: ${FSINT}/afsaux.c
-       ${CCRULE}
+       ${CCRULE} -I../fsint
 
 clean:
        $(RM) -f *.o libafsrpc.a* libafsrpc.sl* libafsrpc.so* libafsrpc_pic.a libafsrpc.dylib.*