1 |
tdb |
1.1 |
# Makefile for server |
2 |
tdb |
1.26 |
# $Id: Makefile,v 1.25 2002/06/07 16:12:47 tdb Exp $ |
3 |
tdb |
1.1 |
|
4 |
tdb |
1.8 |
include Config.inc |
5 |
tdb |
1.1 |
|
6 |
tdb |
1.25 |
all : dist |
7 |
|
|
|
8 |
|
|
### Code Building |
9 |
tdb |
1.1 |
|
10 |
tdb |
1.26 |
genidl : $(IDLCHECK) |
11 |
|
|
$(IDLCHECK) : |
12 |
tdb |
1.8 |
cd idl && $(MAKE) idl |
13 |
tdb |
1.1 |
|
14 |
tdb |
1.11 |
buildidl : genidl |
15 |
tdb |
1.8 |
cd idl && $(MAKE) build |
16 |
|
|
|
17 |
tdb |
1.25 |
build : buildidl |
18 |
tdb |
1.23 |
cd uk/org/iscream/cms/server && $(MAKE) all |
19 |
tdb |
1.25 |
cd $(BUILD) && $(MAKE) package |
20 |
|
|
|
21 |
|
|
### Source, Doc, & Changelog |
22 |
|
|
|
23 |
tdb |
1.26 |
src : $(SRCCHECK) |
24 |
|
|
$(SRCCHECK) : |
25 |
tdb |
1.25 |
if test ! -d "$(SRCDIR)"; then mkdir -p $(SRCDIR); fi |
26 |
|
|
echo "CVS" > TAR_EXCLUDE_TMP |
27 |
|
|
echo ".#*" >> TAR_EXCLUDE_TMP |
28 |
|
|
tar -cf - -X TAR_EXCLUDE_TMP $(SRCFILES) | ( cd $(SRCDIR) && tar -xf - ) |
29 |
|
|
rm -f TAR_EXCLUDE_TMP |
30 |
tdb |
1.26 |
@touch $(SRCCHECK) |
31 |
tdb |
1.25 |
|
32 |
tdb |
1.26 |
javadoc : $(JAVADOCCHECK) |
33 |
|
|
$(JAVADOCCHECK) : $(IDLCHECK) |
34 |
tdb |
1.25 |
if test ! -d "$(DOCDIR)"; then mkdir -p $(DOCDIR); fi |
35 |
|
|
if test ! -d "$(DOCTMPDIR)"; then mkdir -p $(DOCTMPDIR); fi |
36 |
|
|
cp -R $(SOURCEROOT)/uk $(DOCTMPDIR) |
37 |
|
|
cp -R $(SOURCEROOT)/idl/uk $(DOCTMPDIR) |
38 |
tdb |
1.26 |
$(JAVADOCBIN) -d $(DOCDIR) -sourcepath $(DOCTMPDIR) -classpath $(JCCLASSPATH) -windowtitle $(JDTITLE) -author -version -private -use -header $(JDHEADER) -bottom $(JDBOTTOM) -linkoffline $(JDJAPI) $(JDJAPIC) -linkoffline $(JDPBAPI) $(JDPBAPIC) $(PKGLIST) |
39 |
tdb |
1.25 |
rm -Rf $(DOCTMPDIR) |
40 |
tdb |
1.26 |
@touch $(JAVADOCCHECK) |
41 |
tdb |
1.1 |
|
42 |
tdb |
1.26 |
changelog : $(CHANGELOG) |
43 |
|
|
$(CHANGELOG) : |
44 |
tdb |
1.25 |
$(CVS2CL) $(CVS2CLFLAGS) > $(CHANGELOG) |
45 |
tdb |
1.8 |
|
46 |
tdb |
1.25 |
### Dist Making |
47 |
|
|
|
48 |
|
|
dist : build src javadoc changelog |
49 |
|
|
cd $(BUILD) && $(MAKE) dist ver=$(VERSION) dest=$(DISTDEST) |
50 |
|
|
|
51 |
|
|
dist-bin : build changelog |
52 |
|
|
cd $(BUILD) && $(MAKE) dist-bin ver=$(VERSION) dest=$(DISTDEST) |
53 |
|
|
|
54 |
|
|
### CVS Magic :) |
55 |
|
|
|
56 |
|
|
cvs-dist : |
57 |
|
|
$(CVS) -d $(CVSROOT) export -r $(CVSTAG) -d $(CVSBUILDTEMP) $(CVSSERVERMODULE) |
58 |
|
|
cd $(CVSBUILDTEMP) && ./configure |
59 |
|
|
cd $(CVSBUILDTEMP) && $(MAKE) dist ver=$(VERSION) dest=$(DISTDEST) |
60 |
|
|
|
61 |
|
|
cvs-dist-bin : |
62 |
|
|
$(CVS) -d $(CVSROOT) export -r $(CVSTAG) -d $(CVSBUILDTEMP) $(CVSSERVERMODULE) |
63 |
|
|
cd $(CVSBUILDTEMP) && ./configure |
64 |
|
|
cd $(CVSBUILDTEMP) && $(MAKE) dist-bin ver=$(VERSION) dest=$(DISTDEST) |
65 |
|
|
|
66 |
|
|
### Code Cleaning |
67 |
tdb |
1.8 |
|
68 |
tdb |
1.1 |
clean : |
69 |
tdb |
1.3 |
cd idl && $(MAKE) clean |
70 |
tdb |
1.25 |
cd $(BUILD) && $(MAKE) clean ver=$(VERSION) |
71 |
tdb |
1.23 |
cd uk/org/iscream/cms/server && $(MAKE) clean |
72 |
tdb |
1.26 |
rm -f $(BUILDCHECK) $(IDLCHECK) $(JAVADOCCHECK) $(SRCCHECK) |
73 |
|
|
rm -Rf $(CVSBUILDTEMP) $(DOCTMPDIR) |
74 |
tdb |
1.1 |
|
75 |
tdb |
1.8 |
distclean : clean |
76 |
tdb |
1.10 |
cd $(BUILD) && rm -f $(CLPATH) |
77 |
tdb |
1.26 |
rm -Rf $(APICACHE) |
78 |
tdb |
1.8 |
rm -f Config.inc |
79 |
|
|
|
80 |
tdb |
1.25 |
### Util Package |
81 |
|
|
|
82 |
|
|
buildutil : clean |
83 |
|
|
cd uk/org/iscream/cms/server/util && $(MAKE) all |
84 |
|
|
cd $(BUILD) && $(MAKE) packageutil |
85 |
|
|
|
86 |
|
|
### Database |
87 |
|
|
|
88 |
|
|
createtable : |
89 |
|
|
cd db && $(MAKE) create |
90 |
|
|
|
91 |
|
|
droptable : |
92 |
|
|
cd db && $(MAKE) drop |
93 |
|
|
|
94 |
|
|
### Install |
95 |
|
|
|
96 |
tdb |
1.8 |
install : build |
97 |
|
|
@echo "-------------------------------------------------------" |
98 |
|
|
@echo "Installing to $(INSTALL)" |
99 |
|
|
@echo " copying $(PACKAGE) to $(INSTALL)" |
100 |
|
|
mkdir -p $(INSTALL) |
101 |
|
|
cp $(BUILD)/$(PACKAGE) $(INSTALL) |
102 |
|
|
@echo " copying libs to $(INSTALL)/lib" |
103 |
|
|
mkdir -p $(INSTALL)/lib |
104 |
|
|
cp $(LIBDIR)/*.jar $(INSTALL)/lib |
105 |
|
|
@echo " copying etc to $(INSTALL)/etc" |
106 |
|
|
mkdir -p $(INSTALL)/etc |
107 |
|
|
cp $(BUILD)/etc/default.properties $(INSTALL)/etc |
108 |
|
|
cp $(BUILD)/etc/*.conf $(INSTALL)/etc |
109 |
tdb |
1.15 |
@echo " copying scripts to $(INSTALL)" |
110 |
|
|
cp $(BUILD)/run.sh $(INSTALL) |
111 |
|
|
cp $(BUILD)/run.bat $(INSTALL) |
112 |
tdb |
1.8 |
@echo "Completed install to $(INSTALL)" |
113 |
|
|
@echo "-------------------------------------------------------" |
114 |
|
|
|
115 |
tdb |
1.25 |
### Other |
116 |
tdb |
1.11 |
|
117 |
tdb |
1.25 |
run : build |
118 |
|
|
cd $(BUILD) && ./run.sh |
119 |
tdb |
1.13 |
|
120 |
tdb |
1.25 |
### Global Include |
121 |
tdb |
1.5 |
|
122 |
tdb |
1.8 |
include $(MKINC) |