(file) Return to configure CVS log (file) (dir) Up to [Development] / JSOC

  1 arta  1.1 #! /bin/csh -f
  2           
  3           set CLEAN = "no"
  4           set CHKLIBS = "no"
  5           set CCMD = "c"
  6           set LCMD = "l"
  7           
  8           foreach ARG ($argv)
  9               set FLAG = `echo $ARG | awk '{print substr($0, 2)}'`
 10               if ($FLAG == $CCMD) then
 11                 set CLEAN = "yes"
 12               else if ($FLAG == $LCMD) then
 13                 set CHKLIBS = "yes"
 14               endif
 15           end
 16           
 17           if ($CHKLIBS == "no") then
 18 arta  1.5     echo -n "Remove links for local project configuration..."
 19 arta  1.10     if (-d proj) then
 20            	cd proj
 21 arta  1.8  	if (-e configure) then
 22            	    rm configure
 23            	endif
 24            	if (-e make_basic.mk) then
 25            	    rm make_basic.mk
 26            	endif
 27            	if (-e Rules.mk) then
 28            	    rm Rules.mk
 29            	endif
 30            	if (-e target.mk) then
 31            	    rm target.mk
 32            	endif
 33 arta  1.10 	cd ..
 34 arta  1.5      endif
 35                echo "done"
 36            
 37 arta  1.1      echo -n "Remove links to man pages..."
 38                if (-d man/man1) then
 39            	cd man/man1
 40 arta  1.8  	find . -name "*.*" -exec rm {} \;
 41 arta  1.1  	cd ../..
 42                endif
 43                if (-d man/man3) then
 44            	cd man/man3
 45 arta  1.8  	find . -name "*.*" -exec rm {} \;
 46 arta  1.1  	cd ../..
 47                endif
 48                echo "done"
 49            
 50                echo -n "Removing links to headers..."
 51 arta  1.10     if (-d base/include) then
 52            	cd base/include
 53 arta  1.8  	find . -name "*.h" -exec rm {} \;
 54 arta  1.10 	cd ../..
 55 arta  1.1      endif
 56                echo "done"
 57            
 58                echo -n "Removing links to scripts..."
 59                if (-d scripts) then
 60            	cd scripts
 61 arta  1.8  	find . -name "*" -exec rm {} \;
 62 arta  1.1  	cd ..
 63                endif
 64                echo "done"
 65            
 66                echo -n "Removing links to jsds..."
 67                if (-d jsds) then
 68            	cd jsds
 69 arta  1.8  	find . -name "*" -exec rm {} \;
 70 arta  1.1  	cd ..
 71                endif
 72                echo "done"
 73            
 74                echo
 75            
 76                if ($CLEAN == "yes") then
 77 arta  1.10 	if (-x base/local/libs/dsds/scripts/rmlinks.csh) then
 78            	    base/local/libs/dsds/scripts/rmlinks.csh
 79 arta  1.1  	endif
 80            
 81 arta  1.10 	if (-x base/local/libs/soi/scripts/rmlinks.csh) then
 82            	    base/local/libs/soi/scripts/rmlinks.csh
 83 arta  1.1  	endif
 84                else
 85 arta  1.5  	echo -n "Setting links for local project configuration..."
 86 arta  1.6  	if (-e suflag.txt) then
 87 arta  1.10 	    cd proj
 88            	    ln -sf ../projconf/su/configure configure
 89            	    ln -sf ../projconf/su/make_basic.mk make_basic.mk
 90            	    ln -sf ../projconf/su/Rules.mk Rules.mk
 91            	    ln -sf ../projconf/su/target.mk target.mk
 92            	    cd ..
 93 arta  1.6  	else
 94 arta  1.10 	    cd proj
 95            	    ln -sf ../projconf/ex/configure configure
 96            	    ln -sf ../projconf/ex/make_basic.mk make_basic.mk
 97            	    ln -sf ../projconf/ex/Rules.mk Rules.mk
 98            	    ln -sf ../projconf/ex/target.mk target.mk
 99            	    cd ..
100 arta  1.5  	endif
101            	echo "done"
102            
103 arta  1.1  	echo -n "Setting links to man pages..."
104            	if (!(-d man/man1)) then
105            	    mkdir -p man/man1
106            	endif
107            	if (!(-d man/man3)) then
108            	    mkdir -p man/man3
109            	endif
110            	cd man/man1
111 arta  1.2  	find ../.. -path '../../man/man1' -prune -o -path '*/man/man1/*.1' -exec ln -s {} . \;
112 arta  1.1  	cd ../../man/man3
113 arta  1.2  	find ../.. -path '../../man/man3' -prune -o -path '*/man/man3/*.3' -exec ln -s {} . \;
114 arta  1.1  	cd ../..
115            	echo "done"
116            
117            	echo "Setting links to headers..."
118 arta  1.10 	if (!(-d base/include)) then
119            	    mkdir -p base/include
120 arta  1.1  	endif
121 arta  1.10 	cd base/include
122 arta  1.1  	find .. -path '../include' -prune -o -name \*.h  \( \( -exec ln -s {} . \; -a -exec echo "  " {} " OK" \; \) -o -exec echo "  " {} " ERROR - couldn't create link" \; \)
123 arta  1.10 	cd ../..
124 arta  1.1  	echo "done"
125            	echo
126            	
127            	echo "Setting links to scripts..."
128                    if (!(-d scripts)) then
129            	    mkdir scripts
130            	endif
131            	cd scripts
132 arta  1.3  
133            	# Sums scripts
134 arta  1.10 	find ../base/sums/scripts -mindepth 1 \( -path \*CVS -prune -o -exec ln -s {} . \; -a -exec echo "  " {} " OK" \; \) -o -exec echo "  " {} " ERROR - couldn't create link" \;
135 arta  1.3  
136            	# Util scripts
137 arta  1.10 	find ../base/util/scripts -mindepth 1 \( -path \*CVS -prune -o -exec ln -s {} . \; -a -exec echo "  " {} " OK" \; \) -o -exec echo "  " {} " ERROR - couldn't create link" \;
138 arta  1.3  
139 arta  1.9  	# DRMS / IDL-interface scripts
140 arta  1.10 	find ../base/drms/scripts -mindepth 1 \( -path \*CVS -prune -o -exec ln -s {} . \; -a -exec echo "  " {} " OK" \; \) -o -exec echo "  " {} " ERROR - couldn't create link" \;
141 arta  1.9  
142 arta  1.4  	# Project-specific scripts - these won't show up if you don't have the project source.
143 arta  1.10 	if (-x ../proj/configure) then
144            	    ../proj/configure
145 arta  1.4  	endif
146 arta  1.3  
147 arta  1.1  	cd ..
148            	echo "done"
149            	echo
150            
151            	echo "Setting links to jsds..."
152            	if (!(-d jsds)) then
153            	    mkdir jsds
154            	endif
155            	cd jsds
156 arta  1.10 	find ../base \( -name \*.jsd -exec ln -s {} . \; -a -exec echo "  " {} " OK" \; \) -o \( -name \*.jsd -exec echo "  " {} " ERROR - couldn't create link" \; \)
157 arta  1.1  	cd ..
158            	echo "done"
159            	echo
160            
161            	# generate links for DSDS/SOI dynamic libraries - only do this if 
162            	# user's environment has access to /home/soi/CM
163            	if (-d /home/soi/CM/include && -d /home/soi/CM/src) then
164 arta  1.10 	    if (-x base/local/libs/dsds/scripts/genlinks.csh) then
165            		base/local/libs/dsds/scripts/genlinks.csh
166 arta  1.1  	    endif
167            
168 arta  1.10 	    if (-x base/local/libs/soi/scripts/genlinks.csh) then
169            		base/local/libs/soi/scripts/genlinks.csh
170 arta  1.1  	    endif
171            	endif
172                endif
173            endif
174            
175            # Enter required library names and versions here.
176            if ($CHKLIBS == "yes") then
177            
178                echo
179                echo "JSOC expects all third-party library header files to be located at $JSOCROOT/lib_third_party/include/ and all third-party libraries to be located at $JSOCROOT/lib_third_party/$JSOC_MACHINE/.  If you wish to build a target that uses one of the following third-paty libraries, please install the required library version and create a link from from $JSOCROOT/lib_third_party/include/ and $JSOCROOT/lib_third_party/$JSOC_MACHINE/ to the installed library headers and binary files, respectively."
180                echo
181                echo "Example:"
182                echo "  cd $JSOCROOT/lib_third_party/"
183                echo "  ln -s /usr/local/include include"
184                echo "  cd $JSOCROOT/lib_third_party/$JSOC_MACHINE/"
185                echo "  ln -s /usr/local/lib/libfftw3f.a libfftw3f.a "
186                echo
187                echo "Library libfftw3f.a (v. 3.1.2) required for targets: universe, examples, helloworld, xinterp, demo_td08062007"
188                echo "Library libcfitsio.a (v. 3.03) required for targets: universe, examples, f_ingest_gong_mrv, f_dup_gong_mrv"
189            
190            #    echo "Library libcfitsio.a (v. 3.03) required for targets: examples, helloworld"
191 arta  1.1  #    echo "Library libmkl.so (v. 9.0) required for targets: examples, helloworld"
192            #    if ($JSOC_MACHINE == "linux_x86_64") then 
193            #	echo "Library libmkl_lapack64.so (v. 9.0) required for targets: examples, helloworld"
194            #    else echo "Library libmkl_lapack32.so (v. 9.0) required for targets: examples, helloworld"
195            #    endif
196            
197            
198            endif 

Karen Tian
Powered by
ViewCVS 0.9.4