-
Notifications
You must be signed in to change notification settings - Fork 1
/
aclocal.m4
2540 lines (2374 loc) · 92.5 KB
/
aclocal.m4
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
dnl ======================================================================
dnl autoconf macros originally developed for the BBH project
dnl
dnl Copyright 1995--2001 Matthew William Choptuik
dnl The University of British Columbia
dnl and
dnl The University of Texas at Austin
dnl
dnl Please AVOID making modified versions of this file. If ammendments
dnl are necessary, send e-mail to
dnl
dnl
dnl immediately.
dnl
dnl ======================================================================
dnl NOTES:
dnl
dnl (1) April 6 2000
dnl
dnl setenv BBH_CHECK_DEFAULTS NONE
dnl
dnl will (should) inhibit use of default lib/include search locations
dnl
dnl (2) July 18 2000
dnl
dnl Following Scott Hawley's lead, will define 'CCF77LIBS' to be the
dnl standard set of libraries needed to link generic Fortran 77 code
dnl with C compiler.
dnl
dnl (3) January 27 2001
dnl
dnl Removed '-mips3' settings for SGIs
dnl
dnl (4) April 22 2001,
dnl
dnl Fixed bug whereby 'configure' invoked without explicit prefix
dnl setting results in prefix=NONE (ac_default_prefix=/usr/local)
dnl (Thanks to Reinoud Slagter for unearthing this one.)
dnl
dnl (4) May 6 2001,
dnl
dnl Added '-lm' to CCF77LIBS
dnl
dnl (5) December 1 2001
dnl
dnl Removed 'glut GLU Xmu Xi' from LIBGL settings, and added LIBGLUT
dnl
dnl (5) December 7 2001
dnl
dnl DAGH_NO_MPI environment var now sets -DACE_NO_MPI
dnl
dnl (6) July 31 2003
dnl
dnl Discovered that there is a '-fno-second-underscore' option to g77,
dnl changing defaults so that all environments use single-underscore
dnl convention, can be overridden by setting DOUBLE_UNDERSCORE, e.g.
dnl
dnl setenv DOUBLE_UNDERSCORE
dnl ======================================================================
dnl ----------------------------------------------------------------------
dnl BBH_SYS_GETSYSTEM attempts to determine what flavour of UNIX
dnl is being used
dnl ----------------------------------------------------------------------
dnl ----------------------------------------------------------------------
dnl Template for new macros
dnl ----------------------------------------------------------------------
AC_DEFUN(BBH_TEMPLATE,[
])
dnl ----------------------------------------------------------------------
dnl BBH_SYS_GETSYSTEM attempts to determine what flavour of UNIX
dnl is being used
dnl
dnl Sets Output Variable BBH_SYSTEM and possibly others, dependent on
dnl the pecularities of the given OS.
dnl
dnl Modified Nov 3 1999, to include definitions of CPPFLAGS, which
dnl DAGH/GRACE now wants.
dnl ----------------------------------------------------------------------
AC_DEFUN(BBH_SYS_GETSYSTEM,[
if test "X$BBH_SYSTEM" = "X"; then
dnl Ensure 'prefix' is sanely set
if test "X${prefix}" = "XNONE"; then
prefix=$ac_default_prefix
fi
BBH_GET_NPROC
BBH_SUBSYSTEM="NONE"
if test "$prefix" != "NONE"; then
BBH_PUSHUNIQUE(INCLUDE_PATHS,$prefix/include)
BBH_PUSHUNIQUE(LIB_PATHS,$prefix/lib)
fi
RPCGEN_CPPFLAGS=""
AC_MSG_CHECKING(for Unix flavour)
AC_CACHE_VAL(ac_cv_bbh_system,
[
changequote(,)dnl
__UNAME=`uname -a | tr '[a-z]' '[A-Z]'`
changequote([, ])dnl
for s in $__UNAME
do
case $s in
IRIX64)
dnl ----------------------------------------------------------------------
dnl Tried using this flag setting on SGI's to rationalize
dnl signal behaviour. Needs further investigation.
dnl
dnl CFLAGS="$CFLAGS -D_BSD_SIGNALS"
dnl ----------------------------------------------------------------------
dnl DAGH: Masking CXX warnings
dnl 1233
dnl 1021 (type qualifiers are meaningless in this
dnl declaration)
dnl 3262 (vbl. declared and never referenced)
dnl Disabled this as well since wasting too much time
dnl Just set CXXFLAGS to include appropriate -woff string, e.g.
dnl
dnl setenv CXXFLAGS "-woff 1233,1021,3262"
dnl setenv CXXFLAGS "$CXXFLAGS -woff 1233,1021,3262"
dnl ----------------------------------------------------------------------
dnl CXXFLAGS="$CXXFLAGS -ptused -DSGI -woff 1233,1021,3262"
dnl ----------------------------------------------------------------------
CXXFLAGS="$CXXFLAGS -ptused -DSGI"
CFLAGS="$CFLAGS -woff 1174,1178,1552"
CPPFLAGS="$CPPFLAGS -DSGI"
CXXREPOSITORY="ii_files"
dnl ----------------------------------------------------------------------
dnl Linking to Fortran 90 code via C++ will generally
dnl require '-lftn -lftn90'
dnl ----------------------------------------------------------------------
CXXF90LIBS='-lftn -lftn90'
dnl ----------------------------------------------------------------------
dnl For linkage to Fortran 77 code via C
dnl ----------------------------------------------------------------------
if test "X$CCF77LIBS" = "X"; then
CCF77LIBS='-lftn -lm'
fi
dnl ----------------------------------------------------------------------
dnl For GL/OpenGL
dnl ----------------------------------------------------------------------
if test "X$LIBGL" = "X"; then
LIBGL="-lGLU -lGL -lXext -lX11 -lm"
LIBGLUT="-lglut -lGLU -lGL -lXmu -lXi -lXext -lX11 -lm"
fi
dnl ----------------------------------------------------------------------
dnl Can't get load warnings turned off satisfactorily
dnl LDFLAGS="$LDFLAGS -Wl,\"-woff 15,84\""
dnl LDFLAGS="$LDFLAGS -Wl,\"-wall\""
dnl echo "LDFLAGS: $LDFLAGS"
dnl ----------------------------------------------------------------------
case "X$IRIXMODE" in
X32)
BBH_SYSTEM=IRIX32
CFLAGS="$CFLAGS -DSGI -32";
CXXFLAGS="CXXFLAGS -DSGI -32";
LDFLAGS="$LDFLAGS -32";
;;
Xn32|XN32)
BBH_SYSTEM=IRIXN32
CFLAGS="$CFLAGS -DSGI -n32"
CXXFLAGS="$CXXFLAGS -DSGI -n32";
LDFLAGS="$LDFLAGS -n32";
;;
*)
BBH_SYSTEM=IRIX64;
CFLAGS="$CFLAGS -DSGI -64";
CXXFLAGS="$CXXFLAGS -DSGI -64";
LDFLAGS="$LDFLAGS -64";
;;
esac
case $BBH_NPROC in
1) ;;
*)
CFLAGS="$CFLAGS -WK,-listoption=O -pfa -mp";
CXXFLAGS="$CXXFLAGS -pfa -mp";
F77FLAGS="$F77FLAGS -pfa -mp";
F77FLAGSNOOPT="$F77FLAGSNOOPT -pfa -mp";
LDFLAGS="$LDFLAGS -pfa -mp";
;;
esac;
F77FLAGS="$F77FLAGS -NC149999"
CC_TRANSFORM="cat"
dnl F77_TRANSFORM="touch";
break;;
IRIX*) BBH_SYSTEM=IRIX;
dnl F77_TRANSFORM="touch";
CFLAGS="$CFLAGS -DSGI"
CPPFLAGS="$CPPFLAGS -DSGI"
CC_TRANSFORM="cat"
dnl ----------------------------------------------------------------------
dnl See comment above
dnl CXXFLAGS="$CXXFLAGS -ptused -DSGI -woff 1233";
dnl ----------------------------------------------------------------------
CXXFLAGS="$CXXFLAGS -ptused -DSGI"
CXXREPOSITORY="ii_files"
CXXF90LIBS='-lftn -lftn90'
case "X$IRIXMODE" in
Xn32|XN32)
BBH_SYSTEM=IRIXN32
CFLAGS="$CFLAGS -n32"
CXXFLAGS="$CXXFLAGS -n32"
LDFLAGS="$LDFLAGS -n32";
;;
X64)
BBH_SYSTEM=IRIX64
CFLAGS="$CFLAGS -64"
CXXFLAGS="$CXXFLAGS -64";
LDFLAGS="$LDFLAGS -64";
;;
esac
break;;
SUNOS)
BBH_SYSTEM=SUNOS;
dnl F77_TRANSFORM="touch";
LDFLAGS="$LDFLAGS -L/usr/ccs/lib ";
CXXFLAGS="$CXXFLAGS -pto"
CPPFLAGS="$CPPFLAGS -xCC -DCPPFLAGS_UNKNOWN"
CXXREPOSITORY="Templates.DB"
CXXF90LIBS='-lsunmath -lF77'
CC_TRANSFORM="cat"
dnl ----------------------------------------------------------------------
dnl For linkage to Fortran 77 code via C
dnl ----------------------------------------------------------------------
if test "X$CCF77LIBS" = "X"; then
CCF77LIBS='-lF77 -lM77 -lsunmath -lm'
fi
break;;
AIX)
BBH_SYSTEM=AIX;
dnl F77_TRANSFORM="touch";
CXXF90LIBS='-lxlf -lxlf90'
CC_TRANSFORM="cat"
dnl ----------------------------------------------------------------------
dnl Check to see whether this is Cornell SP-2
dnl ----------------------------------------------------------------------
dnl for ss in $__UNAME
dnl do
dnl case $ss in
dnl SP*) BBH_SUBSYSTEM="SP2";;
dnl *);;
dnl esac
dnl done
BBH_SUBSYSTEM=""
case $BBH_SUBSYSTEM in
SP2)
BBH_SUBSYSTEM="SP2"
CFLAGS="$CFLAGS -DSPX"
CPPFLAGS="$CPPFLAGS -DCPPFLAGS_UNKNOWN"
CXXFLAGS="$CXXFLAGS -DSPX"
CC=mpcc
CXX=mpCC
;;
*)
CFLAGS="$CFLAGS -DRS6000 -D_ALL_SOURCE"
CPPFLAGS="$CPPFLAGS -DCPPFLAGS_UNKNOWN"
CXXFLAGS="$CXXFLAGS -DRS6000"
if test "X$CC" = "X"; then
CC=xlc
fi
if test "X$CXX" = "X"; then
CXX=xlC
fi
dnl ----------------------------------------------------------------------
dnl This works on the TICAM RS/6000's. The path may be wrong on others.
dnl ----------------------------------------------------------------------
dnl LDFLAGS="$LDFLAGS -bI:/usr/lpp/xlf/lib/lowsys.exp";
dnl ----------------------------------------------------------------------
dnl These flags are DAGH-specific; if needed (at this
dnl time they are apparently *not needed) they should
dnl probably be set somewhere else.
dnl ----------------------------------------------------------------------
dnl CFLAGS="$CFLAGS -DMPICH -D_ALL_SOURCE"
dnl CFLAGS="$CFLAGS -DFORTRANNOUNDERSCORE -DMPI_rs6000"
dnl CXXFLAGS="$CXXFLAGS -DMPICH -D_ALL_SOURCE"
dnl CXXFLAGS="$CXXFLAGS -DFORTRANNOUNDERSCORE -DMPI_rs6000"
dnl ----------------------------------------------------------------------
;;
esac
CXXREPOSITORY="tempinc"
break;;
A/UX)
BBH_SYSTEM=A/UX;
dnl F77_TRANSFORM="touch";
CC_TRANSFORM="cat"
break;;
OSF1)
BBH_SYSTEM=OSF1;
F77_TRANSFORM="touch";
CC_TRANSFORM="decomment-c-c++"
CPPFLAGS="$CPPFLAGS -std1 -DDEC_ALPHA";
CXXFLAGS="$CXXFLAGS -x cxx"
BBH_DEFS="$BBH_DEFS -std1 -DDEC_ALPHA";
if test "X$CCF77LIBS" = "X"; then
CCF77LIBS='-lfor -lFutil -lots -lUfor -lm';
fi
break;;
dnl ----------------------------------------------------------------------
dnl CRAYS
dnl ----------------------------------------------------------------------
UNICOS|CRAY)
BBH_SYSTEM=UNICOS;
dnl F77_TRANSFORM="../bin/f77transcray";
BBH_RNPL_FLAGS="-csufE";
CPPFLAGS="$CPPFLAGS -D_CRAY"
CC_TRANSFORM="cat"
dnl ----------------------------------------------------------------------
dnl Get subsystem (C90, J90, T3E, T90, SV1)
dnl ----------------------------------------------------------------------
for ss in $__UNAME; do
case $ss in
C90*) BBH_SUBSYSTEM="C90";
CXXFLAGS="$CXXFLAGS -DCRAYC90"
CPPFLAGS="$CPPFLAGS -DCRAYNOIEEE"
break;;
J90*) BBH_SUBSYSTEM="J90";
CXXFLAGS="$CXXFLAGS -DCRAYJ90"
CPPFLAGS="$CPPFLAGS -DCRAYNOIEEE"
break;;
T3E*) BBH_SUBSYSTEM="T3E";
dnl ----------------------------------------------------------------------
dnl CXXFLAGS="$CXXFLAGS -Tcray-t3e -DCRAYT3D";
dnl ----------------------------------------------------------------------
CXXFLAGS="$CXXFLAGS -DCRAYT3D";
CXXFLAGS="$CXXFLAGS -h instantiate=local";
CPPFLAGS="$CPPFLAGS -DCPPFLAGS_UNKNOWN"
break;;
T90*|T94*) BBH_SUBSYSTEM="T90";
dnl ----------------------------------------------------------------------
dnl CXXFLAGS="$CXXFLAGS -Tcray-t3e -DCRAYT3D";
dnl ----------------------------------------------------------------------
CXXFLAGS="$CXXFLAGS -DCRAYT90";
CXXFLAGS="$CXXFLAGS -h instantiate=local";
CPPFLAGS="$CPPFLAGS -DCPPFLAGS_UNKNOWN"
break;;
SV1*) BBH_SUBSYSTEM="SV1";
dnl ----------------------------------------------------------------------
dnl CXXFLAGS="$CXXFLAGS -Tcray-t3e -DCRAYT3D";
dnl ----------------------------------------------------------------------
CXXFLAGS="$CXXFLAGS -DCRAYT90";
CXXFLAGS="$CXXFLAGS -h instantiate=local";
CPPFLAGS="$CPPFLAGS -DCPPFLAGS_UNKNOWN"
break;;
*) ;;
esac
done
dnl ----------------------------------------------------------------------
dnl Detect mario
dnl ----------------------------------------------------------------------
if test `hostname` = "mario"; then
BBH_SYSTEM_MARIO="yes";
fi
break;;
dnl ----------------------------------------------------------------------
dnl LINUX
dnl ----------------------------------------------------------------------
LINUX)
dnl ----------------------------------------------------------------------
dnl Use Fortran compiler to fix BBH_SYSTEM
dnl ----------------------------------------------------------------------
case "X$F77" in
Xpgf77)
BBH_SYSTEM=LINUX_PG
F77_TRANSFORM="touch";
CC_TRANSFORM="cat"
BBH_DEFS="$BBH_DEFS -DLINUX_PG"
CFLAGS="$CFLAGS"
dnl CPPFLAGS="$CPPFLAGS -DLINUX -D__ -DLINUX_PG -DPORT_GROUP -DWant_c_files"
dnl CXXFLAGS="$CXXFLAGS -DLINUX -D__ -DLINUX_PG -DPORT_GROUP -DWant_c_files"
CPPFLAGS="$CPPFLAGS -DLINUX -DLINUX_PG -DPORT_GROUP -DWant_c_files"
CXXFLAGS="$CXXFLAGS -DLINUX -DLINUX_PG -DPORT_GROUP -DWant_c_files"
if test "X$CCF77LIBS" = "X"; then
CCF77LIBS="-lpgftnrtl -lpgf90rtl -lm"
fi
;;
Xefc)
BBH_SYSTEM=LINUX_IA64
F77_TRANSFORM="touch";
CC_TRANSFORM="cat"
BBH_DEFS="$BBH_DEFS"
CFLAGS="$CFLAGS"
CPPFLAGS="$CPPFLAGS -DLINUX -DPORT_GROUP -DWant_c_files"
CXXFLAGS="$CXXFLAGS -DLINUX -DPORT_GROUP -DWant_c_files"
if test "X$CCF77LIBS" = "X"; then
CCF77LIBS="-lCEPCF90 -lF90 -lintrins -lm"
fi
;;
Xifc)
BBH_SYSTEM=LINUX_IA32
F77_TRANSFORM="touch";
CC_TRANSFORM="cat"
BBH_DEFS="$BBH_DEFS"
CFLAGS="$CFLAGS"
CPPFLAGS="$CPPFLAGS -DLINUX -DPORT_GROUP -DWant_c_files"
CXXFLAGS="$CXXFLAGS -DLINUX -DPORT_GROUP -DWant_c_files"
if test "X$CCF77LIBS" = "X"; then
CCF77LIBS="-lCEPCF90 -lF90 -lintrins -lm"
fi
;;
*)
BBH_SYSTEM=LINUX
BBH_SETDEF(CC,gcc)
BBH_SETDEF(CXX,gcc)
BBH_SETDEF(CFLAGS,-O3)
BBH_SETDEF(CPPFLAGS,"")
BBH_SETDEF(F77,g77)
if test "X$DOUBLE_UNDERSCORE" = "X"; then
BBH_SETDEF(F77FLAGS,"-O3 -fno-second-underscore")
BBH_SETDEF(F77LFLAGS,"-O3 -fno-second-underscore")
BBH_SETDEF(F90FLAGS,"-O3 -fno-second-underscore")
else
BBH_SETDEF(F77FLAGS,-O3)
BBH_SETDEF(F77LFLAGS,-O3)
BBH_SETDEF(F90FLAGS,-O3)
fi
BBH_SETDEF(F90,g77)
F77_TRANSFORM="touch";
CC_TRANSFORM="cat"
BBH_DEFS="$BBH_DEFS -DLINUX"
CFLAGS="$CFLAGS"
dnl CPPFLAGS="$CPPFLAGS -DLINUX -D__ -DPORT_GROUP -DWant_c_files"
dnl CXXFLAGS="$CXXFLAGS -DLINUX -D__ -DPORT_GROUP -DWant_c_files"
CPPFLAGS="$CPPFLAGS -DLINUX -DPORT_GROUP -DWant_c_files"
CXXFLAGS="$CXXFLAGS -DLINUX -DPORT_GROUP -DWant_c_files"
if test "X$CCF77LIBS" = "X"; then
CCF77LIBS='-lgfortran -lm'
fi
;;
esac;
RPCGEN_CPPFLAGS="-U__STDC__"
dnl ----------------------------------------------------------------------
dnl For GL/OpenGL
dnl ----------------------------------------------------------------------
LDFLAGS="$LDFLAGS -L/usr/X11R6/lib"
if test "X$LIBGL" = "X"; then
LIBGL="-lGLU -lGL -lXext -lX11 -lm"
LIBGLUT="-lglut -lGLU -lGL -lXmu -lXi -lXext -lX11 -lm"
fi
break;;
dnl ----------------------------------------------------------------------
dnl DARWIN
dnl ----------------------------------------------------------------------
DARWIN)
BBH_SYSTEM=DARWIN
BBH_SETDEF(CC,gcc)
BBH_SETDEF(CXX,gcc)
BBH_SETDEF(CFLAGS,-O3)
BBH_SETDEF(CPPFLAGS,"")
BBH_SETDEF(F77,g77)
BBH_SETDEF(F77FLAGS,-O3)
BBH_SETDEF(F77LFLAGS,-O3)
BBH_SETDEF(F90,g77)
BBH_SETDEF(F90FLAGS,-O3)
F77_TRANSFORM="touch";
CC_TRANSFORM="cat"
CFLAGS="$CFLAGS"
CPPFLAGS="$CPPFLAGS -DDARWIN -D__ -DWant_c_files"
CXXFLAGS="$CXXFLAGS -DDARWIN -D__ -DWant_c_files"
if test "X$CCF77LIBS" = "X"; then
CCF77LIBS='-lgfortran -lm'
fi
RPCGEN_CPPFLAGS="-U__STDC__"
dnl ----------------------------------------------------------------------
dnl For GL/OpenGL and g77
dnl ----------------------------------------------------------------------
LDFLAGS="$LDFLAGS -L/usr/X11R6/lib -L/sw/lib"
if test "X$LIBGL" = "X"; then
LIBGL="-lGLU -lGL -lXext -lX11 -lm"
LIBGLUT="-lglut -lGLU -lGL -lXmu -lXi -lXext -lX11 -lm"
fi
break;;
HP-UX)
BBH_SYSTEM=HP-UX;
dnl F77_TRANSFORM="touch";
CC_TRANSFORM="cat";
BBH_DEFS="$BBH_DEFS -DHP9000";
CFLAGS="$CFLAGS -Aa -D_HPUX_SOURCE -w";
CPPFLAGS="$CPPFLAGS -DCPPFLAGS_UNKNOWN"
break;;
*)
BBH_SYSTEM=UNKNOWN ;;
esac
done
ac_cv_bbh_system="$BBH_SYSTEM"
dnl ac_cv_bbh_f77_transform="$F77_TRANSFORM";
]
)
case $BBH_NPROC in
1) AC_MSG_RESULT($ac_cv_bbh_system);;
*) AC_MSG_RESULT("$BBH_NPROC-processor $ac_cv_bbh_system");;
esac
case $BBH_SUBSYSTEM in
NONE) ;;
*) AC_MSG_CHECKING("for Unix subflavour"); AC_MSG_RESULT($BBH_SUBSYSTEM);;
esac
BBH_SYSTEM=$ac_cv_bbh_system
dnl F77_TRANSFORM=$ac_cv_bbh_f77_transform
dnl ----------------------------------------------------------------------
dnl Export some values
dnl ----------------------------------------------------------------------
AC_SUBST(BBH_SYSTEM)
AC_SUBST(BBH_RNPL_FLAGS)
AC_SUBST(CC_TRANSFORM)
dnl AC_SUBST(F77_TRANSFORM)
dnl AC_SUBST(CPPFLAGS)
AC_SUBST(CXXREPOSITORY)
AC_SUBST(CXXFLAGS)
AC_SUBST(CXXF90LIBS)
AC_SUBST(CCF77LIBS)
AC_SUBST(LIBGL)
AC_SUBST(LIBGLUT)
AC_SUBST(RPCGEN_CPPFLAGS)
case $BBH_SYSTEM in
SUNOS)
AC_CHECK_LIB(socket, socket,
LIBS="$LIBS -lsocket"
BBH_RNPLAPP_FLIBS="$BBH_RNPLAPP_FLIBS -lsocket"
BBH_RNPLAPP_CLIBS="$BBH_RNPLAPP_CLIBS -lsocket"
)
AC_CHECK_LIB(nsl, clnt_create,
LIBS="$LIBS -lnsl"
BBH_RNPLAPP_FLIBS="$BBH_RNPLAPP_FLIBS -lnsl"
BBH_RNPLAPP_CLIBS="$BBH_RNPLAPP_CLIBS -lnsl"
)
break;;
dnl ----------------------------------------------------------------------
dnl Used to set "-lbsd" on AIX in attempt to get ^C handling working
dnl more consistently, but that breaks 'pow' and probably other things.
dnl ----------------------------------------------------------------------
esac
fi
])
dnl ----------------------------------------------------------------------
dnl BBH_GET_NPROC attempts to determine the number of processors in
dnl the system.
dnl ----------------------------------------------------------------------
AC_DEFUN(BBH_GET_NPROC,[
if test "X$BBH_NPROC" = "X"; then
AC_CACHE_VAL(ac_cv_bbh_nproc,
[
changequote(,)dnl
__UNAME=`uname -a | tr '[a-z]' '[A-Z]'`
for s in $__UNAME
do
case $s in
IRIX64) ac_cv_bbh_nproc=`hinv | grep 'IP.*Processor' | sed 's? .*??' | grep '^[0-9]*$'`;
break;;
*) ac_cv_bbh_nproc=1;
break;;
esac
done
changequote([, ])dnl
])
BBH_NPROC=$ac_cv_bbh_nproc
AC_SUBST(BBH_NPROC)
fi
])
dnl ----------------------------------------------------------------------
dnl Locate lib, include paths for DAGH
dnl
dnl "Standard" places people install DAGH can be hard-coded here
dnl ----------------------------------------------------------------------
AC_DEFUN(BBH_CHECK_DAGH,[
dnl ----------------------------------------------------------------------
dnl Look for DAGH header ...
dnl ----------------------------------------------------------------------
BBH_CHECK_FATAL="no"
AC_MSG_CHECKING(for DAGH header)
if test "X${BBH_CHECK_DEFAULTS}" != "XNONE"; then
BBH_CHECK_INC_PATHS="$BBH_CHECK_INC_PATHS /usr/local/include"
BBH_CHECK_INC_PATHS="$BBH_CHECK_INC_PATHS $HOME/dagh/include $HOME/include"
fi
BBH_FINDFILE(BBH_CHECK_INC_PATHS,"DAGH.h",BBH_INC_PATH)
if test $BBH_INC_PATH != "no"; then
BBH_PUSHUNIQUE(BBH_RNPLAPP_INCPATHS,$BBH_INC_PATH)
AC_MSG_RESULT($BBH_INC_PATH/DAGH.h)
else
AC_MSG_RESULT(not found ... will have to abort configuration)
BBH_CHECK_FATAL="yes"
fi
AC_MSG_CHECKING(for DAGH library)
if test "X${BBH_CHECK_DEFAULTS}" != "XNONE"; then
BBH_CHECK_LIB_PATHS="$BBH_CHECK_LIB_PATHS /usr/local/lib"
BBH_CHECK_LIB_PATHS="$BBH_CHECK_LIB_PATHS $HOME/dagh/lib $HOME/lib"
fi
BBH_FINDLIB(BBH_CHECK_LIB_PATHS,"dagh",BBH_LIB_PATH)
if test $BBH_LIB_PATH != "no"; then
BBH_PUSHUNIQUE(BBH_RNPLAPP_LIBPATHS,$BBH_LIB_PATH)
BBH_RNPLAPP_FLIBS="-ldagh $BBH_RNPLAPP_FLIBS"
BBH_RNPLAPP_CLIBS="-ldagh $BBH_RNPLAPP_CLIBS"
BBH_RNPLBLD_CLIBS="-ldagh $BBH_RNPLBLD_CLIBS"
AC_MSG_RESULT($BBH_LIB_PATH/libdagh.a)
else
AC_MSG_RESULT(not found ... will have to abort configuration)
BBH_CHECK_FATAL="yes"
fi
if test $BBH_CHECK_FATAL = "yes"; then
BBH_MSG_DAGH_EXAMPLES_NEED_DAGH
fi
])
AC_DEFUN(BBH_MSG_DAGH_EXAMPLES_NEED_DAGH,[
cat<<.
Installation of the DAGH examples directory requires that DAGH
be intalled on your system and that this script be able to locate
the header file 'DAGH.h' and the library file 'libdagh.a'.
One or both of these files could not be found in the "usual places"
If you know the directories in which the
headers and library are installed on this system, set the
environment variables
LIB_PATHS
INCLUDE_PATHS
to those directory and re-configure.
It is probably wisest
to remove the configuration cache:
/bin/rm config.cache
before reconfiguring.
.
AC_MSG_ERROR(Exiting)
])
AC_DEFUN(BBH_MSG_NEED_MPI,[
cat<<.
Complete installation of DAGH and related software requires the
MPI header file 'mpi.h' and the MPI library 'libmpi.a'; at least one
of which could not be found in any of the usual locations.
If you know the directories in which the headers and library are installed
on this system, set the environment variables
LIB_PATHS
INCLUDE_PATHS
to include those directories and re-configure.
Alternatively, you can
setenv DAGH_NO_MPI on
and re-configure to build without MPI. It is probably wisest
to remove the configuration cache:
/bin/rm config.cache
before reconfiguring.
.
AC_MSG_ERROR(Exiting)
])
dnl ----------------------------------------------------------------------
dnl Locate lib, include paths for auxiliary software needed by DAGH
dnl and not currently needed by RNPL (including librnpl.a).
dnl BBH_CHECK_RNPL_LIBS should always be invoked before this macro
dnl ----------------------------------------------------------------------
AC_DEFUN(BBH_CHECK_DAGH_WITH_RNPL_LIBS,[
BBH_CHECK_FATAL="no"
if test "X${BBH_CHECK_DEFAULTS}" != "XNONE"; then
BBH_CHECK_LIB_PATHS="$LIB_PATHS $BBH_CHECK_LIB_PATHS /usr/local/lib"
BBH_CHECK_INC_PATHS="$INCLUDE_PATHS $BBH_CHECK_INC_PATHS /usr/local/include"
else
BBH_CHECK_LIB_PATHS="$LIB_PATHS $BBH_CHECK_LIB_PATHS"
BBH_CHECK_INC_PATHS="$INCLUDE_PATHS $BBH_CHECK_INC_PATHS"
fi
dnl ----------------------------------------------------------------------
dnl Look for the MPI headers and library ... Fatal exit can be
dnl overwritten by setting the environment variable DAGH_NO_MPI to some
dnl non-trivial value.
dnl ----------------------------------------------------------------------
if test "X$DAGH_NO_MPI" = "X"; then
dnl ----------------------------------------------------------------------
dnl Building with MPI
dnl ----------------------------------------------------------------------
case "$BBH_SYSTEM/$BBH_SUBSYSTEM" in
dnl ----------------------------------------------------------------------
dnl Don't need MPI on SP2
dnl ----------------------------------------------------------------------
AIX/SP2)
;;
*)
AC_MSG_CHECKING(for mpi headers)
dnl BBH_CHECK_INC_PATHS="$BBH_CHECK_INC_PATHS /usr/local/mpi/include"
if test "X${BBH_CHECK_DEFAULTS}" != "XNONE"; then
BBH_CHECK_INC_PATHS="$BBH_CHECK_INC_PATHS /pds/MPI/mpich/include"
fi
BBH_FINDFILE(BBH_CHECK_INC_PATHS,"mpi.h",BBH_INC_PATH)
if test $BBH_INC_PATH != "no"; then
AC_MSG_RESULT($BBH_INC_PATH/mpi.h)
BBH_PUSHUNIQUE(BBH_RNPLAPP_INCPATHS,$BBH_INC_PATH)
dnl ----------------------------------------------------------------------
dnl Guess whether we should be compiling with -DMPICH
dnl ----------------------------------------------------------------------
MPICH=`echo $BBH_INC_PATH | grep mpich`
AC_MSG_CHECKING(if we're using mpich)
if test "X$MPICH" != "X"; then
AC_MSG_RESULT(yes ... setting -DMPICH for C++)
CXXFLAGS="$CXXFLAGS -DMPICH"
else
AC_MSG_RESULT(no)
fi
else
AC_CHECK_HEADER(mpi.h,
HAVE_MPIH=1
)
if test "X$HAVE_MPIH" = "X"; then
if test "X$DAGH_NO_MPI" = "X"; then
AC_MSG_RESULT(not found)
AC_MSG_WARN(Can't find mpi headers ... see message below)
BBH_CHECK_FATAL="yes"
else
AC_MSG_RESULT(not found ... building without MPI)
fi
else
MPICH=`echo $BBH_INC_PATH | grep mpich`
AC_MSG_CHECKING(if we're using mpich)
if test "X$MPICH" != "X"; then
AC_MSG_RESULT(yes ... setting -DMPICH for C++)
CXXFLAGS="$CXXFLAGS -DMPICH"
else
AC_MSG_RESULT(no)
fi
fi
fi
AC_MSG_CHECKING(for mpi library)
dnl BBH_CHECK_LIB_PATHS="$BBH_CHECK_LIB_PATHS /usr/local/mpi/lib/IRIX64/ch_p4"
dnl BBH_CHECK_LIB_PATHS="$BBH_CHECK_LIB_PATHS /usr/local/mpi/lib/IRIXN32/ch_p4"
BBH_CHECK_LIB_PATHS="$BBH_CHECK_LIB_PATHS /pds/MPI/mpich/lib/rs6000/ch_p4"
BBH_FINDLIB(BBH_CHECK_LIB_PATHS,"mpi",BBH_LIB_PATH)
if test $BBH_LIB_PATH != "no"; then
AC_MSG_RESULT($BBH_LIB_PATH/libmpi.a)
BBH_PUSHUNIQUE(BBH_RNPLAPP_LIBPATHS,$BBH_LIB_PATH)
dnl ----------------------------------------------------------------------
dnl MPI requires some OS-dependent additional libaries
dnl ----------------------------------------------------------------------
case $BBH_SYSTEM in
IRIX|IRIX64|IRIX32|IRIXN32) BBH_MPI_XTRA_LIBS=" " ;;
SUNOS) BBH_MPI_XTRA_LIBS=" " ;;
AIX) BBH_MPI_XTRA_LIBS="-lbsd" ;;
A/UX) BBH_MPI_XTRA_LIBS=" " ;;
OSF1) BBH_MPI_XTRA_LIBS=" " ;;
UNICOS) BBH_MPI_XTRA_LIBS=" " ;;
*) BBH_MPI_XTRA_LIBS=" " ;;
esac
BBH_RNPLAPP_FLIBS="$BBH_RNPLAPP_FLIBS -lmpi $BBH_MPI_XTRA_LIBS"
BBH_RNPLAPP_CLIBS="$BBH_RNPLAPP_CLIBS -lmpi $BBH_MPI_XTRA_LIBS"
BBH_RNPLBLD_CLIBS="$BBH_RNPLBLD_CLIBS -lmpi $BBH_MPI_XTRA_LIBS"
BBH_DEFS="$BBH_DEFS -DHAVE_LIBMPI=1"
else
AC_CHECK_LIB(mpi, MPI_Init,
HAVE_LIBMPI=1
)
if test "X$HAVE_LIBMPI" = "X"; then
AC_MSG_RESULT(not found)
BBH_CHECK_FATAL="yes"
else
case $BBH_SYSTEM in
IRIX|IRIX64|IRIX32|IRIXN32) BBH_MPI_XTRA_LIBS=" " ;;
SUNOS) BBH_MPI_XTRA_LIBS=" " ;;
AIX) BBH_MPI_XTRA_LIBS="-lbsd" ;;
A/UX) BBH_MPI_XTRA_LIBS=" " ;;
OSF1) BBH_MPI_XTRA_LIBS=" " ;;
UNICOS) BBH_MPI_XTRA_LIBS=" " ;;
*) BBH_MPI_XTRA_LIBS=" " ;;
esac
BBH_RNPLAPP_FLIBS="$BBH_RNPLAPP_FLIBS -lmpi $BBH_MPI_XTRA_LIBS"
BBH_RNPLAPP_CLIBS="$BBH_RNPLAPP_CLIBS -lmpi $BBH_MPI_XTRA_LIBS"
BBH_RNPLBLD_CLIBS="$BBH_RNPLBLD_CLIBS -lmpi $BBH_MPI_XTRA_LIBS"
BBH_DEFS="$BBH_DEFS -DHAVE_LIBMPI=1"
fi
fi
if test $BBH_CHECK_FATAL = "yes"; then
BBH_MSG_NEED_MPI
fi
;;
esac
else
dnl ----------------------------------------------------------------------
dnl Building without MPI
dnl ----------------------------------------------------------------------
AC_MSG_WARN("Building without MPI")
BBH_DEFS="$BBH_DEFS -DDAGH_NO_MPI -DACE_NO_MPI"
fi
dnl ----------------------------------------------------------------------
dnl Look for location of RNPL (bbhutil) headers and library (rnpl).
dnl ----------------------------------------------------------------------
if test "X$NORNPL" = "X"; then
AC_MSG_CHECKING(for bbhutil headers)
if test "X${BBH_CHECK_DEFAULTS}" != "XNONE"; then
BBH_CHECK_INC_PATHS="$BBH_CHECK_INC_PATHS /usr/local/include /usr/local/rnpl/include"
fi
BBH_FINDFILE(BBH_CHECK_INC_PATHS,"bbhutil.h",BBH_INC_PATH)
if test $BBH_INC_PATH != "no"; then
CPPFLAGS="$CPPFLAGS -DIO_RNPLIO"
BBH_PUSHUNIQUE(BBH_RNPLAPP_INCPATHS,$BBH_INC_PATH)
AC_MSG_RESULT($BBH_INC_PATH/bbhutil.h)
else
AC_MSG_RESULT(not found ... some test apps may not build)
fi
AC_MSG_CHECKING(for rnpl library)
BBH_FINDLIB(BBH_CHECK_LIB_PATHS,"rnpl",BBH_LIB_PATH)
if test $BBH_LIB_PATH != "no"; then
BBH_PUSHUNIQUE(BBH_RNPLAPP_LIBPATHS,$BBH_LIB_PATH)
dnl ----------------------------------------------------------------------
dnl Don't have to add '-lrnpl' since is done by BBH_CHECK_RNPL_LIBS
dnl ----------------------------------------------------------------------
AC_MSG_RESULT($BBH_LIB_PATH/librnpl.a)
else
AC_MSG_RESULT(not found ... some test apps may not build)
fi
else
AC_MSG_WARN("Building without RNPL ... some test apps may not build")
fi
])
AC_DEFUN(BBH_MSG_NEED_MPI,[
cat<<.
Complete installation on DAGH requires the MPI header file 'mpi.h' and
the MPI library 'libmpi.a'; at least one of which could not be found in
any of the usual locations. If you know the directories in which the
headers and library are installed on this system, set the
environment variables
LIB_PATHS
INCLUDE_PATHS
to those directory and re-configure.
Alternatively, you can
setenv DAGH_NO_MPI on
and re-configure to build DAGH without MPI. It is probably wisest
to remove the configuration cache:
/bin/rm config.cache
before reconfiguring.
.
AC_MSG_ERROR(Exiting)
])
dnl ----------------------------------------------------------------------
dnl Locate lib, include paths for auxiliary software needed by RNPL
dnl ----------------------------------------------------------------------
AC_DEFUN(BBH_CHECK_RNPL_LIBS,[
BBH_CHECK_FATAL="no"
BBH_RNPLAPP_LIBPATHS="$BBH_RNPLAPP_LIBPATHS $prefix/lib"
BBH_RNPLAPP_INCPATHS="$BBH_RNPLAPP_INCPATHS $prefix/include"
BBH_RNPLAPP_FLIBS="$BBH_RNPLAPP_FLIBS -lrnpl $BBH_MISC_FLIBS"
BBH_RNPLAPP_CLIBS="$BBH_RNPLAPP_CLIBS -lrnpl "
BBH_RNPLBLD_CLIBS="$BBH_RNPLBLD_CLIBS -lrnpl $LIBS $BBH_MISC_FLIBS"
if test "X${BBH_CHECK_DEFAULTS}" != "XNONE"; then
BBH_CHECK_INC_PATHS="$INCLUDE_PATHS /usr/include"
BBH_CHECK_INC_PATHS="$BBH_CHECK_INC_PATHS $HOME/include $HOME/hdf/include"
BBH_CHECK_INC_PATHS="$BBH_CHECK_INC_PATHS /usr/local/include /local/include"
BBH_CHECK_INC_PATHS="$BBH_CHECK_INC_PATHS /usr/local/hdf/include"
BBH_CHECK_INC_PATHS="$BBH_CHECK_INC_PATHS /usr/local/lib/hdf/include"
BBH_CHECK_INC_PATHS="$BBH_CHECK_INC_PATHS $prefix/include"
BBH_CHECK_INC_PATHS="$BBH_CHECK_INC_PATHS $prefix/hdf/include"
BBH_CHECK_LIB_PATHS="/usr/lib64 $LIB_PATHS"
BBH_CHECK_LIB_PATHS="$BBH_CHECK_LIB_PATHS $HOME/lib $HOME/hdf/lib"
BBH_CHECK_LIB_PATHS="$BBH_CHECK_LIB_PATHS /usr/local/lib /local/lib"
BBH_CHECK_LIB_PATHS="$BBH_CHECK_LIB_PATHS /usr/local/hdf/lib"
BBH_CHECK_LIB_PATHS="$BBH_CHECK_LIB_PATHS /usr/local/lib/hdf/lib"
BBH_CHECK_LIB_PATHS="$BBH_CHECK_LIB_PATHS $prefix/lib $prefix/hdf/lib"
else
BBH_CHECK_LIB_PATHS="$LIB_PATHS $BBH_CHECK_LIB_PATHS"
BBH_CHECK_INC_PATHS="$INCLUDE_PATHS $BBH_CHECK_INC_PATHS"
fi
dnl ----------------------------------------------------------------------
dnl Handle HDF ... now only execute if environment variable HDF is set.
dnl ----------------------------------------------------------------------
if test "X$HDF" != "X"; then
AC_MSG_CHECKING(for netcdf headers)
BBH_FINDFILE(BBH_CHECK_INC_PATHS,"mfhdf.h",BBH_INC_PATH)
if test $BBH_INC_PATH = "no"; then
AC_MSG_RESULT(not found)
AC_MSG_WARN(Can't find netcdf headers ... see message below)
BBH_CHECK_FATAL="yes"
else
AC_MSG_RESULT($BBH_INC_PATH/mfhdf.h)
BBH_PUSHUNIQUE(BBH_RNPLAPP_INCPATHS,$BBH_INC_PATH)
fi
AC_MSG_CHECKING(for hdf headers)
BBH_FINDFILE(BBH_CHECK_INC_PATHS,"df.h",BBH_INC_PATH)
if test $BBH_INC_PATH = "no"; then
AC_MSG_RESULT(not found)
AC_MSG_WARN(Can't find hdf headers ... see message below)
BBH_CHECK_FATAL="yes"
else
BBH_PUSHUNIQUE(BBH_RNPLAPP_INCPATHS,$BBH_INC_PATH)
AC_MSG_RESULT($BBH_INC_PATH/df.h)
fi
dnl ----------------------------------------------------------------------
dnl Name of 'netcdf' library changes with HDF 4.0 (sigh)
dnl ----------------------------------------------------------------------
BBH_APPEND_JPEG_Z="no"
AC_MSG_CHECKING(for mfhdf library)
BBH_FINDLIB(BBH_CHECK_LIB_PATHS,"mfhdf",BBH_LIB_PATH)
if test $BBH_LIB_PATH = "no"; then
AC_MSG_RESULT(not found ... will look for netcdf)
BBH_FINDLIB(BBH_CHECK_LIB_PATHS,"netcdf",BBH_LIB_PATH)
AC_MSG_CHECKING(for netcdf library)
if test $BBH_LIB_PATH = "no"; then
AC_MSG_RESULT(not found)
AC_MSG_WARN(Can't find netcdf library ... see message below)
BBH_CHECK_FATAL="yes"
else
AC_MSG_RESULT($BBH_LIB_PATH/libnetcdf.a)
BBH_PUSHUNIQUE(BBH_RNPLAPP_LIBPATHS,$BBH_LIB_PATH)
BBH_RNPLAPP_FLIBS="$BBH_RNPLAPP_FLIBS -lnetcdf"
BBH_RNPLAPP_CLIBS="$BBH_RNPLAPP_CLIBS -lnetcdf"
BBH_RNPLBLD_CLIBS="$BBH_RNPLBLD_CLIBS -lnetcdf"
BBH_HDFAPP_FLIBS="$BBH_HDFAPP_FLIBS -lnetcdf"
BBH_HDFAPP_CLIBS="$BBH_HDFAPP_FLIBS -lnetcdf"
BBH_DEFS="$BBH_DEFS -DHAVE_LIBNETCDF=1"
fi
else
AC_MSG_RESULT($BBH_LIB_PATH/libmfhdf.a)
BBH_PUSHUNIQUE(BBH_RNPLAPP_LIBPATHS,$BBH_LIB_PATH)
BBH_RNPLAPP_FLIBS="$BBH_RNPLAPP_FLIBS -lmfhdf"
BBH_RNPLAPP_CLIBS="$BBH_RNPLAPP_CLIBS -lmfhdf"
BBH_RNPLBLD_CLIBS="$BBH_RNPLBLD_CLIBS -lmfhdf"
BBH_HDFAPP_FLIBS="$BBH_HDFAPP_FLIBS -lmfhdf"
BBH_HDFAPP_CLIBS="$BBH_HDFAPP_FLIBS -lmfhdf"
BBH_DEFS="$BBH_DEFS -DHAVE_LIBNETCDF=1"
BBH_APPEND_JPEG_Z="yes"
fi
BBH_FINDLIB(BBH_CHECK_LIB_PATHS,"df",BBH_LIB_PATH)
AC_MSG_CHECKING(for hdf library)
if test $BBH_LIB_PATH = "no"; then
AC_MSG_RESULT(not found)
AC_MSG_WARN(Can't find hdf library ... see message below)
BBH_CHECK_FATAL="yes"
else
AC_MSG_RESULT($BBH_LIB_PATH/libdf.a)
BBH_PUSHUNIQUE(BBH_RNPLAPP_LIBPATHS,$BBH_LIB_PATH)
dnl ----------------------------------------------------------------------
dnl Kludge for mario: ensure that local copy of 'libdf.a' gets linked
dnl ----------------------------------------------------------------------
if test "X$BBH_SYSTEM_MARIO" = "Xyes"; then
BBH_MARIO_LIBDF="-l/usr/users/8/choptuik/lib/libdf.a"
BBH_RNPLAPP_FLIBS="$BBH_RNPLAPP_FLIBS $BBH_MARIO_LIBDF"
BBH_RNPLAPP_CLIBS="$BBH_RNPLAPP_CLIBS $BBH_MARIO_LIBDF"
BBH_RNPLBLD_CLIBS="$BBH_RNPLBLD_CLIBS $BBH_MARIO_LIBDF"
BBH_HDFAPP_FLIBS="$BBH_HDFAPP_FLIBS $BBH_MARIO_LIBDF"
BBH_HDFAPP_CLIBS="$BBH_HDFAPP_FLIBS $BBH_MARIO_LIBDF"
else
BBH_RNPLAPP_FLIBS="$BBH_RNPLAPP_FLIBS -ldf"
BBH_RNPLAPP_CLIBS="$BBH_RNPLAPP_CLIBS -ldf"
BBH_RNPLBLD_CLIBS="$BBH_RNPLBLD_CLIBS -ldf"
BBH_HDFAPP_FLIBS="$BBH_HDFAPP_FLIBS -ldf"
BBH_HDFAPP_CLIBS="$BBH_HDFAPP_FLIBS -ldf"
fi
BBH_DEFS="$BBH_DEFS -DHAVE_LIBDF=1"
fi
if test $BBH_APPEND_JPEG_Z = "yes"; then
dnl ----------------------------------------------------------------------
dnl Assume that 'libjpeg.a' and 'libz.a' have been installed in same
dnl location as 'libdf.a' and 'libmfhdf.a'
dnl ----------------------------------------------------------------------