# Makefile for www gateway utility
# Europagate, 1995
#
-# $Id: Makefile,v 1.41 1996/06/06 11:10:10 adam Exp $
+# $Id: Makefile,v 1.42 1997/01/24 13:13:10 adam Exp $
#
SHELL=/bin/sh
#ELIB=-lnsl -lsocket
OLIB=../lib/util.a ../lib/libres+log.a
-TCLLIB=/usr/local/lib/libtcl7.5.a
+TCLLIB=-L/usr/local/lib -ltcl8.0 -lm
TCLINC=
HSCRIPTS=egwindex.html
P4=wproto.o winterp.o waissh.o wtcl.o wirtcl.o wshmain.o wwaistcl.o
CPP=$(CC) -E
+EGWUSER=nobody
HTTPDDIR=/usr/local/etc/httpd
CGIDIR=$(HTTPDDIR)/cgi-bin
HTDOCS=$(HTTPDDIR)/htdocs
EGWDIR=$(HTTPDDIR)/egw
GIFDIR=$(HTDOCS)/egwgif
-#HTTPDDIR=/usr/local/www
-#CGIDIR=/usr/local/www/cgi-bin
-#HTDOCS=/data2/html/egw/html
-#EGWDIR=/data2/html/egw/scripts
-#GIFDIR=/data2/html/egw/gif
-
INCLUDE=-I../include $(ZINC) $(TCLINC) $(IRTCLINC)
DEFS=$(INCLUDE) $(ZDEFS) -DEGWDIR=\"$(EGWDIR)\"
echo "Making directory $(EGWDIR)"; \
mkdir $(EGWDIR); \
fi
+ @chown $(EGWUSER) $(EGWDIR)
@for x in $(TPROG1); do \
echo Installing $$x; \
cp $$x $(CGIDIR); \
- chmod a+x $(CGIDIR)/$$x; \
+ chown $(EGWUSER) $(CGIDIR)/$$x; \
+ chmod +x $(CGIDIR)/$$x; \
+ chmod u+s $(CGIDIR)/$$x; \
done; \
for x in $(TPROG2); do \
echo Installing $$x; \
- cp $$x $(EGWDIR); \
- chmod a+x $(EGWDIR)/$$x; \
+ cp $$x $(EGWDIR)/$$x; \
+ chown $(EGWUSER) $(EGWDIR)/$$x; \
+ chmod +x $(EGWDIR)/$$x; \
done; \
for p in egwtcl egwirtcl egwhtml; do \
rm -f $(EGWDIR)/$$p; \
ln $(EGWDIR)/$(TPROG2) $(EGWDIR)/$$p; \
+ chown $(EGWUSER) $(EGWDIR)/$$p; \
done
@if [ -x $(TPROG4) ]; then \
echo Installing $(TPROG4); \
cp $(TPROG4) $(EGWDIR)/$(TPROG4); \
- chmod a+x $(EGWDIR)/$(TPROG4); \
+ chmod +x $(EGWDIR)/$(TPROG4); \
+ chown $(EGWUSER) $(EGWDIR)/$(TPROG4); \
fi
install.script:
@for x in *.egw *.tcl; do \
echo Installing $$x; \
cp $$x $(EGWDIR)/$$x; \
+ chown $(EGWUSER) $(EGWDIR)/$$x; \
done
@for x in $(HSCRIPTS); do \
echo Installing $$x; \
cp $$x $(HTDOCS); \
+ chmod a+r $(HTDOCS)/$$x; \
done
@for x in $(CONFFILES); do \
echo Installing $$x; \
cp $$x $(EGWDIR); \
+ chown $(EGWUSER) $(EGWDIR)/$$x; \
done
install.gif:
@if [ ! -d $(GIFDIR) ]; then \
echo "Making directory $(GIFDIR)"; \
mkdir $(GIFDIR); \
+ chmod a+x $(GIFDIR); \
fi
- @for x in gif/*.gif; do \
+ @cd gif; for x in *.gif; do \
echo Installing $$x; \
cp $$x $(GIFDIR); \
+ chmod a+r $(GIFDIR)/$$x; \
done
.c.o: