apply-modversions-so-nothing-has-first-been-included-20010623
[openafs.git] / src / libafs / MakefileProto.DUX.in
1 # Copyright 2000, International Business Machines Corporation and others.
2 # All Rights Reserved.
3
4 # This software has been released under the terms of the IBM Public
5 # License.  For details, see the LICENSE file in the top-level source
6 # directory or online at http://www.openafs.org/dl/license10.html
7
8 # MakefileProto for Digital Unix systems
9 #
10
11 DESTDIR=DEST/
12 include ../config/Makefile.${SYS_NAME}
13
14
15 # OS specific object files:
16 AFS_OS_OBJS = \
17         osi_groups.o \
18         osi_file.o \
19         osi_inode.o \
20         osi_misc.o \
21         osi_sleep.o \
22         osi_vm.o \
23         osi_vnodeops.o 
24
25 AFS_OS_NFSOBJS = \
26         osi_vfsops_nfs.o
27
28 AFS_OS_NONFSOBJS = \
29         osi_vfsops.o
30
31
32 # System specific build commands and flags
33 KDEFS=-DLANGUAGE_C -G 4 -I/usr/sys/include -I../include \
34          -I/usr/sys/${HEADER_RT} -I/usr/sys/BINARY -I/usr/sys/AFS \
35         -DDEC3000_500 -DSWAPTYPE=1 -DUERF -DOSF -DCOMPAT_43 -DMACH -DUFS \
36         -DRT -DKERNEL -D_KERNEL  -signed  -no_excpt -Wb,-static -Wco,-nofloat \
37         -Olimit 1000 -D__alpha -Umips -UMIPS 
38 DBUG = -O2 -g3
39 DEFINES= -DAFSDEBUG -DKERNEL -DAFS -DVICE -DNFS -DUFS -DINET -DQUOTA -DGETMOUNT
40 OPTF=${OPT} 
41 OPTF2=${OPT2} 
42 CFLAGS=-I. -I.. -I${TOP_SRCDIR}/config ${FSINCLUDES} $(DEFINES) $(KDEFS) $(KOPTS) ${DBUG}
43
44
45 # Name of directory to hold object files and libraries.
46 KOBJ = STATIC
47
48 # This tells Makefile.common to use it's single directory build target.
49 COMPDIRS = single_compdir
50
51 include Makefile.common
52
53 setup:
54         -mkdir $(KOBJ)
55         -rm $(KOBJ)/Makefile $(KOBJ)/Makefile.common
56         ln -s ../Makefile $(KOBJ)/Makefile
57         ln -s ../Makefile.common $(KOBJ)/Makefile.common
58         -rm -f  h net netinet rpc ufs nfs  machine sys vm
59         -ln -s /usr/sys/include/net net
60         -ln -s /usr/sys/include/machine machine
61         -ln -s /usr/sys/include/netinet netinet
62         -ln -s /usr/sys/include/nfs nfs
63         -ln -s /usr/sys/include/rpc rpc
64         -ln -s /usr/sys/include/sys sys
65         -ln -s /usr/sys/include/ufs ufs
66         -ln -s /usr/sys/include/sys h
67         -ln -s /usr/sys/include/vm vm
68         -touch $(KOBJ)/sec_net.h
69
70
71 # Below this line are targets when in the COMMON directory:
72 LIBAFS = libafs.o
73 LIBAFSNONFS = libafs.nonfs.o
74
75 DEST_LIBAFS = ${DESTDIR}/root.client/bin/${LIBAFS}
76 DEST_LIBAFSNONFS = ${DESTDIR}/root.client/bin/${LIBAFSNONFS}
77
78
79 # libafs:       $(DEST_LIBAFS) $(DEST_LIBAFSNONFS)
80
81 .PHONY: libafs
82 libafs: $(DEST_LIBAFSNONFS)
83
84
85 $(DEST_LIBAFS): $(LIBAFS)
86         $(INSTALL) -f $? $@
87
88 $(DEST_LIBAFSNONFS): $(LIBAFSNONFS)
89         $(INSTALL) -f $? $@
90
91 ${LIBAFS}: $(AFSAOBJS) $(AFSNFSOBJS)
92         $(LD) -r -o ${LIBAFS} ${AFSAOBJS} ${AFSNFSOBJS}
93
94 ${LIBAFSNONFS}:  $(AFSAOBJS) $(AFSNONFSOBJS)
95         $(LD) -r -o ${LIBAFSNONFS} ${AFSAOBJS} ${AFSNONFSOBJS}
96
97
98 # Object build rules:
99 osi_groups.o: $(AFS)/osi_groups.c
100         $(CRULE1)
101 osi_file.o: $(AFS)/osi_file.c
102         $(CRULE1)
103 osi_inode.o: $(AFS)/osi_inode.c
104         $(CRULE1)
105 osi_misc.o: $(AFS)/osi_misc.c
106         $(CRULE1)
107 osi_sleep.o: $(AFS)/osi_sleep.c
108         $(CRULE1)
109 osi_vfsops_nfs.o: $(AFS)/osi_vfsops.c
110         $(CRULE1) -o osi_vfsops_nfs.o
111 osi_vfsops.o: $(AFS)/osi_vfsops.c
112         $(CRULE1) -DAFS_NONFSTRANS
113 osi_vm.o: $(AFS)/osi_vm.c
114         $(CRULE1)
115 osi_vnodeops.o: $(AFS)/osi_vnodeops.c
116         $(CRULE1)