fix missing -lnetcdff when netcdf built as shared libraries #8
[WPS-merge.git] / clean
blob862376fb0d0c45b8d2bc55b14db6b0f6bf0270ce
1 #!/bin/csh -f
3 set DEV_TOP = `pwd`
5 set TOUCH = ORIG
6 if ( ! -e configure.wps ) then
7 touch configure.wps
8 set TOUCH = TOUCH
9 endif
11 set nonomatch
13 set DIRS = ( geogrid ungrib metgrid ungrib ungrib util util util util util util util util )
14 set EXES = ( geogrid ungrib metgrid g1print g2print plotfmt plotgrids mod_levs rd_intermediate avg_tsfc calc_ecmwf_p height_ukmo int2nc )
16 set i = 1
17 foreach dir ( $DIRS )
18 if ( -d $dir ) then
19 ( cd $dir ; make -i DEV_TOP="${DEV_TOP}" TARGET="$EXES[$i].exe" clean )
20 endif
21 /bin/rm -f $EXES[$i].exe
22 if ( $EXES[$i] == "g1print" || $EXES[$i] == "g2print" ) then
23 /bin/rm -f util/$EXES[$i].exe
24 endif
25 @ i ++
26 end
28 #rm gmeta
30 #if ( -e GRIBFILE.AAA ) then
31 # /bin/rm -f GRIBFILE.[A-Z][A-Z][A-Z]
32 #endif
34 #/bin/rm -f FILE:[0-9][0-9][0-9][0-9]-[0-9][0-9]-[0-9][0-9]_[0-9][0-9] >& /dev/null
36 #if ( -e Vtable ) then
37 # /bin/rm -f Vtable
38 #endif
40 #foreach core ( em nmm )
41 # foreach io_form ( nc bin grib )
42 # /bin/rm -f geo_${core}.d[0-9][0-9].${io_form} >& /dev/null
43 # /bin/rm -f met_${core}.d[0-9][0-9].*.${io_form} >& /dev/null
44 # end
45 #end
47 #if ( -e geogrid.log ) then
48 # /bin/rm -f geogrid.log
49 #endif
51 #if ( -e metgrid.log ) then
52 # /bin/rm -f metgrid.log
53 #endif
55 if ( "$1" == '-a' ) then
56 /bin/rm -rf ./netcdf_links
57 foreach dir ( $DIRS )
58 if ( -d $dir ) then
59 ( cd $dir ; make -i DEV_TOP="${DEV_TOP}" TARGET="${dir}.exe" superclean >& /dev/null )
60 endif
61 if { test -h ${dir}.exe } then
62 /bin/rm -f ${dir}.exe
63 endif
64 end
65 if ( ( -e configure.wps ) && ( $TOUCH != TOUCH ) ) then
66 /bin/cp -p configure.wps configure.wps.backup
67 /bin/rm -f configure.wps
68 endif
69 endif
71 if ( ( $TOUCH == TOUCH ) && ( -e configure.wps ) ) then
72 /bin/rm -f configure.wps
73 endif