Annotation of loncom/build/Makefile, revision 1.37
1.1 harris41 1: # Makefile
2: # For LON-CAPA
3: # Scott Harrison
4: # November 2000
5:
1.12 harris41 6: CDTARGET="."
1.32 harris41 7: CDFSLOC="/mnt/loncapacd/install.lon-capa.org/3.1/currentcdsource"
1.12 harris41 8:
1.9 harris41 9: all:
10: # nothing yet here
1.1 harris41 11:
12: cd:
1.12 harris41 13: # Build temporary script to get cd
1.11 harris41 14: # make sure there is enough disk space
1.12 harris41 15: @echo "# Automatically generated Makefile for LON-CAPA" > Makefile.cd.tmp
16: @/bin/df $(CDTARGET) | perl -e '@l=<>;split(/\s+/,$$l[1]);$$s=@_[3]*1024;if ($$s>1000000000) {print "\S=1\n";} else {print "\S=0\n";}' >> Makefile.cd.tmp
17: @echo "cd:" >> Makefile.cd.tmp
18: @echo -e "ifeq (\$$(S),1)" >> Makefile.cd.tmp
19: @echo -e "\t@echo \"There is enough disk space. Good!\"" >> Makefile.cd.tmp
20: # set up commands to copy cd image from install.lon-capa.org (wget -r)
1.19 harris41 21: @echo -e "\tcd \$$(TARGET); wget -np -N -r -l 1000 http://install.lon-capa.org/3.1/currentcdsource" >> Makefile.cd.tmp
1.14 harris41 22: @echo -e "\tcd \$$(TARGET); find ./install.lon-capa.org -name index.html | xargs rm -f" >> Makefile.cd.tmp
1.12 harris41 23: # set up cvs update commands
24: # set up cd image compilation (mkisofs)
1.15 harris41 25: @echo -e "\tcd \$$(TARGET)/install.lon-capa.org/3.1/currentcdsource/; mkisofs -v -R -T -V \"LON-CAPA and Red Hat 6.2\" -b images/boot.img -c boot.cat -o \$$(TARGET)/redhat.img ." >> Makefile.cd.tmp
1.12 harris41 26: @echo -e "else" >> Makefile.cd.tmp
27: @echo -e "\t@echo \"ERROR ******* Not enough disk space. There must be at least one gigabyte free\"" >> Makefile.cd.tmp
28: @echo -e "endif" >> Makefile.cd.tmp
1.19 harris41 29: @echo -e "\t@echo \"To mount this for something like an http network install; mount -t iso9660 -o ro,loop=/dev/loop0 /mnt/drive/redhat.img /home/harris41/public_html/mount\"" >> Makefile.cd.tmp
1.12 harris41 30: make -f Makefile.cd.tmp TARGET="$(CDTARGET)" cd
1.1 harris41 31:
32: cd_cover:
1.2 harris41 33:
1.3 harris41 34: HTML:
35: install -d HTML
36: cp ../../doc/loncapafiles/*.gif HTML
37: perl parse.pl ../../doc/loncapafiles/loncapafiles.html HTML > HTML/index.html
38:
1.8 harris41 39: status:
1.7 harris41 40: install -d HTML
41: cp ../../doc/loncapafiles/*.gif HTML
42: perl parse.pl ../../doc/loncapafiles/loncapafiles.html status > HTML/filestatus.html
43:
1.22 harris41 44: statuspost: status
45: cp ../../doc/loncapafiles/*.gif /home/httpd/html/lon-status
46: cp HTML/filestatus.html /home/httpd/html/lon-status/filestatus.html
47:
1.33 harris41 48: rpmstatus:
49: install -d RPMSTATUS
50: rpm -qa --queryformat '%{NAME}\t%{VERSION}\t%{BUILDTIME}\n' | sort > RPMSTATUS/current.tmp
1.34 harris41 51: cat ../../doc/otherfiles/cd_rpms.txt > RPMSTATUS/standard.tmp
1.36 harris41 52: cat ../../doc/otherfiles/rpm_list.txt > RPMSTATUS/expected.tmp
53: perl rpmparse.pl RPMSTATUS/standard.tmp RPMSTATUS/current.tmp RPMSTATUS/expected.tmp > RPMSTATUS/rpmstatus.html
1.33 harris41 54:
55: rpmstatuspost: rpmstatus
56: cp RPMSTATUS/rpmstatus.html /home/httpd/html/lon-status/rpmstatus.html
57:
1.2 harris41 58: LCMakefile:
1.3 harris41 59: perl parse.pl ../../doc/loncapafiles/loncapafiles.html LCMakefile > LCMakefile
1.2 harris41 60:
1.4 harris41 61: SPEC:
62: perl parse.pl ../../doc/loncapafiles/loncapafiles.html SPEC
1.7 harris41 63:
1.37 ! albertel 64: configinstall: Makefile.configinstall
1.9 harris41 65: # there is a dependency on having directories in place, but oh well...
1.10 harris41 66: make -f Makefile.configinstall SOURCE="../.." TARGET="" configfiles
1.9 harris41 67: perl loncaparestoreconfigurations lasttimestamp
1.10 harris41 68: make -f Makefile.configinstall TARGET="" configpermissions
1.9 harris41 69:
1.37 ! albertel 70: Makefile.configinstall: ../../doc/loncapafiles/loncapafiles.html
! 71: perl parse.pl ../../doc/loncapafiles/loncapafiles.html configinstall > Makefile.configinstall
! 72:
! 73: install: build Makefile.install
1.9 harris41 74: make -f Makefile.install SOURCE="../.." TARGET="" directories
75: make -f Makefile.install SOURCE="../.." TARGET="" files
76: make -f Makefile.install SOURCE="../.." TARGET="" links
1.4 harris41 77:
1.37 ! albertel 78: Makefile.install: ../../doc/loncapafiles/loncapafiles.html
! 79: perl parse.pl ../../doc/loncapafiles/loncapafiles.html install > Makefile.install
! 80:
! 81: build: Makefile.build
! 82: make -f Makefile.build all
! 83:
! 84: Makefile.build: ../../doc/loncapafiles/loncapafiles.html
1.8 harris41 85: perl parse.pl ../../doc/loncapafiles/loncapafiles.html build > Makefile.build
86:
1.6 harris41 87: RPM: BinaryRoot
88: cat base_file_list.txt | perl make_rpm.pl base 3.1 '' '' BinaryRoot
1.20 harris41 89: cat setup_file_list.txt | perl make_rpm.pl setup 3.1 '' '' BinaryRoot
1.32 harris41 90: cp LON-CAPA-base-3.1-1.i386.rpm $(CDFSLOC)/RedHat/RPMS/.
91: cp LON-CAPA-setup-3.1-1.i386.rpm $(CDFSLOC)/RedHat/RPMS/.
1.6 harris41 92:
93: BinaryRoot:
1.5 harris41 94: perl parse.pl ../../doc/loncapafiles/loncapafiles.html BinaryRoot
95:
1.23 harris41 96: loncapaconfig:
97: rm -Rf LoncapaconfigRoot
98: install -d LoncapaconfigRoot/usr/src/
1.24 harris41 99: install -d LoncapaconfigRoot/usr/lib/python1.5/site-packages
100: install /usr/lib/python1.5/site-packages/kudzumodule.so LoncapaconfigRoot/usr/lib/python1.5/site-packages/kudzumodule.so
1.23 harris41 101: cd LoncapaconfigRoot/usr/src; cp -pR /mnt/drive/loncapaconfig .
102: install -d LoncapaconfigRoot/usr/sbin
103: @echo -e "#!/bin/sh\ncd /usr/src/loncapaconfig/usr/bin; ./loncapaconfig\n" > LoncapaconfigRoot/usr/sbin/loncapaconfig
104: chmod u+x LoncapaconfigRoot/usr/sbin/loncapaconfig
1.24 harris41 105: find LoncapaconfigRoot -type d | xargs chmod o-wxr
106: find LoncapaconfigRoot -type f | xargs chmod o-wxr
107: find LoncapaconfigRoot/ -type d | grep 'src/lon' > loncapaconfig_file_list.txt
108: find LoncapaconfigRoot/ -type d | grep '^LoncapaconfigRoot/usr/lib/python1.5/site-packages' >> loncapaconfig_file_list.txt
109: find LoncapaconfigRoot/ -type f >> loncapaconfig_file_list.txt
110: cat loncapaconfig_file_list.txt | perl make_rpm.pl loncapaconfig 3.1 '' '' LoncapaconfigRoot
111: cp LON-CAPA-loncapaconfig-3.1-1.i386.rpm /mnt/drive/install.lon-capa.org/3.1/currentcdsource/RedHat/RPMS/.
1.23 harris41 112:
1.31 harris41 113: install.lon-capa.org: cvsreport
1.26 harris41 114: install -d docs
1.31 harris41 115: install ../../doc/build/cvsreport.html docs/cvsreport.html
1.26 harris41 116: install ../../doc/build/doc.html docs/index.html
117: install -d docs/hardware
1.27 harris41 118: install ../../doc/hardware/hardware.html docs/hardware/hardware.html
1.26 harris41 119: install -d docs/3.1
120: install ../../doc/build/install.html docs/3.1/index.html
1.29 harris41 121: install ../../doc/build/instructions_with_cd.html docs/3.1/instructions_with_cd.html
122: install ../../doc/build/libraryserverconfiguration.gif docs/3.1/libraryserverconfiguration.gif
123: install ../../doc/build/librarysystemsettings.gif docs/3.1/librarysystemsettings.gif
1.35 harris41 124: install -d docs/cvsupgrade
125: install ../../doc/build/cvsupgrade.html docs/cvsupgrade/index.html
1.26 harris41 126: install -d docs/upgrade
1.35 harris41 127: install ../../doc/build/upgrade.html docs/upgrade/index.html
1.26 harris41 128: install -d docs/reconfig
129: install ../../doc/build/reconfig.html docs/reconfig/index.html
1.27 harris41 130: install -d docs/3.1/otherfiles
1.26 harris41 131: install ../../doc/otherfiles/rpm_list.txt docs/3.1/otherfiles/rpm_list.txt
1.27 harris41 132: install ../../doc/build/loncapanetwork.html docs/loncapanetwork.html
133: install ../../doc/build/loncapanfs.html docs/loncapanfs.html
134: install ../../doc/build/loncapaappleshares.html docs/loncapaappleshares.html
1.28 harris41 135: install ../../doc/build/loncapasqldatabase.html docs/loncapasqldatabase.html
136: install ../../doc/build/loncapapasswords.html docs/loncapapasswords.html
137: install ../../doc/build/loncapapasswordauthentication.html docs/loncapapasswordauthentication.html
138: install ../../doc/build/loncapatimesync.html docs/loncapatimesync.html
139: install ../../doc/build/loncapamathequivalency.html docs/loncapamathequivalency.html
1.27 harris41 140: tar czvf install.lon-capa.org_docs.tar.gz docs
141: rm -Rf docs
1.26 harris41 142:
1.30 harris41 143: cvsreport:
1.31 harris41 144: echo "<H1>Automatically generated CVS report</H1>" > ../../doc/build/cvsreport.html
145: echo "<H1>LON-CAPA Software Changes from `date --date='7 days ago' +\"%Y-%m-%d\"` to `date +\"%Y-%m-%d\"`</H1>" >> ../../doc/build/cvsreport.html
146: echo "<P>Number of altered files:" >> ../../doc/build/cvsreport.html
147: cd ../..; cvs log -d ">`date --date='8 days ago' +\"%Y-%m-%d\"`" loncom CAPA doc packaging 2>/dev/null | perl loncom/build/cvsfilter.pl | grep '^Working file:' | cut -b15- | wc -l >> doc/build/cvsreport.html
148: echo "</P><P>Altered files:</P><P><PRE>" >> ../../doc/build/cvsreport.html
149: cd ../..; cvs log -d ">`date --date='8 days ago' +\"%Y-%m-%d\"`" loncom CAPA doc packaging 2>/dev/null | perl loncom/build/cvsfilter.pl | grep '^Working file:' | cut -b15- >> doc/build/cvsreport.html
150: echo "</PRE></P><P>Log entries for <B>loncom</B>:</P><PRE>" >> ../../doc/build/cvsreport.html
151: cd ../../loncom; cvs log -d ">`date --date='8 days ago' +\"%Y-%m-%d\"`" . 2>/dev/null | perl ../loncom/build/cvsfilter.pl >> ../doc/build/cvsreport.html
152: echo "</PRE></P><P>Log entries for <B>CAPA</B>:</P><PRE>" >> ../../doc/build/cvsreport.html
153: cd ../../CAPA; cvs log -d ">`date --date='8 days ago' +\"%Y-%m-%d\"`" . 2>/dev/null | perl ../loncom/build/cvsfilter.pl >> ../doc/build/cvsreport.html
154: echo "</PRE></P><P>Log entries for <B>doc</B>:</P><PRE>" >> ../../doc/build/cvsreport.html
155: cd ../../doc; cvs log -d ">`date --date='8 days ago' +\"%Y-%m-%d\"`" . 2>/dev/null | perl ../loncom/build/cvsfilter.pl >> ../doc/build/cvsreport.html
156: echo "</PRE></P><P>Log entries for <B>packaging</B>:</P><PRE>" >> ../../doc/build/cvsreport.html
157: cd ../../packaging; cvs log -d ">`date --date='8 days ago' +\"%Y-%m-%d\"`" . 2>/dev/null | perl ../loncom/build/cvsfilter.pl >> ../doc/build/cvsreport.html
158: echo "</PRE></P>" >> ../../doc/build/cvsreport.html
1.1 harris41 159: clean:
1.3 harris41 160: rm -Rf HTML
1.4 harris41 161: rm -f *.spec
162: rm -f LCMakefile
1.5 harris41 163: rm -Rf BinaryRoot
164: rm -f Makefile.BinaryRoot
1.8 harris41 165: rm -f Makefile.build
166: rm -f Makefile.install
1.21 harris41 167: rm -f Makefile.install.tmp
168: rm -f Makefile.cd.tmp
169: rm -f *.rpm
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>