all: force ${SYS_NAME}/dest
$(MAKE) install
-${SYS_NAME}/dest:
- mkdir -p ${SYS_NAME}/dest
-
all_nolibafs: ${SYS_NAME}/dest
$(MAKE) install TARGET=finale_nolibafs
only_libafs: ${SYS_NAME}/dest
$(MAKE) install TARGET=libafs
+only_libafs_tree: ${SYS_NAME}/dest
+ $(MAKE) install TARGET=libafs_tree
+
+${SYS_NAME}/dest:
+ mkdir -p ${SYS_NAME}/dest
+
project: cmd comerr
config:
libafs: libafs_setup ${KERNELDIR}
${COMPILE_PART1} libafs ${COMPILE_PART2}
+libafs_tree: libafs_setup ${KERNELDIR}
+ -/bin/rm -rf libafs_tree
+ for d in afs afsint rx config; do \
+ [ -d libafs_tree/$$d ] || mkdir -p libafs_tree/$$d; \
+ done
+ for f in `cd src/libafs; find . -name '*.[ch]'` \
+ Makefile.common Makefile.extradefs \
+ afs.shutdown afs.startup redhat.sh sgi_master sgi_system \
+ ; do \
+ ${INSTALL} -c -f src/libafs/$$f libafs_tree/$$f; \
+ done
+ src/config/config src/libafs/MakefileProto.${MKAFS_OSTYPE}.in libafs_tree/Makefile.in ${SYS_NAME}
+ ${INSTALL} -c src/config/Makefile.${SYS_NAME}.in libafs_tree/config
+ ${INSTALL} -c src/config/afsconfig.h.in libafs_tree/config
+ ${INSTALL} -c -f -ns configure-libafs libafs_tree/configure
+
libuafs: libuafs_setup ${UKERNELDIR}
set -x; \
case ${SYS_NAME} in \
-${COMPILE_PART1} rcp ${COMPILE_CLEAN}
-${COMPILE_PART1} libafs ${COMPILE_CLEAN}
-${COMPILE_PART1} libuafs ${COMPILE_CLEAN}
+ -(cd src/libafs; /bin/rm -rf afs afsint config rx)
+ -(cd src/libuafs; /bin/rm -rf afs afsint config rx des)
+ -/bin/rm -rf libafs_tree ${SYS_NAME}
distclean: clean
src/xstat/Makefile
pristine: distclean
- /bin/rm -f src/config/afsconfig.h.in configure aclocal.m4
+ /bin/rm -f src/config/afsconfig.h.in configure configure-libafs aclocal.m4
#
# Below targets are all deprecated, insecure, or obsolte,
--- /dev/null
+AC_INIT(Makefile.common)
+AM_INIT_AUTOMAKE(openafs-libafs,devel)
+AC_CANONICAL_HOST
+AC_CONFIG_HEADER(config/afsconfig.h)
+
+#BOZO_SAVE_CORES BOS_RESTRICTED_MODE BOS_NEW_CONFIG pam sia
+AC_ARG_WITH(afs-sysname,
+[ --with-afs-sysname=sys use sys for the afs sysname]
+)
+AC_ARG_ENABLE( obsolete,
+[ --enable-obsolete enable obsolete portions of AFS (mpp, ntp and package)],, enable_obsolete="no")
+AC_ARG_ENABLE( insecure,
+[ --enable-insecure enable insecure portions of AFS (ftpd, inetd, rcp, rlogind and rsh)],, enable_insecure="no")
+AC_ARG_ENABLE( afsdb,
+[ --disable-afsdb disable AFSDB RR support],, enable_afsdb="yes")
+AC_ARG_ENABLE( bos-restricted-mode,
+[ --enable-bos-restricted-mode enable bosserver restricted mode which disables certain bosserver functionality],, enable_bos_restricted_mode="no")
+AC_ARG_ENABLE( namei-fileserver,
+[ --enable-namei-fileserver force compilation of namei fileserver in preference to inode fileserver],, enable_namei_fileserver="no")
+AC_ARG_ENABLE( fast-restart,
+[ --enable-fast-restart enable fast startup of file server without salvaging],, enable_fast_restart="no")
+AC_ARG_ENABLE( bitmap-later,
+[ --enable-bitmap-later enable fast startup of file server by not reading bitmap till needed],, enable_bitmap_later="no")
+AC_ARG_ENABLE( full-vos-listvol-switch,
+[ --enable-full-vos-listvol-switch enable vos full listvol switch for formatted output],, enable_full_vos_listvol_switch="no")
+AC_ARG_WITH(dux-kernel-headers,
+[ --with-dux-kernel-headers=path use the kernel headers found at path(optional, defaults to first match in /usr/sys)]
+)
+AC_ARG_WITH(linux-kernel-headers,
+[ --with-linux-kernel-headers=path use the kernel headers found at path(optional, defaults to /usr/src/linux)]
+)
+AC_ARG_ENABLE(kernel-module,
+[ --disable-kernel-module disable compilation of the kernel module (defaults to enabled)],, enable_kernel_module="yes"
+)
+AC_ARG_ENABLE(redhat-buildsys,
+[ --enable-redhat-buildsys enable compilation of the redhat build system kernel (defaults to disabled)],, enable_redhat_buildsys="no"
+)
+
+AC_PROG_CC
+
+dnl weird ass systems
+AC_AIX
+AC_ISC_POSIX
+AC_MINIX
+
+dnl Various compiler setup.
+AC_C_INLINE
+AC_C_CONST
+AC_TYPE_PID_T
+AC_TYPE_SIZE_T
+AC_TYPE_SIGNAL
+
+dnl Checks for programs.
+AC_PROG_INSTALL
+AC_PROG_LN_S
+AC_PROG_RANLIB
+AC_PROG_YACC
+AM_PROG_LEX
+
+OPENAFS_CHECK_BIGENDIAN
+
+AC_MSG_CHECKING(your OS)
+system=$host
+case $system in
+ *-linux*)
+ MKAFS_OSTYPE=LINUX
+ if test "x$enable_redhat_buildsys" = "xyes"; then
+ AC_DEFINE(ENABLE_REDHAT_BUILDSYS)
+ fi
+ if test "x$enable_kernel_module" = "xyes"; then
+ if test "x$with_linux_kernel_headers" != "x"; then
+ LINUX_KERNEL_PATH="$with_linux_kernel_headers"
+ else
+ LINUX_KERNEL_PATH="/usr/src/linux"
+ fi
+ if test -f "$LINUX_KERNEL_PATH/include/linux/version.h"; then
+ linux_kvers=`fgrep UTS_RELEASE $LINUX_KERNEL_PATH/include/linux/version.h |awk 'BEGIN { FS="\"" } { print $2 }'|tail -1`
+ if test "x$linux_kvers" = "x"; then
+ if test -f "$LINUX_KERNEL_PATH/include/linux/version-up.h"; then
+ linux_kvers=`fgrep UTS_RELEASE $LINUX_KERNEL_PATH/include/linux/version-up.h |awk 'BEGIN { FS="\"" } { print $2 }'|tail -1`
+ if test "x$linux_kvers" = "x"; then
+
+ AC_MSG_ERROR(Linux headers lack version definition [2])
+ exit 1
+ else
+ LINUX_VERSION="$linux_kvers"
+ fi
+ else
+ AC_MSG_ERROR(Linux headers lack version definition)
+ exit 1
+ fi
+ else
+ LINUX_VERSION="$linux_kvers"
+ fi
+ else
+ enable_kernel_module="no"
+ fi
+ if test ! -f "$LINUX_KERNEL_PATH/include/linux/autoconf.h"; then
+ enable_kernel_module="no"
+ fi
+ if test "x$enable_kernel_module" = "xno"; then
+ if test "x$with_linux_kernel_headers" != "x"; then
+ AC_MSG_ERROR(No usable linux headers found at $LINUX_KERNEL_PATH)
+ exit 1
+ else
+ AC_MSG_WARN(No usable linux headers found at $LINUX_KERNEL_PATH so disabling kernel module)
+ fi
+ fi
+ fi
+ AC_MSG_RESULT(linux)
+ if test "x$enable_kernel_module" = "xyes"; then
+ LINUX_FS_STRUCT_INODE_HAS_I_BYTES
+ LINUX_FS_STRUCT_ADDRESS_SPACE_HAS_PAGE_LOCK
+ LINUX_FS_STRUCT_INODE_HAS_I_CDEV
+ LINUX_FS_STRUCT_INODE_HAS_I_TRUNCATE_SEM
+ LINUX_FS_STRUCT_INODE_HAS_I_DIRTY_DATA_BUFFERS
+ LINUX_FS_STRUCT_INODE_HAS_I_MAPPING_OVERLOAD
+ LINUX_INODE_SETATTR_RETURN_TYPE
+ LINUX_NEED_RHCONFIG
+ LINUX_WHICH_MODULES
+ if test "x$ac_cv_linux_func_inode_setattr_returns_int" = "xyes" ; then
+ AC_DEFINE(INODE_SETATTR_NOT_VOID)
+ fi
+ if test "x$ac_cv_linux_fs_struct_inode_has_i_dirty_data_buffers" = "xyes"; then
+ AC_DEFINE(STRUCT_INODE_HAS_I_DIRTY_DATA_BUFFERS)
+ fi
+ if test "x$ac_cv_linux_fs_struct_inode_has_i_mapping_overload" = "xyes"; then
+ AC_DEFINE(STRUCT_INODE_HAS_I_MAPPING_OVERLOAD)
+ fi
+ if test "x$ac_cv_linux_fs_struct_inode_has_i_cdev" = "xyes"; then
+ AC_DEFINE(STRUCT_INODE_HAS_I_CDEV)
+ fi
+ if test "x$ac_cv_linux_fs_struct_inode_has_i_truncate_sem" = "xyes"; then
+ AC_DEFINE(STRUCT_INODE_HAS_I_TRUNCATE_SEM)
+ fi
+ if test "x$ac_cv_linux_fs_struct_inode_has_i_bytes" = "xyes"; then
+ AC_DEFINE(STRUCT_INODE_HAS_I_BYTES)
+ fi
+ if test "x$ac_cv_linux_fs_struct_address_space_has_page_lock" = "xyes"; then
+ AC_DEFINE(STRUCT_ADDRESS_SPACE_HAS_PAGE_LOCK)
+ fi
+ :
+ fi
+ ;;
+ *-solaris*)
+ MKAFS_OSTYPE=SOLARIS
+ AC_MSG_RESULT(sun4)
+ SOLARIS_UFSVFS_HAS_DQRWLOCK
+ ;;
+ *-hpux*)
+ MKAFS_OSTYPE=HPUX
+ AC_MSG_RESULT(hp_ux)
+ ;;
+ *-irix*)
+ MKAFS_OSTYPE=IRIX
+ AC_MSG_RESULT(sgi)
+ ;;
+ *-aix*)
+ MKAFS_OSTYPE=AIX
+ AC_MSG_RESULT(rs_aix)
+ ;;
+ *-osf*)
+ MKAFS_OSTYPE=DUX
+ AC_MSG_RESULT(alpha_dux)
+ if test "x$enable_kernel_module" = "xyes"; then
+ if test "x$with_dux_kernel_headers" != "x"; then
+ HEADER_RT=`ls ${with_dux_kernel_headers}/rt_preempt.h | head -1 | sed 's,/rt_preempt.h,,;s,/usr/sys/,,'`
+ else
+ HEADER_RT=`ls /usr/sys/*/rt_preempt.h | head -1 | sed 's,/rt_preempt.h,,;s,/usr/sys/,,'`
+ fi
+ fi
+ if test "$HEADER_RT" = "*" ; then
+ AC_MSG_ERROR([Need a configured kernel directory])
+ fi
+ AC_SUBST([HEADER_RT])
+ ;;
+ *-darwin*)
+ MKAFS_OSTYPE=DARWIN
+ AC_MSG_RESULT(ppc_darwin)
+ ;;
+ *-freebsd*)
+ MKAFS_OSTYPE=FBSD
+ AC_MSG_RESULT(i386_fbsd)
+ ;;
+ *)
+ AC_MSG_RESULT($system)
+ ;;
+esac
+
+if test "x$with_afs_sysname" != "x"; then
+ AFS_SYSNAME="$with_afs_sysname"
+else
+ AC_MSG_CHECKING(your AFS sysname)
+ case $host in
+ i?86-*-freebsd4.2*)
+ AFS_SYSNAME="i386_fbsd_42"
+ ;;
+ hppa*-hp-hpux11*)
+ AFS_SYSNAME="hp_ux110"
+ ;;
+ hppa*-hp-hpux10*)
+ AFS_SYSNAME="hp_ux102"
+ ;;
+ powerpc-apple-darwin1.2*)
+ AFS_SYSNAME="ppc_darwin_12"
+ ;;
+ powerpc-apple-darwin1.3*)
+ AFS_SYSNAME="ppc_darwin_13"
+ ;;
+ sparc-sun-solaris2.5*)
+ AFS_SYSNAME="sun4x_55"
+ ;;
+ sparc-sun-solaris2.6)
+ AFS_SYSNAME="sun4x_56"
+ ;;
+ sparc-sun-solaris2.7)
+ AFS_SYSNAME="sun4x_57"
+ ;;
+ sparc-sun-solaris2.8)
+ AFS_SYSNAME="sun4x_58"
+ ;;
+ alpha*-dec-osf4.0*)
+ AFS_SYSNAME="alpha_dux40"
+ ;;
+ alpha*-dec-osf5.0*)
+ AFS_SYSNAME="alpha_dux50"
+ ;;
+ mips-sgi-irix6.5)
+ AFS_SYSNAME="sgi_65"
+ ;;
+ ia64-*-linux*)
+ AFS_SYSNAME="ia64_linuxXX"
+ ;;
+ powerpc-*-linux*)
+ AFS_SYSNAME="ppc_linuxXX"
+ ;;
+ alpha*-linux*)
+ AFS_SYSNAME="alpha_linux_XX"
+ ;;
+ s390-*-linux*)
+ AFS_SYSNAME="s390_linuxXX"
+ ;;
+ sparc-*-linux*)
+ AFS_SYSNAME="sparc_linuxXX"
+ ;;
+ sparc64-*-linux*)
+ AFS_SYSNAME="sparc64_linuxXX"
+ ;;
+ i?86-*-linux*)
+ AFS_SYSNAME="i386_linuxXX"
+ ;;
+ power*-ibm-aix4.2*)
+ AFS_SYSNAME="rs_aix42"
+ ;;
+ power*-ibm-aix4.3*)
+ AFS_SYSNAME="rs_aix42"
+ ;;
+ *)
+ AC_MSG_ERROR(An AFS sysname is required)
+ exit 1
+ ;;
+ esac
+ case $AFS_SYSNAME in
+ *_linux*)
+ AFS_SYSKVERS=`echo $LINUX_VERSION | awk -F\. '{print $1 $2}'`
+ if test "x${AFS_SYSKVERS}" = "x"; then
+ AC_MSG_ERROR(Couldn't guess your Linux version. Please use the --with-afs-sysname option to configure an AFS sysname.)
+ fi
+ _AFS_SYSNAME=`echo $AFS_SYSNAME|sed s/XX\$/$AFS_SYSKVERS/`
+ AFS_SYSNAME="$_AFS_SYSNAME"
+ ;;
+ esac
+ AC_MSG_RESULT($AFS_SYSNAME)
+fi
+
+
+if test "x${MKAFS_OSTYPE}" = "xIRIX"; then
+ echo Skipping library tests because they confuse Irix.
+else
+ AC_CHECK_FUNCS(socket)
+
+ if test "$ac_cv_func_socket" = no; then
+ for lib in socket inet; do
+ if test "$HAVE_SOCKET" != 1; then
+ AC_CHECK_LIB(${lib}, socket,LIBS="$LIBS -l$lib";HAVE_SOCKET=1;AC_DEFINE(HAVE_SOCKET))
+ fi
+ done
+ fi
+
+ AC_CHECK_FUNCS(connect)
+
+ if test "$ac_cv_func_connect" = no; then
+ for lib in nsl; do
+ if test "$HAVE_CONNECT" != 1; then
+ AC_CHECK_LIB(${lib}, connect,LIBS="$LIBS -l$lib";HAVE_CONNECT=1;AC_DEFINE(HAVE_CONNECT))
+ fi
+ done
+ fi
+
+ AC_CHECK_FUNCS(gethostbyname)
+ if test "$ac_cv_func_gethostbyname" = no; then
+ for lib in dns nsl resolv; do
+ if test "$HAVE_GETHOSTBYNAME" != 1; then
+ AC_CHECK_LIB(${lib}, gethostbyname, LIBS="$LIBS -l$lib";HAVE_GETHOSTBYNAME=1;AC_DEFINE(HAVE_GETHOSTBYNAME))
+ fi
+ done
+ fi
+
+ AC_CHECK_FUNCS(res_search)
+ if test "$ac_cv_func_res_search" = no; then
+ for lib in dns nsl resolv; do
+ if test "$HAVE_RES_SEARCH" != 1; then
+ AC_CHECK_LIB(${lib}, res_search, LIBS="$LIBS -l$lib";HAVE_RES_SEARCH=1;AC_DEFINE(HAVE_RES_SEARCH))
+ fi
+ done
+ if test "$HAVE_RES_SEARCH" = 1; then
+ LIB_res_search="-l$lib"
+ fi
+ fi
+fi
+
+PTHREAD_LIBS=error
+AC_CHECK_LIB(pthread, pthread_attr_init,
+ PTHREAD_LIBS="-lpthread")
+if test "x$PTHREAD_LIBS" = xerror; then
+ AC_CHECK_LIB(pthreads, pthread_attr_init,
+ PTHREAD_LIBS="-lpthreads")
+fi
+if test "x$PTHREAD_LIBS" = xerror; then
+ AC_CHECK_LIB(c_r, pthread_attr_init,
+ PTHREAD_LIBS="-lc_r")
+fi
+if test "x$PTHREAD_LIBS" = xerror; then
+ AC_CHECK_FUNC(pthread_attr_init, PTHREAD_LIBS="")
+fi
+if test "x$PTHREAD_LIBS" = xerror; then
+ AC_MSG_WARN(*** Unable to locate working posix thread library ***)
+fi
+AC_SUBST(PTHREAD_LIBS)
+
+WITH_OBSOLETE=NO
+if test "$enable_obsolete" = "yes"; then
+ WITH_OBSOLETE=YES
+fi
+
+WITH_INSECURE=NO
+if test "$enable_insecure" = "yes"; then
+ WITH_INSECURE=YES
+fi
+
+# Fast restart
+if test "$enable_fast_restart" = "yes"; then
+ AC_DEFINE(FAST_RESTART)
+fi
+
+if test "$enable_bitmap_later" = "yes"; then
+ AC_DEFINE(BITMAP_LATER)
+fi
+
+if test "$enable_full_vos_listvol_switch" = "yes"; then
+ AC_DEFINE(FULL_LISTVOL_SWITCH)
+fi
+
+if test "$enable_bos_restricted_mode" = "yes"; then
+ AC_DEFINE(BOS_RESTRICTED_MODE)
+fi
+
+if test "$enable_namei_fileserver" = "yes"; then
+ AC_DEFINE(AFS_NAMEI_ENV)
+fi
+
+if test "$enable_afsdb" = "yes"; then
+ LIB_AFSDB="$LIB_res_search"
+ AC_DEFINE(AFS_AFSDB_ENV)
+fi
+
+SRCDIR_PARENT=`pwd`
+TOP_SRCDIR="${SRCDIR_PARENT}"
+DESTDIR="${SRCDIR_PARENT}/${AFS_SYSNAME}/dest/"
+SRCDIR="${SRCDIR_PARENT}/${AFS_SYSNAME}/dest/"
+
+dnl checks for header files.
+AC_HEADER_STDC
+AC_HEADER_SYS_WAIT
+AC_HEADER_DIRENT
+AC_CHECK_HEADERS(stdlib.h string.h unistd.h fcntl.h sys/time.h sys/file.h)
+AC_CHECK_HEADERS(netinet/in.h netdb.h sys/fcntl.h sys/mnttab.h sys/mntent.h)
+AC_CHECK_HEADERS(mntent.h sys/vfs.h sys/param.h sys/fs_types.h)
+AC_CHECK_HEADERS(sys/mount.h strings.h termios.h signal.h)
+AC_CHECK_HEADERS(windows.h malloc.h winsock2.h direct.h io.h)
+AC_CHECK_HEADERS(security/pam_modules.h siad.h usersec.h)
+
+AC_CHECK_FUNCS(utimes random srandom getdtablesize snprintf re_comp re_exec)
+
+if test "x$enable_kernel_module" = "xyes"; then
+ENABLE_KERNEL_MODULE=libafs
+fi
+
+AC_SUBST(AFS_SYSNAME)
+AC_SUBST(ENABLE_KERNEL_MODULE)
+AC_SUBST(LIB_AFSDB)
+AC_SUBST(LINUX_KERNEL_PATH)
+AC_SUBST(LINUX_VERSION)
+AC_SUBST(MKAFS_OSTYPE)
+AC_SUBST(TOP_SRCDIR)
+AC_SUBST(DESTDIR)
+AC_SUBST(SRCDIR)
+AC_SUBST(WITH_OBSOLETE)
+AC_SUBST(WITH_INSECURE)
+
+AC_OUTPUT( \
+Makefile \
+config/Makefile.${AFS_SYSNAME} \
+)
aclocal -I src/cf
echo "Running autoconf"
autoconf
+echo "Running autoconf for configure-libafs"
+autoconf configure-libafs.in > configure-libafs
+chmod +x configure-libafs
echo "Running autoheader"
autoheader
#echo "Running automake"
CRULE3= $(CC) $(OPTF2) $(CFLAGS) -c $?
CRULE4= $(CC) $(DBG) $(CFLAGS) -c $?
-system: install
+system: all
kinstall: install
-install: all
+install: all $(INSTDIRS)
all: setup $(COMPDIRS)
-single_compdir:
+single_compdir single_instdir:
cd $(KOBJ) ; \
- echo $(MAKE) DESTDIR=${DESTDIR} libafs; \
- $(MAKE) DESTDIR=${DESTDIR} libafs;
+ echo $(MAKE) DESTDIR=${DESTDIR} $@_libafs; \
+ $(MAKE) DESTDIR=${DESTDIR} $@_libafs;
+
+single_compdir_libafs: libafs
+single_instdir_libafs: install_libafs
AFSAOBJS = \
afs_atomlist.o \
TOP_SRCDIR=@TOP_SRCDIR@
SYS_NAME=@AFS_SYSNAME@
-include ../config/Makefile.${SYS_NAME}
+include config/Makefile.${SYS_NAME}
# OS specific object files:
AFS_OS_OBJS = \
# This tells Makefile.common to use it's single directory build target.
COMPDIRS = single_compdir
+INSTDIRS = single_instdir
include Makefile.common
setup:
-mkdir $(KOBJ)
- -rm $(KOBJ)/Makefile $(KOBJ)/Makefile.common
+ -rm $(KOBJ)/Makefile $(KOBJ)/Makefile.common $(KOBJ)/config
ln -s ../Makefile $(KOBJ)/Makefile
ln -s ../Makefile.common $(KOBJ)/Makefile.common
+ ln -s ../config $(KOBJ)/config
-rm -f h net netinet rpc ufs nfs machine sys
ln -s /usr/include/sys h
ln -s /usr/include/net net
-bmap:afs.ext.map -o afs.ext \
${AFSAOBJS} $(AFSNOIAUTHOBJS) ${LIBS} ${LDFLAGS}
-libafs: $(DEST_LIBAFS) $(DEST_LIBAFSIAUTH)
+libafs: $(LIBAFS) $(LIBAFSIAUTH)
+install_libafs: $(DEST_LIBAFS) $(DEST_LIBAFSIAUTH)
# Object build rules:
TOP_SRCDIR=@TOP_SRCDIR@
SYS_NAME=@AFS_SYSNAME@
-include ../config/Makefile.${SYS_NAME}
+include config/Makefile.${SYS_NAME}
# OS specific object files:
# This tells Makefile.common to use it's single directory build target.
COMPDIRS = single_compdir
+INSTDIRS = single_instdir
include Makefile.common
setup:
-mkdir $(KOBJ)
- -rm $(KOBJ)/Makefile $(KOBJ)/Makefile.common
+ -rm $(KOBJ)/Makefile $(KOBJ)/Makefile.common $(KOBJ)/config
ln -s ../Makefile $(KOBJ)/Makefile
ln -s ../Makefile.common $(KOBJ)/Makefile.common
+ ln -s ../config $(KOBJ)/config
-rm -f h net netinet rpc ufs nfs machine sys vm mach kern
-ln -s $(KROOT)/System/Library/Frameworks/Kernel.framework/Headers/net net
-ln -s $(KROOT)/System/Library/Frameworks/Kernel.framework/Headers/machine machine
DEST_LIBAFSNONFS = ${DESTDIR}/root.client/usr/vice/etc/afs.kext/Contents/MacOS/afs
-libafs: $(DEST_LIBAFSNONFS) ;
+libafs: $(LIBAFSNONFS) ;
+install_libafs: $(DEST_LIBAFSNONFS) ;
$(DEST_LIBAFS): $(LIBAFS)
TOP_SRCDIR=@TOP_SRCDIR@
SYS_NAME=@AFS_SYSNAME@
-include ../config/Makefile.${SYS_NAME}
+include config/Makefile.${SYS_NAME}
# OS specific object files:
# This tells Makefile.common to use it's single directory build target.
COMPDIRS = single_compdir
+INSTDIRS = single_instdir
include Makefile.common
setup:
-mkdir $(KOBJ)
- -rm $(KOBJ)/Makefile $(KOBJ)/Makefile.common
+ -rm $(KOBJ)/Makefile $(KOBJ)/Makefile.common $(KOBJ)/config
ln -s ../Makefile $(KOBJ)/Makefile
ln -s ../Makefile.common $(KOBJ)/Makefile.common
+ ln -s ../config $(KOBJ)/config
-rm -f h net netinet rpc ufs nfs machine sys vm
-ln -s /usr/sys/include/net net
-ln -s /usr/sys/include/machine machine
# libafs: ${DEST_LIBAFS} ${DEST_LIBAFSNONFS} ${DEST_AFSMOD}
-.PHONY: libafs
-libafs: ${DEST_LIBAFSNONFS} ${DEST_AFSMOD}
+.PHONY: libafs install_libafs
+libafs: ${LIBAFSNONFS} ${AFSMOD}
+install_libafs: ${DEST_LIBAFSNONFS} ${DEST_AFSMOD}
${DEST_LIBAFS}: ${LIBAFS}
TOP_SRCDIR=@TOP_SRCDIR@
SYS_NAME=@AFS_SYSNAME@
-# include ../config/Makefile.${SYS_NAME}
+# include config/Makefile.${SYS_NAME}
# OS specific object files:
AFS_OS_OBJS = \
# This tells Makefile.common to use it's single directory build target.
COMPDIRS = single_compdir
+INSTDIRS = single_instdir
include Makefile.common
setup:
-mkdir $(KOBJ)
- -rm $(KOBJ)/Makefile $(KOBJ)/Makefile.common
+ -rm $(KOBJ)/Makefile $(KOBJ)/Makefile.common $(KOBJ)/config
ln -s ../Makefile $(KOBJ)/Makefile
ln -s ../Makefile.common $(KOBJ)/Makefile.common
+ ln -s ../config $(KOBJ)/config
-rm -f h net netinet rpc ufs nfs machine sys vm
-ln -s /usr/src/sys/net net
-ln -s /usr/src/sys/i386/include machine
DEST_LIBAFSNONFS = ${DESTDIR}/root.client/bin/${LIBAFSNONFS}
-# libafs: $(DEST_LIBAFS) $(DEST_LIBAFSNONFS)
-# libafs: $(DEST_LIBAFSNONFS)
+# libafs: $(LIBAFS) $(LIBAFSNONFS)
+# libafs: $(LIBAFSNONFS)
+# install_libafs: $(DEST_LIBAFS) $(DEST_LIBAFSNONFS)
+# install_libafs: $(DEST_LIBAFSNONFS)
libafs:
echo WARNING: No kernel module for ${SYS_NAME}
+install_libafs:
+ echo WARNING: No kernel module for ${SYS_NAME}
+
$(DEST_LIBAFS): $(LIBAFS)
$(INSTALL) -f $? $@
TOP_SRCDIR=@TOP_SRCDIR@
SYS_NAME=@AFS_SYSNAME@
-include ../config/Makefile.${SYS_NAME}
+include config/Makefile.${SYS_NAME}
# OS specific object files:
AFS_OS_OBJS = \
#COMPDIRS = single_compdir
# This is the hpux multiple directory target.
COMPDIRS = hpux_compdirs
+INSTDIRS = hpux_instdirs
include Makefile.common
dir=$$t.$$b; \
echo Making directory: $$dir; \
mkdir -p $$dir; \
- rm -f $$dir/Makefile $$dir/Makefile.common; \
+ rm -f $$dir/Makefile $$dir/Makefile.common $$dir/config; \
ln -s ../Makefile $$dir/Makefile; \
ln -s ../Makefile.common $$dir/Makefile.common; \
+ ln -s ../config $$dir/config; \
done; \
done
echo Setup complete.
# Compile the clients.
-${COMPDIRS}:
+${COMPDIRS} ${INSTDIRS}:
if false; then \
for b in $(BITS); do \
for t in $(KOBJ); do \
64) bopts="$(KDEFS_64)"; bsuff="64";; \
esac; \
cd $$dir; \
- $(MAKE) BITSUFFIX=$$bsuff CPU_KDEFS="$$bopts" libafs || exit $$?; \
+ $(MAKE) BITSUFFIX=$$bsuff CPU_KDEFS="$$bopts" $@_libafs || exit $$?; \
cd ..; \
done; \
done; \
fi
+hpux_compdirs_libafs: libafs
+hpux_instdirs_libafs: install_libafs
+
# Below this line are targets when in the static directory:
LIBAFS = libafs$(BITSUFFIX).a
# libafs: ${DEST_LIBAFS} ${DEST_LIBAFSNONFS}
-libafs: ${DEST_LIBAFSNONFS}
+libafs: ${LIBAFSNONFS}
+install_libafs: ${DEST_LIBAFSNONFS}
$(DEST_LIBAFS): $(LIBAFS)
${INSTALL} -f $? $@
TOP_SRCDIR=@TOP_SRCDIR@
SYS_NAME=@AFS_SYSNAME@
-include ../config/Makefile.${SYS_NAME}
+include config/Makefile.${SYS_NAME}
# OS specific object files:
AFS_OS_OBJS = \
#COMPDIRS = single_compdir
# This is the irix multiple directory target.
COMPDIRS = irix_compdirs
+INSTDIRS = irix_instdirs
include Makefile.common
dir=$$t.$$n.$$p ; \
echo Making directory: $$dir; \
mkdir -p $$dir; \
- rm -f $$dir/Makefile.common $$dir/Makefile; \
+ rm -f $$dir/Makefile.common $$dir/Makefile $$dir/config; \
ln -s ../Makefile.common $$dir/Makefile.common; \
ln -s ../Makefile $$dir/Makefile; \
+ ln -s ../config $$dir/config; \
done; \
done; \
done
dir=$$t.$$p ; \
echo Making directory: $$dir; \
mkdir -p $$dir; \
- rm -f $$dir/Makefile.common $$dir/Makefile; \
+ rm -f $$dir/Makefile.common $$dir/Makefile $$dir/config; \
ln -s ../Makefile.common $$dir/Makefile.common; \
ln -s ../Makefile $$dir/Makefile; \
+ ln -s ../config $$dir/config; \
done; \
done
<all>
# Compile static and modload versions of the clients.
<all -sgi_65>
-${COMPDIRS}:
+${COMPDIRS} ${INSTDIRS}:
BUILDPROCS="${PROCESSORS}" ; \
if [ "${CPUARCH}" != "" ] ; then \
BUILDPROCS=${CPUARCH}; \
export CPU_KDEFS ;\
export LDFLAGS; \
cd $$dir ; \
- $(MAKE) CPUARCH=$$p MPSP=$$n $$t.libafs || exit $$?;\
+ $(MAKE) CPUARCH=$$p MPSP=$$n $@_$$t.libafs || exit $$?;\
cd ../ ; \
done; \
done; \
done
<sgi_65>
-${COMPDIRS}:
+${COMPDIRS} ${INSTDIRS}:
BUILDPROCS="${PROCESSORS}" ; \
if [ "${IPNO}" != "" ] ; then \
BUILDPROCS="${IPNO}"; \
export CPU_KDEFS ;\
export LDFLAGS ;\
cd $$dir ; \
- $(MAKE) IPNO=$$p $$t.libafs || exit $$?; \
+ $(MAKE) IPNO=$$p $@_$$t.libafs || exit $$?; \
cd ../ ; \
done; \
done
<all>
+irix_compdirs_STATIC.libafs: STATIC.libafs
+irix_compdirs_MODLOAD.libafs: MODLOAD.libafs
+irix_instdirs_STATIC.libafs: install_STATIC.libafs
+irix_instdirs_MODLOAD.libafs: install_MODLOAD.libafs
+
LIBAFSNONFSA = libafs.nonfs.a
COPYFILES = copyfiles
LINKFILES = linkfiles
+${INSTDIRS}: ${COPYFILES} ${LINKFILES}
+
STATICCLIENTDIR = ${DESTDIR}root.client/bin
MODLOADCLIENTDIR = ${DESTDIR}root.client/usr/vice/etc/sgiload
# Make the NFS and no-NFS clients for this directory.
# STATIC.libafs: ${LIBAFSNONFSA} ${COPYFILES} ${LINKFILES}
-STATIC.libafs: ${LIBAFSNONFSA} ${COPYFILES} ${LINKFILES}
+STATIC.libafs: ${LIBAFSNONFSA}
+install_STATIC.libafs: ${LIBAFSNONFSA}
<all -sgi_65>
${CP} ${LIBAFSNONFSA} \
${STATICCLIENTDIR}/libafs.${MPSP}.${CPUARCH}.nonfs.a
LIBAFSNONFSO = libaf.nonfs.o
# MODLOAD.libafs: ${LIBAFSNONFSO} ${COPYFILES} ${LINKFILES}
-MODLOAD.libafs: ${LIBAFSNONFSO} ${COPYFILES} ${LINKFILES}
+MODLOAD.libafs: ${LIBAFSNONFSO}
+install_MODLOAD.libafs: ${LIBAFSNONFSO}
<all -sgi_65>
${CP} ${LIBAFSNONFSO} \
${MODLOADCLIENTDIR}/libafs.${MPSP}.${CPUARCH}.nonfs.o
TOP_SRCDIR=@TOP_SRCDIR@
SYS_NAME=@AFS_SYSNAME@
-include ../config/Makefile.${SYS_NAME}
+include config/Makefile.${SYS_NAME}
# OS specific object files:
AFS_OS_OBJS = \
# COMPDIRS is called in Makefile.common to do the actual builds.
COMPDIRS=linux_compdirs
+INSTDIRS=linux_instdirs
include Makefile.common
mkdir -p $${KDIR}; \
ln -fs ../Makefile $${KDIR}/Makefile ; \
ln -fs ../Makefile.common $${KDIR}/Makefile.common; \
+ ln -fs ../config $${KDIR}/config; \
done
# Compile SP and MP clients as requested
-${COMPDIRS}:
+${COMPDIRS} ${INSTDIRS}:
rm -f h
ln -s ${LINUX_KERNEL_PATH}/include/linux h
rm -f linux
cd ../ ; \
done
+linux_compdirs_libafs: libafs
+linux_compdirs_libafs.mp: libafs.mp
+linux_instdirs_libafs: install_libafs
+linux_instdirs_libafs.mp: install_libafs.mp
+
# Below this line are targets when in the COMMON directory:
# For Linux there is no kernel NFS server.
DEST_LIBAFS_MP = ${DESTDIR}/root.client/usr/vice/etc/modload/${LIBAFS_MP}
-libafs: $(DEST_LIBAFS)
+libafs: $(LIBAFS)
echo SP Build Complete
-libafs.mp: $(DEST_LIBAFS_MP)
+libafs.mp: $(LIBAFS_MP)
echo MP Build Complete
-$(DEST_LIBAFS): $(LIBAFS)
- ${INSTALL} -f $? $@
-
-$(DEST_LIBAFS_MP): $(LIBAFS_MP)
- ${INSTALL} -f $? $@
-
${LIBAFS}: $(AFSAOBJS) $(AFSNONFSOBJS)
$(RM) -f $@
$(LD) -r -o $@ $(AFSAOBJS) $(AFSNONFSOBJS)
$(RM) -f $@
$(LD) -r -o $@ $(AFSAOBJS) $(AFSNONFSOBJS)
+install_libafs: $(DEST_LIBAFS)
+ echo SP Install Complete
+
+install_libafs.mp: $(DEST_LIBAFS_MP)
+ echo MP Install Complete
+
+$(DEST_LIBAFS): $(LIBAFS)
+ ${INSTALL} -f $? $@
+
+$(DEST_LIBAFS_MP): $(LIBAFS_MP)
+ ${INSTALL} -f $? $@
+
# Linux specific objects
osi_alloc.o: $(AFS)/osi_alloc.c
TOP_SRCDIR=@TOP_SRCDIR@
SYS_NAME=@AFS_SYSNAME@
-include ../config/Makefile.${SYS_NAME}
+include config/Makefile.${SYS_NAME}
# OS specific object files:
AFS_OS_OBJS = \
# This tells Makefile.common to use it's single directory build target.
<all -sun4x_57 -sun4x_58>
COMPDIRS = single_compdir
+INSTDIRS = single_instdir
<sun4x_57 sun4x_58>
COMPDIRS = solaris_compdirs
+INSTDIRS = solaris_instdirs
<all>
include Makefile.common
for t in ${KOBJ} ; do \
echo Making directory: $$t; \
mkdir -p $$t; \
- rm -f $$t/Makefile.common $$t/Makefile ; \
+ rm -f $$t/Makefile.common $$t/Makefile $$t/config ; \
ln -s ../Makefile.common $$t/Makefile.common ; \
ln -s ../Makefile $$t/Makefile ;\
+ ln -s ../config $$t/config ;\
done
## the 64 bit libafs in MODLOAD32 and MODLOAD64 directories respectively
<sun4x_57 sun4x_58>
-${COMPDIRS}:
+${COMPDIRS} ${INSTDIRS}:
for t in ${KOBJ} ; do \
echo Building directory: $$t ; \
case $$t in \
export ARCH_DEFS ; \
export BITS ; \
cd $$t ; \
- $(MAKE) libafs ; \
+ $(MAKE) $@_libafs ; \
cd ../ ;\
done
+solaris_compdirs_libafs: libafs
+solaris_instdirs_libafs: install_libafs
+
<all>
# Below this line are targets when in the COMMON directory:
.PHONY: libafs
# libafs: $(DEST_LIBAFS) $(DEST_LIBAFSNONFS)
-libafs: $(DEST_LIBAFSNONFS)
+libafs: $(LIBAFSNONFS)
+install_libafs: $(DEST_LIBAFSNONFS)
$(DEST_LIBAFS): $(LIBAFS)
MODLOADDIR = ${DESTDIR}root.client/usr/vice/etc/modload
libafs: ${LIBAFSNONFS}
+install_libafs: ${LIBAFSNONFS}
${INSTALL} -f ${LIBAFSNONFS} ${MODLOADDIR}/libafs${BITS}.nonfs.o
<all>