3 |
|
|
4 |
|
include Config.inc |
5 |
|
|
6 |
< |
all : build |
6 |
> |
.PHONY : all |
7 |
> |
all : dist |
8 |
|
|
9 |
< |
genidl : |
9 |
< |
cd idl && $(MAKE) idl |
9 |
> |
### Code Building |
10 |
|
|
11 |
< |
buildidl : genidl |
12 |
< |
cd idl && $(MAKE) build |
11 |
> |
.PHONY : build |
12 |
> |
build : $(IDLCHECK) |
13 |
> |
cd uk/org/iscream/cms/server && $(MAKE) all |
14 |
> |
cd $(BUILD) && $(MAKE) package |
15 |
|
|
16 |
< |
code : genidl |
15 |
< |
cd uk/ac/ukc/iscream && $(MAKE) all |
16 |
> |
### Source, Doc, & Changelog |
17 |
|
|
18 |
< |
build : buildidl code |
19 |
< |
cd build && $(MAKE) package |
18 |
> |
.PHONY : src |
19 |
> |
src : $(SRCCHECK) |
20 |
|
|
21 |
< |
run : build |
22 |
< |
cd build && ./run.sh |
21 |
> |
.PHONY : mksrc |
22 |
> |
mksrc : |
23 |
> |
if test ! -d "$(SRCDIR)"; then mkdir -p $(SRCDIR); fi |
24 |
> |
echo "CVS" > TAR_EXCLUDE_TMP |
25 |
> |
echo ".#*" >> TAR_EXCLUDE_TMP |
26 |
> |
echo "*.jar" >> TAR_EXCLUDE_TMP |
27 |
> |
tar -cf - -X TAR_EXCLUDE_TMP $(SRCFILES) | ( cd $(SRCDIR) && tar -xf - ) |
28 |
> |
rm -f TAR_EXCLUDE_TMP |
29 |
> |
@touch $(SRCCHECK) |
30 |
|
|
31 |
+ |
.PHONY : javadoc |
32 |
+ |
javadoc : $(JAVADOCCHECK) |
33 |
+ |
|
34 |
+ |
.PHONY : mkjavadoc |
35 |
+ |
mkjavadoc : $(IDLCHECK) |
36 |
+ |
if test ! -d "$(DOCDIR)"; then mkdir -p $(DOCDIR); fi |
37 |
+ |
if test ! -d "$(DOCTMPDIR)"; then mkdir -p $(DOCTMPDIR); fi |
38 |
+ |
cp -R $(SOURCEROOT)/uk $(DOCTMPDIR) |
39 |
+ |
cp -R $(SOURCEROOT)/idl/uk $(DOCTMPDIR) |
40 |
+ |
$(JAVADOCBIN) -d $(DOCDIR) -sourcepath $(DOCTMPDIR) -classpath $(JCCLASSPATH) -windowtitle $(JDTITLE) -author -version -private -use -header $(JDHEADER) -bottom $(JDBOTTOM) -linkoffline $(JDJAPI) $(JDJAPIC) -linkoffline $(JDPBAPI) $(JDPBAPIC) $(PKGLIST) |
41 |
+ |
rm -Rf $(DOCTMPDIR) |
42 |
+ |
@touch $(JAVADOCCHECK) |
43 |
+ |
|
44 |
+ |
.PHONY : changelog |
45 |
+ |
changelog : $(CHANGELOG) |
46 |
+ |
|
47 |
+ |
.PHONY : mkchangelog |
48 |
+ |
mkchangelog : |
49 |
+ |
if [ -d $(SOURCEROOT)/CVS ]; then \ |
50 |
+ |
$(CVS2CL) $(CVS2CLFLAGS) > $(CHANGELOG); \ |
51 |
+ |
else \ |
52 |
+ |
echo "Can't generate ChangeLog from non-checked out copy." > $(CHANGELOG); \ |
53 |
+ |
fi |
54 |
+ |
|
55 |
+ |
### Dist Making |
56 |
+ |
|
57 |
+ |
.PHONY : dist |
58 |
+ |
dist : |
59 |
+ |
cd $(BUILD) && $(MAKE) dist dest=$(DISTDEST) |
60 |
+ |
|
61 |
+ |
.PHONY : dist-bin |
62 |
+ |
dist-bin : |
63 |
+ |
cd $(BUILD) && $(MAKE) dist-bin dest=$(DISTDEST) |
64 |
+ |
|
65 |
+ |
### Code Cleaning |
66 |
+ |
|
67 |
+ |
.PHONY : clean |
68 |
|
clean : |
69 |
|
cd idl && $(MAKE) clean |
70 |
< |
cd build && $(MAKE) clean |
71 |
< |
cd uk/ac/ukc/iscream && $(MAKE) clean |
72 |
< |
rm -Rf $(BUILDCHECK) $(IDLCHECK) |
73 |
< |
rm -Rf $(CVSBUILDTEMP) |
29 |
< |
rm -Rf doc doctemp |
70 |
> |
cd $(BUILD) && $(MAKE) clean ver=$(VERSION) |
71 |
> |
cd uk/org/iscream/cms/server && $(MAKE) clean |
72 |
> |
rm -f $(MCOMPILECHECK) $(JAVADOCCHECK) $(SRCCHECK) |
73 |
> |
rm -Rf $(DOCTMPDIR) |
74 |
|
|
75 |
+ |
.PHONY : distclean |
76 |
|
distclean : clean |
77 |
|
cd $(BUILD) && rm -f $(CLPATH) |
78 |
+ |
rm -Rf $(APICACHE) |
79 |
|
rm -f Config.inc |
80 |
|
|
81 |
< |
install : build |
81 |
> |
### Util Package |
82 |
> |
|
83 |
> |
.PHONY : buildutil |
84 |
> |
buildutil : clean |
85 |
> |
cd uk/org/iscream/cms/server/util && $(MAKE) all |
86 |
> |
cd $(BUILD) && $(MAKE) packageutil |
87 |
> |
|
88 |
> |
### Database |
89 |
> |
|
90 |
> |
.PHONY : createtable |
91 |
> |
createtable : |
92 |
> |
cd db && $(MAKE) create |
93 |
> |
|
94 |
> |
.PHONY : droptable |
95 |
> |
droptable : |
96 |
> |
cd db && $(MAKE) drop |
97 |
> |
|
98 |
> |
### Install |
99 |
> |
|
100 |
> |
.PHONY : install |
101 |
> |
install : $(MCOMPILECHECK) |
102 |
|
@echo "-------------------------------------------------------" |
103 |
|
@echo "Installing to $(INSTALL)" |
104 |
|
@echo " copying $(PACKAGE) to $(INSTALL)" |
117 |
|
@echo "Completed install to $(INSTALL)" |
118 |
|
@echo "-------------------------------------------------------" |
119 |
|
|
120 |
< |
cvsbuild : |
55 |
< |
$(CVS) -d $(CVSROOT) export -r $(REVISION) -d $(CVSBUILDTEMP) $(CVSSERVERMODULE) |
56 |
< |
cd $(CVSBUILDTEMP) && ./configure |
57 |
< |
cd $(CVSBUILDTEMP) && $(MAKE) buildutil |
58 |
< |
cd $(CVSBUILDTEMP) && $(MAKE) build |
59 |
< |
cp $(CVSBUILDTEMP)/build/$(TARGZFILE) $(BUILD)/$(ARCNAME)-$(REVISION)$(TARGZEXT) |
60 |
< |
cp $(CVSBUILDTEMP)/build/$(ZIPFILE) $(BUILD)/$(ARCNAME)-$(REVISION)$(ZIPEXT) |
61 |
< |
cp $(CVSBUILDTEMP)/build/$(UTILPACKAGE) $(BUILD) |
120 |
> |
### Other |
121 |
|
|
122 |
< |
javadoc : genidl |
123 |
< |
if test ! -d "$(DOCDIR)"; then mkdir $(DOCDIR); fi |
124 |
< |
if test ! -d "$(DOCTMPDIR)"; then mkdir $(DOCTMPDIR); fi |
66 |
< |
cp -R $(SERVERROOT)/uk $(SERVERROOT)/$(DOCTMPDIR) |
67 |
< |
cp -R $(SERVERROOT)/idl/uk $(SERVERROOT)/$(DOCTMPDIR) |
68 |
< |
javadoc -d $(SERVERROOT)/$(DOCDIR) -sourcepath $(SERVERROOT)/$(DOCTMPDIR) -classpath $(JCCLASSPATH) -author -version -private $(PKGLIST) |
69 |
< |
rm -Rf doctemp |
122 |
> |
.PHONY : run |
123 |
> |
run : $(MCOMPILECHECK) |
124 |
> |
cd $(BUILD) && ./run.sh |
125 |
|
|
126 |
< |
buildutil : clean |
72 |
< |
cd uk/ac/ukc/iscream/util && $(MAKE) all |
73 |
< |
cd build && $(MAKE) packageutil |
126 |
> |
### Global Include |
127 |
|
|
128 |
|
include $(MKINC) |