3c3f820dfb5d8f93f477eccb5b28bc00beecb8ca
[openafs.git] / src / cf / osconf.m4
1
2 AC_DEFUN([OPENAFS_OSCONF], [
3
4 dnl defaults, override in case below as needed
5 XCFLAGS='${DBG} ${OPTMZ}'
6 RXDEBUG="-DRXDEBUG"
7 SHLIB_SUFFIX="so"
8 CCOBJ="$CC"
9 MT_CC="$CC"
10 XLIBS="${LIB_AFSDB} ${XBSA_XLIBS} ${LIB_libintl}"
11 MT_LIBS="-lpthread ${XLIBS}"
12
13 dnl debugging and optimization flag defaults
14 dnl Note, these are all the defaults for if debug/optimize turned on, and
15 dnl the arch cases below do override as needed
16 KERN_DBG=-g
17 KERN_OPTMZ=-O
18 DBG=-g
19 OPTMZ=-O
20 LWP_DBG=-g
21 NO_STRIP_BIN=
22 LWP_OPTMZ=-O
23 PAM_DBG=-g
24 PAM_OPTMZ=
25
26 dnl standard programs
27 AC_PROG_RANLIB
28 AC_CHECK_PROGS(AS, as, [${am_missing_run}as])
29 AC_CHECK_PROGS(AR, ar, [${am_missing_run}ar])
30 AC_CHECK_PROGS(MV, mv, [${am_missing_run}mv])
31 AC_CHECK_PROGS(RM, rm, [${am_missing_run}rm])
32 AC_CHECK_PROGS(LD, ld, [${am_missing_run}ld])
33 AC_CHECK_PROGS(CP, cp, [${am_missing_run}cp])
34 AC_CHECK_PROGS(STRIP, strip, [${am_missing_run}strip])
35 AC_CHECK_PROGS(LORDER, lorder, [${am_missing_run}lorder])
36
37 dnl TODO - need to disable STRIP if we are doing debugging in any user space code
38
39 case $AFS_SYSNAME in
40         alpha_dux40)
41                 CC="cc"
42                 CCOBJ="cc"
43                 MT_CC="cc"
44                 CSTATIC="-non_shared"
45                 DBG="-g3"
46                 MT_CFLAGS='-D_REENTRANT=1 -pthread -DAFS_PTHREAD_ENV ${XCFLAGS}'
47                 MT_LIBS="-pthread -lpthread -lmach -lexc -lc"
48                 XCFLAGS="-D_NO_PROTO -DOSF"
49                 SHLIB_LINKER="${CC} -all -shared -expect_unresolved \"*\""
50                 ;;
51
52         alpha_dux50)
53                 CC="cc"
54                 CCOBJ="cc"
55                 MT_CC="cc"
56                 LEX="flex -l"
57                 DBG="-g3"
58                 CSTATIC="-non_shared"
59                 MT_CFLAGS='-D_REENTRANT=1 -pthread -DAFS_PTHREAD_ENV ${XCFLAGS}'
60                 MT_LIBS="-pthread -lpthread -lmach -lexc -lc"
61                 XCFLAGS="-D_NO_PROTO -DOSF"
62                 SHLIB_LINKER="${CC} -all -shared -expect_unresolved \"*\""
63                 ;;
64
65         alpha_dux51)
66                 CC="cc"
67                 CCOBJ="cc"
68                 MT_CC="cc"
69                 DBG="-g3"
70                 CSTATIC="-non_shared"
71                 LWP_OPTMZ="-O2"
72                 MT_CFLAGS='-D_REENTRANT=1 -pthread -DAFS_PTHREAD_ENV ${XCFLAGS}'
73                 MT_LIBS="-pthread -lpthread -lmach -lexc -lc"
74                 XCFLAGS="-D_NO_PROTO -DOSF"
75                 SHLIB_LINKER="${CC} -all -shared -expect_unresolved \"*\""
76                 ;;
77
78         alpha_linux_22)
79                 KERN_OPTMZ=-O2
80                 MT_CFLAGS='-DAFS_PTHREAD_ENV -pthread -D_REENTRANT ${XCFLAGS}'
81                 PAM_OPTMZ=-O2
82                 PAM_CFLAGS="-Dlinux -DLINUX_PAM -fPIC"
83                 SHLIB_CFLAGS="-fPIC"
84                 SHLIB_LDFLAGS="-shared -Xlinker -x"
85                 XCFLAGS="-D_LARGEFILE64_SOURCE"
86                 SHLIB_LINKER="${MT_CC} -shared"
87                 ;;
88
89         alpha_linux_24)
90                 CCOBJ="${CC} -fPIC"
91                 KERN_OPTMZ=-O2
92                 MT_CFLAGS='-DAFS_PTHREAD_ENV -pthread -D_REENTRANT ${XCFLAGS}'
93                 PAM_OPTMZ=-O2
94                 PAM_CFLAGS="-Dlinux -DLINUX_PAM -fPIC"
95                 SHLIB_CFLAGS="-fPIC"
96                 SHLIB_LDFLAGS="-shared -Xlinker -x"
97                 XCFLAGS="-D_LARGEFILE64_SOURCE"
98                 SHLIB_LINKER="${MT_CC} -shared"
99                 ;;
100
101         alpha_linux_26)
102                 CCOBJ="${CC} -fPIC"
103                 KERN_OPTMZ=-O2
104                 MT_CFLAGS='-DAFS_PTHREAD_ENV -pthread -D_REENTRANT ${XCFLAGS}'
105                 PAM_OPTMZ=-O2
106                 PAM_CFLAGS="-Dlinux -DLINUX_PAM -fPIC"
107                 SHLIB_CFLAGS="-fPIC"
108                 SHLIB_LDFLAGS="-shared -Xlinker -x"
109                 XCFLAGS="-D_LARGEFILE64_SOURCE"
110                 SHLIB_LINKER="${MT_CC} -shared"
111                 ;;
112
113         arm_linux24)
114                 CCOBJ="${CC} -fPIC"
115                 KERN_OPTMZ=-O2
116                 MT_CFLAGS='-DAFS_PTHREAD_ENV -pthread -D_REENTRANT ${XCFLAGS}'
117                 PAM_OPTMZ=-O2
118                 PAM_CFLAGS="-Dlinux -DLINUX_PAM -fPIC"
119                 SHLIB_CFLAGS="-fPIC"
120                 SHLIB_LDFLAGS="-shared -Xlinker -x"
121                 XCFLAGS="-D_LARGEFILE64_SOURCE"
122                 SHLIB_LINKER="${MT_CC} -shared"
123                 ;;
124
125         arm_linux26)
126                 CCOBJ="${CC} -fPIC"
127                 KERN_OPTMZ=-O2
128                 MT_CFLAGS='-DAFS_PTHREAD_ENV -pthread -D_REENTRANT ${XCFLAGS}'
129                 PAM_OPTMZ=-O2
130                 PAM_CFLAGS="-Dlinux -DLINUX_PAM -fPIC"
131                 SHLIB_CFLAGS="-fPIC"
132                 SHLIB_LDFLAGS="-shared -Xlinker -x"
133                 XCFLAGS="-D_LARGEFILE64_SOURCE"
134                 SHLIB_LINKER="${MT_CC} -shared"
135                 ;;
136
137         hp_ux102)
138                 AS="/usr/ccs/bin/as"
139                 CC="/opt/ansic/bin/cc -Ae"
140                 CCOBJ="/opt/ansic/bin/cc -Ae"
141                 DBM="/lib/libndbm.a"
142                 LD="/bin/ld"
143                 LEX="/opt/langtools/bin/lex"
144                 LWP_OPTMZ="-O"
145                 MT_CC="/opt/ansic/bin/cc -Ae"
146                 MT_CFLAGS='-D_POSIX_C_SOURCE=199506L -DAFS_PTHREAD_ENV ${XCFLAGS}'
147                 MT_LIBS="-L/opt/dce/lib -ldce ${XLIBS}"
148                 MV="/bin/mv"
149                 OPTMZ="-O"
150                 PAM_CFLAGS="+DA1.0 +z -Wl,+k"
151                 PAM_LIBS="/usr/lib/libpam.1"
152                 RANLIB="/usr/bin/ranlib"
153                 RM="/bin/rm"
154                 SHLIB_LDFLAGS="-b -Bsymbolic"
155                 SHLIB_SUFFIX="sl"
156                 VFSCK_CFLAGS="-D_FILE64"
157                 XCFLAGS0="-ldld -lc -Wp,-H200000 -Wl,-a,archive -DAUTH_DBM_LOG +z -Wl,+k -D_LARGEFILE64_SOURCE"
158                 XCFLAGS64="${XCFLAGS0} +DA2.0W"
159                 XCFLAGS="${XCFLAGS0} +DA1.0"
160                 YACC="/opt/langtools/bin/yacc"
161                 SHLIB_LINKER="ld -b"
162                 ;;
163
164         hp_ux11*)
165                 AR="/usr/bin/ar"
166                 AS="/usr/ccs/bin/as"
167                 CC="/opt/ansic/bin/cc"
168                 CCOBJ="/opt/ansic/bin/cc"
169                 DBM="/lib/libndbm.a"
170                 LD="/bin/ld   "
171                 LEX="/opt/langtools/bin/lex"
172                 LWP_OPTMZ="-O"
173                 MT_CC="$CC"
174                 MT_CFLAGS='-D_POSIX_C_SOURCE=199506L -DAFS_PTHREAD_ENV ${XCFLAGS}'
175                 MV="/bin/mv"
176                 OPTMZ="-O"
177                 PAM_CFLAGS="+DA1.0 +z -Wl,+k"
178                 PAM_LIBS="/usr/lib/libpam.1"
179                 RANLIB="/usr/bin/ranlib"
180                 RM="/bin/rm"
181                 SHLIB_LDFLAGS="-b -Bsymbolic"
182                 SHLIB_SUFFIX="sl"
183                 VFSCK_CFLAGS="-I/usr/old/usr/include -D_FILE64"
184                 XCFLAGS0="-ldld -lc -Wp,-H200000 -Wl,-a,archive -DAUTH_DBM_LOG +z -Wl,+k -D_LARGEFILE64_SOURCE"
185                 XCFLAGS64="${XCFLAGS0} +DA2.0W"
186                 XCFLAGS="${XCFLAGS0} +DA1.0"
187                 XLIBELFA="-lelf"
188                 #XLIBS="${LIB_AFSDB} -lnsl"
189                 YACC="/opt/langtools/bin/yacc"
190                 SHLIB_LINKER="ld -b"
191                 ;;
192
193         ia64_hpux*)
194                 AR="/usr/bin/ar"
195                 AS="/usr/ccs/bin/as"
196                 CC="/opt/ansic/bin/cc"
197                 CCOBJ="/opt/ansic/bin/cc"
198                 DBM="/lib/hpux32/libndbm.so"
199                 LD="/bin/ld   "
200                 LEX="/opt/langtools/bin/lex"
201                 LWP_OPTMZ=""
202                 MT_CC="$CC"
203                 MT_CFLAGS='-D_POSIX_C_SOURCE=199506L -DAFS_PTHREAD_ENV ${XCFLAGS}'
204                 MV="/bin/mv"
205                 OPTMZ="-O"
206                 PAM_CFLAGS="-b +z -Wl,+k"
207                 PAM_LIBS="/usr/lib/hpux32/libpam.so"
208                 RANLIB="/usr/bin/ranlib"
209                 RM="/bin/rm"
210                 SHLIB_LDFLAGS="-b -Bsymbolic"
211                 SHLIB_SUFFIX="sl"
212                 VFSCK_CFLAGS="-I/usr/old/usr/include -D_FILE64"
213                 XCFLAGS0="-ldld -lc -Wp,-H200000 -Wl,-a,archive_shared -DAUTH_DBM_LOG +z -Wl,+k -D_LARGEFILE64_SOURCE"
214                 XCFLAGS64="${XCFLAGS0} +DD64"
215                 XCFLAGS="${XCFLAGS0}"
216                 XLIBELFA="-lelf"
217                 #XLIBS="${LIB_AFSDB} -lnsl"
218                 YACC="/opt/langtools/bin/yacc"
219                 SHLIB_LINKER="ld -b"
220                 ;;
221
222         i386_fbsd_*)
223                 MT_CFLAGS='-DAFS_PTHREAD_ENV -pthread -D_REENTRANT ${XCFLAGS}'
224                 PAM_OPTMZ=-O2
225                 PAM_CFLAGS="-pipe -fPIC"
226                 SHLIB_LDFLAGS="-shared -Xlinker -x"
227                 SHLIB_LINKER="${MT_CC} -shared"
228                 XCFLAGS="-pipe"
229                 ;;
230
231         i386_dfbsd_*)
232                 MT_CFLAGS='-DAFS_PTHREAD_ENV -pthread -D_REENTRANT ${XCFLAGS}'
233                 PAM_OPTMZ=-O2
234                 PAM_CFLAGS="-pipe -fPIC"
235                 SHLIB_LDFLAGS="-shared -Xlinker -x"
236                 SHLIB_LINKER="${MT_CC} -shared"
237                 XCFLAGS="-pipe"
238                 ;;
239
240         amd64_fbsd_*)
241                 MT_CFLAGS='-DAFS_PTHREAD_ENV -pthread -D_REENTRANT ${XCFLAGS}'
242                 PAM_CFLAGS="-O2 -pipe -fPIC"
243                 SHLIB_LDFLAGS="-shared -Xlinker -x"
244                 SHLIB_LINKER="${MT_CC} -shared"
245                 XCFLAGS="-O2 -pipe -fPIC"
246                 ;;
247
248         *nbsd2*|*nbsd3*|*nbsd4*|*nbsd5*)
249                 MT_CFLAGS='-DAFS_PTHREAD_ENV -pthread -D_REENTRANT ${XCFLAGS}'
250                 PAM_OPTMZ=-O2
251                 PAM_CFLAGS="-pipe -fPIC"
252                 SHLIB_CFLAGS="-fPIC"
253                 SHLIB_LDFLAGS="-shared -Xlinker -x"
254                 SHLIB_LINKER="${MT_CC} -shared"
255                 XCFLAGS="-pipe"
256                 ;;
257
258         *nbsd15|*nbsd16)
259                 MT_CFLAGS='${XCFLAGS}'
260                 MT_LIBS="${XLIBS}"
261                 PAM_OPTMZ=-O2
262                 PAM_CFLAGS="-pipe -fPIC"
263                 SHLIB_LDFLAGS="-shared -Xlinker -x"
264                 SHLIB_LINKER="${MT_CC} -shared"
265                 XCFLAGS="-pipe"
266                 ;;
267
268         ia64_linux24|ia64_linux26)
269                 KERN_OPTMZ=-O2
270                 MT_CFLAGS='-DAFS_PTHREAD_ENV -pthread -D_REENTRANT ${XCFLAGS}'
271                 PAM_OPTMZ=-O2
272                 PAM_CFLAGS="-Dlinux -DLINUX_PAM -fPIC"
273                 SHLIB_CFLAGS="-fPIC"
274                 SHLIB_LDFLAGS="-shared -Xlinker -x"
275                 XCFLAGS="-D_LARGEFILE64_SOURCE -G0"
276                 SHLIB_LINKER="${MT_CC} -shared"
277                 ;;
278
279         amd64_linux*)
280                 CCOBJ="${CC} -fPIC"
281                 KERN_OPTMZ=-O2
282                 MT_CFLAGS='-DAFS_PTHREAD_ENV -pthread -D_REENTRANT ${XCFLAGS}'
283                 PAM_OPTMZ=-O2
284                 PAM_CFLAGS="-Dlinux -DLINUX_PAM -fPIC"
285                 SHLIB_CFLAGS="-fPIC"
286                 SHLIB_LDFLAGS="-shared -Xlinker -x"
287                 XCFLAGS="-D_LARGEFILE64_SOURCE"
288                 SHLIB_LINKER="${MT_CC} -shared"
289                 ;;
290
291         ppc64_linux24)
292                 KERN_OPTMZ=-O2
293                 MT_CFLAGS='-DAFS_PTHREAD_ENV -pthread -D_REENTRANT ${XCFLAGS}'
294                 PAM_OPTMZ=-O2
295                 PAM_CFLAGS="-Dlinux -DLINUX_PAM -fPIC"
296                 SHLIB_LDFLAGS="-shared -Xlinker -x"
297                 SHLIB_CFLAGS="-fPIC"
298                 XCFLAGS="-D_LARGEFILE64_SOURCE"
299                 SHLIB_LINKER="${MT_CC} -shared"
300                 ;;
301
302         ppc64_linux26)
303                 KERN_OPTMZ=-O2
304                 MT_CFLAGS='-DAFS_PTHREAD_ENV -pthread -D_REENTRANT ${XCFLAGS}'
305                 PAM_OPTMZ=-O2
306                 PAM_CFLAGS="-Dlinux -DLINUX_PAM -fPIC"
307                 SHLIB_LDFLAGS="-shared -Xlinker -x"
308                 SHLIB_CFLAGS="-fPIC"
309                 XCFLAGS="-D_LARGEFILE64_SOURCE -fPIC"
310                 SHLIB_LINKER="${MT_CC} -shared"
311                 ;;
312
313         i386_umlinux22)
314                 KERN_OPTMZ=-O2
315                 MT_CFLAGS='-DAFS_PTHREAD_ENV -pthread -D_REENTRANT ${XCFLAGS}'
316                 PAM_OPTMZ=-O2
317                 PAM_CFLAGS="-Dlinux -DLINUX_PAM -fPIC"
318                 SHLIB_CFLAGS="-fPIC"
319                 SHLIB_LDFLAGS="-shared -Xlinker -x"
320                 XCFLAGS="-D_LARGEFILE64_SOURCE"
321                 SHLIB_LINKER="${MT_CC} -shared"
322                 ;;
323
324         i386_linux*)
325                 KERN_OPTMZ=-O2
326                 MT_CFLAGS='-DAFS_PTHREAD_ENV -pthread -D_REENTRANT ${XCFLAGS}'
327                 DBG=-g
328                 KERN_DBG=-g
329                 LWP_DBG=-g
330                 LWP_OPTMZ=-O2
331                 OPTMZ=-O2
332                 PAM_CFLAGS="-Dlinux -DLINUX_PAM -fPIC"
333                 SHLIB_CFLAGS="-fPIC"
334                 SHLIB_LDFLAGS="-shared -Xlinker -x"
335                 XCFLAGS="-D_LARGEFILE64_SOURCE"
336                 SHLIB_LINKER="${MT_CC} -shared"
337                 ;;
338
339         i386_umlinux24)
340                 KERN_OPTMZ=-O2
341                 MT_CFLAGS='-DAFS_PTHREAD_ENV -pthread -D_REENTRANT ${XCFLAGS}'
342                 DBG=-g
343                 KERN_DBG=-g
344                 LWP_DBG=-g
345                 LWP_OPTMZ=-O2
346                 OPTMZ=-O2
347                 PAM_OPTMZ=-O2
348                 PAM_CFLAGS="-Dlinux -DLINUX_PAM -fPIC"
349                 SHLIB_CFLAGS="-fPIC"
350                 SHLIB_LDFLAGS="-shared -Xlinker -x"
351                 XCFLAGS="-D_LARGEFILE64_SOURCE"
352                 SHLIB_LINKER="${MT_CC} -shared"
353                 ;;
354
355         i386_umlinux26)
356                 KERN_OPTMZ=-O2
357                 MT_CFLAGS='-DAFS_PTHREAD_ENV -pthread -D_REENTRANT ${XCFLAGS}'
358                 DBG=-g
359                 KERN_DBG=-g
360                 LWP_DBG=-g
361                 LWP_OPTMZ=-O2
362                 OPTMZ=-O2
363                 PAM_OPTMZ=-O2
364                 PAM_CFLAGS="-Dlinux -DLINUX_PAM -fPIC"
365                 SHLIB_CFLAGS="-fPIC"
366                 SHLIB_LDFLAGS="-shared -Xlinker -x"
367                 XCFLAGS="-D_LARGEFILE64_SOURCE"
368                 SHLIB_LINKER="${MT_CC} -shared"
369                 ;;
370
371         *_obsd*)
372                 MT_CFLAGS='-DAFS_PTHREAD_ENV -pthread -D_REENTRANT ${XCFLAGS}'
373                 PAM_OPTMZ=-O2
374                 PAM_CFLAGS="-pipe -fpic"
375                 SHLIB_CFLAGS="-fpic"
376                 SHLIB_LDFLAGS="-shared -Xlinker -x"
377                 SHLIB_LINKER="${MT_CC} -shared"
378                 XCFLAGS=
379                 ;;
380
381         parisc_linux24)
382                 KERN_OPTMZ=-O2
383                 MT_CFLAGS='-DAFS_PTHREAD_ENV -pthread -D_REENTRANT ${XCFLAGS}'
384                 PAM_OPTMZ=-O2
385                 PAM_CFLAGS="-Dlinux -DLINUX_PAM -fPIC"
386                 SHLIB_CFLAGS="-fPIC"
387                 SHLIB_LDFLAGS="-shared -Xlinker -x"
388                 XCFLAGS="-D_LARGEFILE64_SOURCE"
389                 SHLIB_LINKER="${MT_CC} -shared"
390                 ;;
391
392         ppc_darwin_70)
393                 CC="cc"
394                 CCOBJ="cc"
395                 MT_CC="cc"
396                 AFSD_LDFLAGS="-F/System/Library/PrivateFrameworks -framework DiskArbitration -framework SystemConfiguration -framework IOKit -framework CoreFoundation"
397                 MT_CFLAGS='-DAFS_PTHREAD_ENV -D_REENTRANT ${XCFLAGS}'
398                 KROOT=
399                 KINCLUDES='-I$(KROOT)/System/Library/Frameworks/Kernel.framework/Headers'
400                 LWP_OPTMZ="-O2"
401                 REGEX_OBJ="regex.o"
402                 XCFLAGS="-no-cpp-precomp"
403                 EXTRA_VLIBOBJS="fstab.o"
404                 SHLIB_LINKER="${MT_CC} ${ARCHFLAGS} -dynamiclib"
405                 SHLIB_SUFFIX="dylib"
406                 XLIBS="${LIB_AFSDB} ${XBSA_XLIBS} -framework CoreFoundation"
407                 ;;
408
409         *_darwin_80)
410                 CC="cc"
411                 CCOBJ="cc"
412                 MT_CC="cc"
413                 AFSD_LDFLAGS="-F/System/Library/PrivateFrameworks -framework DiskArbitration -framework SystemConfiguration -framework IOKit -framework CoreFoundation"
414                 MT_CFLAGS='-DAFS_PTHREAD_ENV -D_REENTRANT ${XCFLAGS} ${ARCHFLAGS}'
415                 KROOT=
416                 KINCLUDES='-I$(KROOT)/System/Library/Frameworks/Kernel.framework/Headers'
417                 KERN_OPTMZ="-Os"
418                 LWP_OPTMZ="-Os"
419                 OPTMZ="-Os"
420                 REGEX_OBJ="regex.o"
421                 EXTRA_VLIBOBJS="fstab.o"
422                 SHLIB_LINKER="${MT_CC} ${ARCHFLAGS} -dynamiclib"
423                 SHLIB_SUFFIX="dylib"
424                 RANLIB="ranlib -c"
425                 XLIBS="${LIB_AFSDB} ${XBSA_XLIBS} -framework CoreFoundation"
426                 ;;
427
428         *_darwin_90)
429                 AFSD_LDFLAGS="-F/System/Library/PrivateFrameworks -framework DiskArbitration -framework SystemConfiguration -framework IOKit -framework CoreFoundation"
430                 MT_CFLAGS='-DAFS_PTHREAD_ENV -D_REENTRANT ${XCFLAGS} ${ARCHFLAGS}'
431                 KROOT=
432                 KINCLUDES='-I$(KROOT)/System/Library/Frameworks/Kernel.framework/Headers'
433                 LD="cc"
434                 KERN_OPTMZ="-Os"
435                 LWP_OPTMZ="-Os"
436                 OPTMZ="-Os"
437                 REGEX_OBJ="regex.o"
438                 EXTRA_VLIBOBJS="fstab.o"
439                 SHLIB_LINKER="${MT_CC} ${ARCHFLAGS} -dynamiclib"
440                 SHLIB_SUFFIX="dylib"
441                 RANLIB="ranlib -c"
442                 XLIBS="${LIB_AFSDB} ${XBSA_XLIBS} -framework CoreFoundation"
443                 ;;
444
445         *_darwin_100)
446                 AFSD_LDFLAGS="-F/System/Library/PrivateFrameworks -framework DiskArbitration -framework SystemConfiguration -framework IOKit -framework CoreFoundation"
447                 MT_CFLAGS='-DAFS_PTHREAD_ENV -D_REENTRANT ${XCFLAGS} ${ARCHFLAGS}'
448                 MT_LIBS="${XLIBS}"
449                 KROOT=
450                 KINCLUDES='-I$(KROOT)/System/Library/Frameworks/Kernel.framework/Headers'
451                 LD="cc"
452                 KERN_OPTMZ="-Os"
453                 LWP_OPTMZ="-Os"
454                 OPTMZ="-Os"
455                 PAM_LIBS="-lpam"
456                 REGEX_OBJ="regex.o"
457                 EXTRA_VLIBOBJS="fstab.o"
458                 SHLIB_LINKER="${MT_CC} ${ARCHFLAGS} -dynamiclib"
459                 SHLIB_SUFFIX="dylib"
460                 RANLIB="ranlib"
461                 XLIBS="${LIB_AFSDB} ${XBSA_XLIBS} -framework CoreFoundation"
462                 ;;
463
464         ppc_linux*)
465                 KERN_OPTMZ=-O2
466                 MT_CFLAGS='-DAFS_PTHREAD_ENV -pthread -D_REENTRANT ${XCFLAGS}'
467                 PAM_OPTMZ=-O2
468                 PAM_CFLAGS="-Dlinux -DLINUX_PAM -fPIC"
469                 SHLIB_CFLAGS="-fPIC"
470                 SHLIB_LDFLAGS="-shared -Xlinker -x"
471                 XCFLAGS="-D_LARGEFILE64_SOURCE"
472                 SHLIB_LINKER="${MT_CC} -shared"
473                 ;;
474
475         rs_aix42)
476                 CC="cc"
477                 CCOBJ="cc"
478                 DBG=""
479                 LIBSYS_AIX_EXP="afsl.exp"
480                 MT_CC="xlc_r"
481                 MT_CFLAGS='-DAFS_PTHREAD_ENV ${XCFLAGS}'
482                 SHLIB_SUFFIX="o"
483                 XCFLAGS="-K -D_NONSTD_TYPES -D_MBI=void"
484                 XLIBS="${LIB_AFSDB} ${LIB_libintl} -ldl"
485                 SHLIB_LINKER="${MT_CC} -bM:SRE -berok"
486                 AIX32=""
487                 AIX64="#"
488                 ;;
489
490
491         rs_aix51)
492                 CC="cc"
493                 CCOBJ="cc"
494                 DBG=""
495                 LIBSYS_AIX_EXP="afsl.exp"
496                 MT_CC="xlc_r"
497                 MT_CFLAGS='-DAFS_PTHREAD_ENV ${XCFLAGS}'
498                 SHLIB_SUFFIX="o"
499                 XCFLAGS="-K -D_NONSTD_TYPES -D_MBI=void"
500                 XLIBS="${LIB_AFSDB} ${LIB_libintl} -ldl"
501                 SHLIB_LINKER="${MT_CC} -bM:SRE -berok"
502                 AIX32=""
503                 AIX64=""
504                 ;;
505
506         rs_aix52)       
507                 CC="cc"
508                 CCOBJ="cc"
509                 DBG=""
510                 LIBSYS_AIX_EXP="afsl.exp"
511                 MT_CC="xlc_r"
512                 MT_CFLAGS='-DAFS_PTHREAD_ENV ${XCFLAGS}'
513                 SHLIB_SUFFIX="o"
514                 XCFLAGS="-K -D_NONSTD_TYPES -D_MBI=void"
515                 XLIBS="${LIB_AFSDB} ${LIB_libintl} -ldl"
516                 SHLIB_LINKER="${MT_CC} -bM:SRE -berok"
517                 AIX32=""
518                 AIX64=""
519                 ;;
520
521         rs_aix53)       
522                 CC="cc"
523                 CCOBJ="cc"
524                 DBG="-g"
525                 LIBSYS_AIX_EXP="afsl.exp"
526                 MT_CC="xlc_r"
527                 MT_CFLAGS='-DAFS_PTHREAD_ENV ${XCFLAGS}'
528                 SHLIB_SUFFIX="o"
529                 XCFLAGS="-K -D_NONSTD_TYPES -D_MBI=void"
530                 XLIBS="${LIB_AFSDB} ${LIB_libintl} -ldl"
531                 SHLIB_LINKER="${MT_CC} -bM:SRE -berok"
532                 AIX32=""
533                 AIX64=""
534                 ;;
535
536         rs_aix61)       
537                 CC="cc"
538                 CCOBJ="cc"
539                 DBG="-g"
540                 LIBSYS_AIX_EXP="afsl.exp"
541                 MT_CC="xlc_r"
542                 MT_CFLAGS='-DAFS_PTHREAD_ENV ${XCFLAGS}'
543                 SHLIB_SUFFIX="o"
544                 XCFLAGS="-K -D_NONSTD_TYPES -D_MBI=void"
545                 XLIBS="${LIB_AFSDB} ${LIB_libintl} -ldl"
546                 SHLIB_LINKER="${MT_CC} -bM:SRE -berok"
547                 AIX32="#"
548                 AIX64=""
549                 ;;
550
551         s390_linux22)
552                 LD="ld"
553                 KERN_OPTMZ=-O2
554                 MT_CC="$CC"
555                 MT_CFLAGS='-DAFS_PTHREAD_ENV -pthread -D_REENTRANT ${XCFLAGS}'
556                 PAM_OPTMZ=-O
557                 PAM_CFLAGS="-Dlinux -DLINUX_PAM -fPIC"
558                 SHLIB_CFLAGS="-fPIC"
559                 SHLIB_LDFLAGS="-shared -Xlinker -x"
560                 OPTMZ=-O
561                 XCFLAGS="-D_LARGEFILE64_SOURCE"
562                 SHLIB_LINKER="${MT_CC} -shared"
563                 ;;
564
565         s390_linux24|s390_linux26)
566                 LD="ld"
567                 KERN_OPTMZ=-O2
568                 MT_CC="$CC"
569                 MT_CFLAGS='-DAFS_PTHREAD_ENV -pthread -D_REENTRANT ${XCFLAGS}'
570                 PAM_OPTMZ=-O2
571                 PAM_CFLAGS="-Dlinux -DLINUX_PAM -fPIC"
572                 SHLIB_CFLAGS="-fPIC"
573                 SHLIB_LDFLAGS="-shared -Xlinker -x"
574                 XCFLAGS="-D_LARGEFILE64_SOURCE"
575                 SHLIB_LINKER="${MT_CC} -shared"
576                 ;;
577
578         s390x_linux24|s390x_linux26)
579                 CCOBJ="${CC} -fPIC"
580                 LD="ld"
581                 KERN_OPTMZ=-O2
582                 MT_CC="$CC"
583                 MT_CFLAGS='-DAFS_PTHREAD_ENV -pthread -D_REENTRANT ${XCFLAGS}'
584                 PAM_OPTMZ=-O
585                 PAM_CFLAGS="-Dlinux -DLINUX_PAM -fPIC"
586                 SHLIB_CFLAGS="-fPIC"
587                 SHLIB_LDFLAGS="-shared -Xlinker -x -Xlinker -Bsymbolic"
588                 OPTMZ=-O
589                 XCFLAGS="-D_LARGEFILE64_SOURCE -D__s390x__"
590                 SHLIB_LINKER="${MT_CC} -shared"
591                 ;;
592
593         sgi_62)
594                 CC="cc"
595                 CCOBJ="cc"
596                 MT_CC="cc"
597                 AFSD_LIBS="/usr/lib/libdwarf.a /usr/lib/libelf.a"
598                 FSINCLUDES="-I/usr/include/sys/fs"
599                 MT_CFLAGS='-D_SGI_MP_SOURCE -DAFS_PTHREAD_ENV ${XCFLAGS}'
600                 XCFLAGS64="-64 -mips3"
601                 XCFLAGS="-o32"
602                 XLDFLAGS64="-64"
603                 XLDFLAGS="-o32"
604                 SHLIB_LINKER="${CC} -shared"
605                 ;;
606
607         sgi_63)
608                 CC="cc"
609                 CCOBJ="cc"
610                 MT_CC="cc"
611                 AFSD_LIBS="/usr/lib/libdwarf.a /usr/lib/libelf.a"
612                 FSINCLUDES="-I/usr/include/sys/fs"
613                 MT_CFLAGS='-D_SGI_MP_SOURCE -DAFS_PTHREAD_ENV ${XCFLAGS}'
614                 XCFLAGS64="-D_BSD_COMPAT -64 -mips3"
615                 XCFLAGS="-D_OLD_TERMIOS -D_BSD_COMPAT -o32"
616                 XLDFLAGS64="-64"
617                 XLDFLAGS="-o32"
618                 SHLIB_LINKER="${CC} -shared"
619                 ;;
620
621         sgi_64)
622                 CC="cc"
623                 CCOBJ="cc"
624                 MT_CC="cc"
625                 AFSD_LIBS="/usr/lib32/libdwarf.a /usr/lib32/libelf.a"
626                 FSINCLUDES="-I/usr/include/sys/fs"
627                 MT_CFLAGS='-D_SGI_MP_SOURCE -DAFS_PTHREAD_ENV ${XCFLAGS}'
628                 XCFLAGS64="-D_BSD_COMPAT -64 -mips3"
629                 XCFLAGS="-D_OLD_TERMIOS -D_BSD_COMPAT -n32 -woff 1009,1014,1110,1116,1164,1169,1171,1174,1177,1183,1185,1204,1233,1515,1516,1548,1169,1174,1177,1196,1498,1506,1552,3201 -Wl,-woff,84,-woff,15"
630                 XLDFLAGS64="-64"
631                 XLDFLAGS="-n32"
632                 SHLIB_LINKER="${CC} -shared"
633                 ;;
634
635         sgi_65)
636                 AFSD_LIBS="/usr/lib32/libdwarf.a /usr/lib32/libelf.a"
637                 CC="/usr/bin/cc"
638                 CCOBJ="/usr/bin/cc"
639                 FSINCLUDES="-I/usr/include/sys/fs"
640                 LD="/usr/bin/ld"
641                 MT_CC="/usr/bin/cc"
642                 MT_CFLAGS='-D_SGI_MP_SOURCE -DAFS_PTHREAD_ENV ${XCFLAGS}'
643                 XCFLAGS64="-64 -mips3"
644                 XCFLAGS="-n32 -mips3 -woff 1009,1014,1110,1116,1164,1171,1177,1183,1185,1204,1233,1515,1516,1548,1169,1174,1177,1196,1498,1506,1552,3201 -Wl,-woff,84,-woff,15"
645                 XLDFLAGS64="-64 -mips3"
646                 XLDFLAGS="-n32 -mips3"
647                 SHLIB_LINKER="${CC} -shared"
648                 ;;
649
650         sparc*_linux*)
651                 KERN_OPTMZ=-O2
652                 MT_CFLAGS='-DAFS_PTHREAD_ENV -pthread -D_REENTRANT ${XCFLAGS}'
653                 PAM_OPTMZ=-O2
654                 PAM_CFLAGS="-Dlinux -DLINUX_PAM -fPIC"
655                 SHLIB_CFLAGS="-fPIC"
656                 SHLIB_LDFLAGS="-shared -Xlinker -x"
657                 XCFLAGS="-D_LARGEFILE64_SOURCE"
658                 XCFLAGS64="-D_LARGEFILE64_SOURCE -m64"
659                 XLDFLAGS64="-m64"
660                 SHLIB_LINKER="${MT_CC} -shared"
661                 ;;
662
663         sun4_413)
664                 CCXPG2="/usr/xpg2bin/cc"
665                 CC="gcc"
666                 CCOBJ="gcc"
667                 SHLIB_CFLAGS="-PIC"
668                 XCFLAGS=""
669                 XLIBELFA="-lelf"
670                 XLIBKVM="-lkvm"
671                 XLIBS="${LIB_AFSDB}"
672                 LD="ld"
673                 ;;
674
675         sun4x_55)
676                 CC=$SOLARISCC
677                 CCOBJ=$SOLARISCC
678                 MT_CC=$SOLARISCC
679                 MT_CFLAGS='-mt -DAFS_PTHREAD_ENV ${XCFLAGS}'
680                 SHLIB_CFLAGS="-KPIC"
681                 XCFLAGS="-dy -Bdynamic"
682                 XLIBELFA="-lelf"
683                 XLIBKVM="-lkvm"
684                 XLIBS="${LIB_AFSDB} -lsocket -lnsl -lintl -ldl"
685                 LD="/usr/ccs/bin/ld"
686                 SHLIB_LINKER="${CC} -G -dy -Bsymbolic -z text"
687                 LWP_OPTMZ="-g"
688                 ;;
689
690         sun4x_56)
691                 CC=$SOLARISCC
692                 CCOBJ=$SOLARISCC
693                 MT_CC=$SOLARISCC
694                 MT_CFLAGS='-mt -DAFS_PTHREAD_ENV ${XCFLAGS}'
695                 PAM_CFLAGS="-KPIC"
696                 PAM_LIBS="-lc -lpam -lsocket -lnsl -lm"
697                 SHLIB_CFLAGS="-KPIC"
698                 SHLIB_LDFLAGS="-G -Bsymbolic"
699                 XCFLAGS="-dy -Bdynamic"
700                 XLIBELFA="-lelf"
701                 LD="/usr/ccs/bin/ld"
702                 XLIBKVM="-lkvm"
703                 XLIBS="${LIB_AFSDB} -lsocket -lnsl -lintl -ldl"
704                 SHLIB_LINKER="${CC} -G -dy -Bsymbolic -z text"
705                 LWP_OPTMZ="-g"
706                 ;;
707
708         sun4x_57)
709                 CC=$SOLARISCC
710                 CCOBJ=$SOLARISCC
711                 LD="/usr/ccs/bin/ld"
712                 MT_CC=$SOLARISCC
713                 MT_CFLAGS='-mt -DAFS_PTHREAD_ENV ${XCFLAGS}'
714                 PAM_CFLAGS="-KPIC"
715                 PAM_LIBS="-lc -lpam -lsocket -lnsl -lm"
716                 SHLIB_CFLAGS="-KPIC"
717                 SHLIB_LDFLAGS="-G -Bsymbolic"
718                 XCFLAGS64='${XCFLAGS} -xarch=v9'
719                 XCFLAGS="-dy -Bdynamic"
720                 XLIBELFA="-lelf"
721                 XLIBKVM="-lkvm"
722                 XLIBS="${LIB_AFSDB} -lsocket -lnsl -lintl -ldl"
723                 SHLIB_LINKER="${CC} -G -dy -Bsymbolic -z text"
724                 LWP_OPTMZ="-g"
725                 ;;
726
727         sun4x_58)
728                 CC=$SOLARISCC
729                 CCOBJ=$SOLARISCC
730                 LD="/usr/ccs/bin/ld"
731                 MT_CC=$SOLARISCC
732                 MT_CFLAGS='-mt -DAFS_PTHREAD_ENV ${XCFLAGS}'
733                 PAM_CFLAGS="-KPIC"
734                 PAM_LIBS="-lc -lpam -lsocket -lnsl -lm"
735                 SHLIB_CFLAGS="-KPIC"
736                 SHLIB_LDFLAGS="-G -Bsymbolic"
737                 XCFLAGS64='${XCFLAGS} -xarch=v9'
738                 XCFLAGS="-dy -Bdynamic"
739                 XLIBELFA="-lelf"
740                 XLIBKVM="-lkvm"
741                 XLIBS="${LIB_AFSDB} -lsocket -lnsl -lintl -ldl"
742                 SHLIB_LINKER="${CC} -G -dy -Bsymbolic -z text"
743                 LWP_OPTMZ="-g"
744                 ;;
745
746         sun4x_59)
747                 CC=$SOLARISCC
748                 CCOBJ=$SOLARISCC
749                 LD="/usr/ccs/bin/ld"
750                 MT_CC=$SOLARISCC
751                 MT_CFLAGS='-mt -DAFS_PTHREAD_ENV ${XCFLAGS}'
752                 PAM_CFLAGS="-KPIC"
753                 PAM_LIBS="-lc -lpam -lsocket -lnsl -lm"
754                 SHLIB_CFLAGS="-KPIC"
755                 SHLIB_LDFLAGS="-G -Bsymbolic"
756                 XCFLAGS64='${XCFLAGS} -xarch=v9'
757                 XCFLAGS="-dy -Bdynamic"
758                 XLIBELFA="-lelf"
759                 XLIBKVM="-lkvm"
760                 XLIBS="${LIB_AFSDB} -lsocket -lnsl -lintl -ldl"
761                 SHLIB_LINKER="${CC} -G -dy -Bsymbolic -z text"
762                 LWP_OPTMZ="-g"
763                 ;;
764
765         sun4x_510)
766                 CC=$SOLARISCC
767                 CCOBJ=$SOLARISCC
768                 LD="/usr/ccs/bin/ld"
769                 MT_CC=$SOLARISCC
770                 MT_CFLAGS='-mt -DAFS_PTHREAD_ENV ${XCFLAGS}'
771                 PAM_CFLAGS="-KPIC"
772                 PAM_LIBS="-lc -lpam -lsocket -lnsl -lm"
773                 SHLIB_CFLAGS="-KPIC"
774                 SHLIB_LDFLAGS="-G -Bsymbolic"
775                 XCFLAGS64='${XCFLAGS} -m64'
776                 XCFLAGS="-dy -Bdynamic"
777                 XLIBELFA="-lelf"
778                 XLIBKVM="-lkvm"
779                 XLIBS="${LIB_AFSDB} -lsocket -lnsl -lintl -ldl"
780                 SHLIB_LINKER="${CC} -G -dy -Bsymbolic -z text"
781                 LWP_OPTMZ="-g"
782                 ;;
783
784         sun4x_511)
785                 CC=$SOLARISCC
786                 CCOBJ=$SOLARISCC
787                 LD="/usr/ccs/bin/ld"
788                 MT_CC=$SOLARISCC
789                 MT_CFLAGS='-mt -DAFS_PTHREAD_ENV ${XCFLAGS}'
790                 PAM_CFLAGS="-KPIC"
791                 PAM_LIBS="-lc -lpam -lsocket -lnsl -lm"
792                 SHLIB_CFLAGS="-KPIC"
793                 SHLIB_LDFLAGS="-G -Bsymbolic"
794                 XCFLAGS64='${XCFLAGS} -xarch=v9'
795                 XCFLAGS="-dy -Bdynamic"
796                 XLIBELFA="-lelf"
797                 XLIBKVM="-lkvm"
798                 XLIBS="${LIB_AFSDB} -lsocket -lnsl -lintl -ldl"
799                 SHLIB_LINKER="${CC} -G -dy -Bsymbolic -z text"
800                 LWP_OPTMZ="-g"
801                 ;;
802
803         sunx86_57)
804                 CC=$SOLARISCC
805                 CCOBJ=$SOLARISCC
806                 LD="/usr/ccs/bin/ld"
807                 MT_CC=$SOLARISCC
808                 MT_CFLAGS='-mt -DAFS_PTHREAD_ENV ${XCFLAGS}'
809                 PAM_CFLAGS="-KPIC"
810                 PAM_LIBS="-lc -lpam -lsocket -lnsl -lm"
811                 SHLIB_CFLAGS="-KPIC"
812                 SHLIB_LDFLAGS="-G -Bsymbolic"
813                 XCFLAGS64='${XCFLAGS} -xarch=amd64'
814                 XCFLAGS="-dy -Bdynamic"
815                 XLIBELFA="-lelf"
816                 XLIBKVM="-lkvm"
817                 XLIBS="${LIB_AFSDB} -lsocket -lnsl -lintl -ldl"
818                 SHLIB_LINKER="${CC} -G -dy -Bsymbolic -z text"
819                 ;;
820
821         sunx86_58)
822                 CC=$SOLARISCC
823                 CCOBJ=$SOLARISCC
824                 LD="/usr/ccs/bin/ld"
825                 MT_CC=$SOLARISCC
826                 MT_CFLAGS='-mt -DAFS_PTHREAD_ENV ${XCFLAGS}'
827                 PAM_CFLAGS="-KPIC"
828                 PAM_LIBS="-lc -lpam -lsocket -lnsl -lm"
829                 SHLIB_CFLAGS="-KPIC"
830                 SHLIB_LDFLAGS="-G -Bsymbolic"
831                 XCFLAGS64='${XCFLAGS} -xarch=amd64'
832                 XCFLAGS="-dy -Bdynamic"
833                 XLIBELFA="-lelf"
834                 XLIBKVM="-lkvm"
835                 XLIBS="${LIB_AFSDB} -lsocket -lnsl -lintl -ldl"
836                 SHLIB_LINKER="${CC} -G -dy -Bsymbolic -z text"
837                 ;;
838
839         sunx86_59)
840                 CC=$SOLARISCC
841                 CCOBJ=$SOLARISCC
842                 LD="/usr/ccs/bin/ld"
843                 MT_CC=$SOLARISCC
844                 MT_CFLAGS='-mt -DAFS_PTHREAD_ENV ${XCFLAGS}'
845                 PAM_CFLAGS="-KPIC"
846                 PAM_LIBS="-lc -lpam -lsocket -lnsl -lm"
847                 SHLIB_CFLAGS="-KPIC"
848                 SHLIB_LDFLAGS="-G -Bsymbolic"
849                 XCFLAGS64='${XCFLAGS} -xarch=amd64'
850                 XCFLAGS="-dy -Bdynamic"
851                 XLIBELFA="-lelf"
852                 XLIBKVM="-lkvm"
853                 XLIBS="${LIB_AFSDB} -lsocket -lnsl -lintl -ldl"
854                 SHLIB_LINKER="${CC} -G -dy -Bsymbolic -z text"
855                 ;;
856
857         sunx86_510)
858                 CC=$SOLARISCC
859                 CCOBJ=$SOLARISCC
860                 LD="/usr/ccs/bin/ld"
861                 MT_CC=$SOLARISCC
862                 MT_CFLAGS='-mt -DAFS_PTHREAD_ENV ${XCFLAGS}'
863                 PAM_CFLAGS="-KPIC"
864                 PAM_LIBS="-lc -lpam -lsocket -lnsl -lm"
865                 SHLIB_CFLAGS="-KPIC"
866                 SHLIB_LDFLAGS="-G -Bsymbolic"
867                 XCFLAGS64='${XCFLAGS} -m64'
868                 XCFLAGS="-dy -Bdynamic"
869                 XLIBELFA="-lelf"
870                 XLIBKVM="-lkvm"
871                 XLIBS="${LIB_AFSDB} -lsocket -lnsl -lintl -ldl"
872                 SHLIB_LINKER="${CC} -G -dy -Bsymbolic -z text"
873                 ;;
874
875         sunx86_511)
876                 CC=$SOLARISCC
877                 CCOBJ=$SOLARISCC
878                 LD="/usr/ccs/bin/ld"
879                 MT_CC=$SOLARISCC
880                 MT_CFLAGS='-mt -DAFS_PTHREAD_ENV ${XCFLAGS}'
881                 PAM_CFLAGS="-KPIC"
882                 PAM_LIBS="-lc -lpam -lsocket -lnsl -lm"
883                 SHLIB_CFLAGS="-KPIC"
884                 SHLIB_LDFLAGS="-G -Bsymbolic"
885                 XCFLAGS64='${XCFLAGS} -xarch=amd64'
886                 XCFLAGS="-dy -Bdynamic"
887                 XLIBELFA="-lelf"
888                 XLIBKVM="-lkvm"
889                 XLIBS="${LIB_AFSDB} -lsocket -lnsl -lintl -ldl"
890                 SHLIB_LINKER="${CC} -G -dy -Bsymbolic -z text"
891                 ;;
892 esac
893
894 #
895 # Special build targets
896 #
897 case $AFS_SYSNAME in
898         sgi_6*)
899                 IRIX_SYS_SYSTM_H_HAS_MEM_FUNCS
900                 XFS_SIZE_CHECK="xfs_size_check"
901                 install_XFS_SIZE_CHECK='$(DESTDIR)${afssrvsbindir}/xfs_size_check'
902                 dest_XFS_SIZE_CHECK='$(DEST)/root.server/usr/afs/bin/xfs_size_check'
903         
904                 AC_SUBST(XFS_SIZE_CHECK)
905                 AC_SUBST(install_XFS_SIZE_CHECK)
906                 AC_SUBST(dest_XFS_SIZE_CHECK)
907         ;;
908 esac
909
910 dnl Disable the default for debugging/optimization if not enabled
911 if test "x$enable_debug_kernel" = "xno"; then
912   KERN_DBG=
913 fi
914
915 if test "x$enable_optimize_kernel" = "xno"; then
916   KERN_OPTMZ=
917 fi
918
919 if test "x$enable_debug" = "xno"; then
920   DBG=
921   NO_STRIP_BIN=-s
922 fi
923
924 if test "x$enable_optimize" = "xno"; then
925   OPTMZ=
926 fi
927
928 if test "x$enable_debug_lwp" = "xno"; then
929   LWP_DBG=
930 fi
931
932 if test "x$enable_optimize_lwp" = "xno"; then
933   LWP_OPTMZ=
934 fi
935
936 if test "x$enable_strip_binaries" != "xno"; then
937   if test "x$enable_strip_binaries" = "xmaybe" -a "x$enable_debug" = "xyes"; then
938     NO_STRIP_BIN=
939   else
940     NO_STRIP_BIN=-s
941   fi
942 else
943   NO_STRIP_BIN=
944 fi
945
946 CFLAGS_NOERROR=
947 CFLAGS_NOSTRICT=
948 CFLAGS_NOUNUSED=
949 CFLAGS_NOOLDSTYLE=
950
951 if test "x$GCC" = "xyes"; then
952   if test "x$enable_warnings" = "xyes"; then
953     XCFLAGS="${XCFLAGS} -Wall -Wstrict-prototypes -Wold-style-definition -Wpointer-arith"
954   fi
955   if test "x$enable_checking" != "xno"; then
956     XCFLAGS="${XCFLAGS} -Wall -Wstrict-prototypes -Wold-style-definition -Werror -fdiagnostics-show-option -Wpointer-arith"
957     if test "x$enable_checking" != "xall"; then
958       CFLAGS_NOERROR="-Wno-error"
959       CFLAGS_NOSTRICT="-fno-strict-aliasing"
960       CFLAGS_NOUNUSED="-Wno-unused"
961       CFLAGS_NOOLDSTYLE="-Wno-old-style-definition"
962       AC_DEFINE(IGNORE_SOME_GCC_WARNINGS, 1, [define to disable some gcc warnings in warnings-as-errors mode])
963     fi
964   fi
965 else
966   case $AFS_SYSNAME in
967     sun*_51?)
968       # Solaris Studio
969       warn_common="-v -errfmt=error -errtags=yes -erroff=E_ATTRIBUTE_UNKNOWN,E_END_OF_LOOP_CODE_NOT_REACHED"
970       if test "x$enable_warnings" = "xyes" ; then
971         XCFLAGS="${XCFLAGS} $warn_common"
972       fi
973       if test "x$enable_checking" != "xno" ; then
974         XCFLAGS="${XCFLAGS} $warn_common -errwarn=%all"
975         if test "x$enable_checking" != "xall" ; then
976           CFLAGS_NOERROR="-errwarn=%none"
977         fi
978       fi
979       ;;
980   esac
981 fi
982
983 dnl horribly cheating, assuming double / is ok.
984 case $INSTALL in
985   ./* ) 
986     INSTALL="/@abs_top_srcdir@/install-sh -c"
987   ;;
988   *) 
989   ;;
990 esac
991
992 INSTALL_PROGRAM="${INSTALL_PROGRAM} ${NO_STRIP_BIN}"
993
994 AC_SUBST(CCXPG2)
995 AC_SUBST(CCOBJ)
996 AC_SUBST(AFSD_LIBS)
997 AC_SUBST(AFSD_LDFLAGS)
998 AC_SUBST(AIX32)
999 AC_SUBST(AIX64)
1000 AC_SUBST(AR)
1001 AC_SUBST(AS)
1002 AC_SUBST(CP)
1003 AC_SUBST(DBG)
1004 AC_SUBST(FSINCLUDES)
1005 AC_SUBST(KERN_DBG)
1006 AC_SUBST(KERN_OPTMZ)
1007 AC_SUBST(LD)
1008 AC_SUBST(LEX)
1009 AC_SUBST(LWP_DBG)
1010 AC_SUBST(LWP_OPTMZ)
1011 AC_SUBST(MT_CC)
1012 AC_SUBST(MT_CFLAGS)
1013 AC_SUBST(MT_LIBS)
1014 AC_SUBST(MV)
1015 AC_SUBST(NO_STRIP_BIN)
1016 AC_SUBST(OPTMZ)
1017 AC_SUBST(PAM_CFLAGS)
1018 AC_SUBST(PAM_LIBS)
1019 AC_SUBST(PAM_DBG)
1020 AC_SUBST(PAM_OPTMZ)
1021 AC_SUBST(RANLIB)
1022 AC_SUBST(REGEX_OBJ)
1023 AC_SUBST(RM)
1024 AC_SUBST(RXDEBUG)
1025 AC_SUBST(SHLIB_CFLAGS)
1026 AC_SUBST(SHLIB_LDFLAGS)
1027 AC_SUBST(SHLIB_LINKER)
1028 AC_SUBST(SHLIB_SUFFIX)
1029 AC_SUBST(VFSCK_CFLAGS)
1030 AC_SUBST(XCFLAGS)
1031 AC_SUBST(CFLAGS_NOERROR)
1032 AC_SUBST(CFLAGS_NOSTRICT)
1033 AC_SUBST(CFLAGS_NOUNUSED)
1034 AC_SUBST(CFLAGS_NOOLDSTYLE)
1035 AC_SUBST(XCFLAGS64)
1036 AC_SUBST(XLDFLAGS)
1037 AC_SUBST(XLDFLAGS64)
1038 AC_SUBST(XLIBELFA)
1039 AC_SUBST(XLIBKVM)
1040 AC_SUBST(XLIBS)
1041 AC_SUBST(YACC)
1042
1043
1044 ])