aix64-dont-build-on-aix4-20040317
[openafs.git] / src / export / Makefile.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 srcdir=@srcdir@
9 include @TOP_OBJDIR@/src/config/Makefile.config
10
11   EXPORTS = -bexport:export.exp
12   IMPORTS = /lib/kernex.exp /lib/syscalls.exp ${srcdir}/extras.exp
13      KOBJ = export.o symtab.o
14
15 include ../config/Makefile.version
16
17 all: ${TOP_LIBDIR}/export.exp ${TOP_LIBDIR}/export64.exp ${TOP_LIBDIR}/extras.exp cfgexport cfgafs
18         ${INSTALL} ${srcdir}/export.h ${KERNELDIR}
19         ${INSTALL} export.exp ${KERNELDIR}
20         ${INSTALL} export64.exp ${KERNELDIR}
21         ${INSTALL} ${srcdir}/export.h ${UKERNELDIR}
22         ${INSTALL} export64.exp ${UKERNELDIR}
23         ${INSTALL} export.exp ${UKERNELDIR}
24
25 noversion system: install
26
27 install: ${DESTDIR}${libdir}/afs/export.exp ${DESTDIR}${libdir}/afs/extras.exp  
28
29 export.exp: ${srcdir}/export4.exp ${srcdir}/export5.exp
30         case ${SYS_NAME} in \
31         rs_aix4* ) \
32                 cp -p ${srcdir}/export4.exp export.exp ; \
33                 cp -p ${srcdir}/export4-64.exp export64.exp ;; \
34         rs_aix5* ) \
35                 cp -p ${srcdir}/export5.exp export.exp ; \
36                 cp -p ${srcdir}/export5-64.exp export64.exp ;; \
37         esac
38
39 export.ext: ${KOBJ}
40         ${LD} -o export.ext -eexport ${IMPORTS} ${KOBJ} ${EXPORTS} -lcsys
41
42 export64.ext: export64.o symtab64.o
43         ${LD} -b64 -o export64.ext -eexport ${IMPORTS} export64.o symtab64.o \
44                 -bexport:export64.exp -lcsys
45
46 export.ext.nonfs: export.nonfs.o symtab.o
47         ${LD} -o export.ext.nonfs -eexport ${IMPORTS} export.nonfs.o \
48                 symtab.o ${EXPORTS} -lcsys
49
50 export64.ext.nonfs: export64.nonfs.o symtab64.o
51         ${LD} -b64 -o export64.ext.nonfs -eexport ${IMPORTS} export64.nonfs.o \
52                 symtab64.o -bexport:export64.exp -lcsys
53
54 symtab.o symtab64.o: ${srcdir}/symtab.c
55         case ${SYS_NAME} in \
56         rs_aix4* ) \
57                 ${CC} ${CFLAGS} -c ${srcdir}/symtab.c ;; \
58         rs_aix5* ) \
59                 ${CC} ${CFLAGS} -q64 -D__XCOFF64__ -DAFS_64BIT_KERNEL -DAFS_AIX51_ENV -c ${srcdir}/symtab.c ; \
60                 mv symtab.o symtab64.o ; \
61                 ${CC} ${CFLAGS} -DAFS_AIX51_ENV -c ${srcdir}/symtab.c ;; \
62         esac
63
64 export.o export64.o: ${srcdir}/export.c
65         case ${SYS_NAME} in \
66         rs_aix4* ) \
67                 ${CC} ${CFLAGS} -c ${srcdir}/export.c ;; \
68         rs_aix5* ) \
69                 ${CC} ${CFLAGS} -q64 -D__XCOFF64__ -DAFS_64BIT_KERNEL -DAFS_AIX51_ENV -c ${srcdir}/export.c ; \
70                 mv export.o export64.o ; \
71                 ${CC} ${CFLAGS} -DAFS_AIX51_ENV -c ${srcdir}/export.c ;; \
72         esac
73                
74 export.nonfs.o export64.nonfs.o: ${srcdir}/export.c
75         case ${SYS_NAME} in \
76         rs_aix4* ) \
77                 ${CC} ${INCS} -DAFS_NONFSTRANS -c ${srcdir}/export.c ;; \
78         rs_aix5* ) \
79                 ${CC} -q64 ${INCS} -D__XCOFF64__ -DAFS_64BIT_KERNEL -DAFS_NONFSTRANS -DAFS_AIX51_ENV -c ${srcdir}/export.c ; \
80                 mv export.o export64.nonfs.o ; \
81                 ${CC} ${INCS} -DAFS_NONFSTRANS -DAFS_AIX51_ENV -c ${srcdir}/export.c ;; \
82         esac
83         -mv export.o export.nonfs.o
84
85 cfgexport: cfgexport.o
86         ${CC} -g ${INCS} -o cfgexport cfgexport.o
87
88 cfgexport64: cfgexport64.o
89         ${CC} -g ${INCS} -q64 -o cfgexport64 cfgexport64.o
90
91 cfgafs: cfgafs.o
92         ${CC} ${INCS} -o cfgafs cfgafs.o
93
94 cfgafs64: cfgafs64.o
95         ${CC} -g ${INCS} -q64 -o cfgafs64 cfgafs64.o
96
97 cfgexport64.o: ${srcdir}/cfgexport.c AFS_component_version_number.c
98         ${CC} -g -q64 ${CFLAGS} -D__XCOFF64__ -c ${srcdir}/cfgexport.c -o cfgexport64.o
99
100 cfgexport.o: ${srcdir}/cfgexport.c AFS_component_version_number.c
101 cfgafs.o: ${srcdir}/cfgafs.c AFS_component_version_number.c
102 cfgafs64.o: ${srcdir}/cfgafs.c AFS_component_version_number.c
103         ${CC} -q64 ${CFLAGS} -c ${srcdir}/cfgafs.c -o cfgafs64.o
104
105 clean:
106         $(RM) -f *.o *.Zlst *.map *.out cfgexport cfgafs *.ext AFS_component_version_number.c export.exp export64.exp
107
108 ${DEST}/root.client/usr/vice/etc/dkload/export.ext: export.ext
109         ${INSTALL} $? $@
110
111 ${DEST}/root.client/usr/vice/etc/dkload/export64.ext: @AIX64@export64.ext
112 @AIX64@ ${INSTALL} $? $@
113
114 ${DEST}/root.client/usr/vice/etc/dkload/export.ext.nonfs: export.ext.nonfs
115         ${INSTALL} $? $@
116
117 ${DEST}/root.client/usr/vice/etc/dkload/export64.ext.nonfs: @AIX64@export64.ext.nonfs
118 @AIX64@ ${INSTALL} $? $@
119
120 ${DEST}/lib/afs/export.exp: export.exp
121         ${INSTALL} $? $@
122
123 ${DEST}/lib/afs/export64.exp: export64.exp
124         ${INSTALL} $? $@
125
126 ${DESTDIR}${libdir}/afs/export.exp: export.exp
127         ${INSTALL} $? $@ 
128
129 ${DESTDIR}${libdir}/afs/export64.exp: export64.exp
130         ${INSTALL} $? $@ 
131
132 ${TOP_LIBDIR}/export.exp: export.exp
133         ${INSTALL} $? $@
134
135 ${TOP_LIBDIR}/export64.exp: export64.exp
136         ${INSTALL} $? $@
137
138 ${DEST}/lib/afs/extras.exp: ${srcdir}/extras.exp
139         ${INSTALL} $? $@
140
141 ${DESTDIR}${libdir}/afs/extras.exp: ${srcdir}/extras.exp
142         ${INSTALL} $? $@
143
144
145 ${TOP_LIBDIR}/extras.exp: ${srcdir}/extras.exp
146         ${INSTALL} $? $@
147
148
149 ${DEST}/root.client/usr/vice/etc/dkload/cfgexport: cfgexport
150         ${INSTALL} $? $@
151
152 ${DEST}/root.client/usr/vice/etc/dkload/cfgexport64: @AIX64@cfgexport64
153 @AIX64@ ${INSTALL} $? $@
154
155 ${DEST}/root.client/usr/vice/etc/dkload/cfgafs: @AIX64@cfgafs
156 @AIX64@ ${INSTALL} $? $@
157
158 ${DEST}/root.client/usr/vice/etc/dkload/cfgafs64: @AIX64@cfgafs64
159 @AIX64@ ${INSTALL} $? $@
160
161 dest:    ${DEST}/root.client/usr/vice/etc/dkload/export.ext \
162         ${DEST}/root.client/usr/vice/etc/dkload/export.ext.nonfs \
163         ${DEST}/root.client/usr/vice/etc/dkload/export64.ext.nonfs \
164         ${DEST}/lib/afs/export.exp \
165         ${DEST}/lib/afs/export64.exp \
166         ${DEST}/lib/afs/extras.exp \
167         ${DEST}/root.client/usr/vice/etc/dkload/cfgexport \
168         ${DEST}/root.client/usr/vice/etc/dkload/cfgafs \
169         ${DEST}/root.client/usr/vice/etc/dkload/export64.ext \
170         ${DEST}/root.client/usr/vice/etc/dkload/cfgexport64 \
171         ${DEST}/root.client/usr/vice/etc/dkload/cfgafs64