+ # Add here commands to install package into
+ # debian/<package>-whatever.
+ ( cd FS/ && $(MAKE) -e DESTDIR=$(TMP)-lib install )
+
+ #false laziness w/install-perl-modules now
+ #install this for postinst later (no create-config)
+ ##install -d $(DIST_CONF)
+ #install conf/[a-z]* $(DEFAULT_CONF)
+ #CVS is not [a-z]
+ ##install `ls -d conf/[a-z]* | grep -v CVS` $(DIST_CONF)
+
+ install -d $(FREESIDE_DOCUMENT_ROOT)
+ install -d $(FREESIDE_CACHE)/masondata #MASONDATA
+ $(MAKE) -e DESTDIR=$(TMP)-webui install-docs
+
+ #hack the build dir out of Freeside too. oh yeah, sucky.
+ perl -p -i -e "\
+ s'${TMP}(-webui)?''g;\
+ " ${TMP}-webui/usr/share/freeside/handler.pl \
+ ${TMP}/usr/share/perl5/FS/* \
+ ${TMP}/usr/share/perl5/FS/*/* \
+ ${TMP}/usr/bin/*
+
+ #rm -r $(FREESIDE_DOCUMENT_ROOT).*
+
+ install -d $(APACHE_CONF)
+ #install debian/freeside.apache-alias.conf $(APACHE_CONF)/freeside-alias.conf
+ #FREESIDE_DOCUMENT_ROOT=/usr/share/freeside/www MASON_HANDLER=/usr/share/freeside/handler.pl FREESIDE_CONF=/etc/freeside $(MAKE) -e install-apache
+ $(MAKE) -e install-apache
+
+ $(MAKE) -e install-init
+
+ #RT
+ #(configure-rt)
+ $(MAKE) -e configure-rt
+
+ ## XXX need to adjust db-type, db-database, db-rt-user, db-rt-pass
+ ## based on info from dbc
+ #( cd rt; \
+ # cp config.layout.in config.layout; \
+ # perl -p -i -e "\
+ # s'%%%FREESIDE_DOCUMENT_ROOT%%%'${FREESIDE_DOCUMENT_ROOT}'g;\
+ # s'%%%MASONDATA%%%'${FREESIDE_CACHE}/masondata'g;\
+ # " config.layout; \
+ # ./configure --prefix=${RT_PATH} \
+ # --enable-layout=Freeside \
+ # --with-db-type=Pg \
+ # --with-db-dba=freeside \
+ # --with-db-database=_DBC_DBNAME_ \
+ # --with-db-rt-user=_DBC_DBUSER_ \
+ # --with-db-rt-pass=_DBC_DBPASS_ \
+ # --with-web-user=freeside \
+ # --with-web-group=freeside \
+ # --with-rt-group=freeside \
+ #)
+
+ ##(create-rt)
+ #$(MAKE) -e create-rt
+
+ #install -d $(RT_PATH)
+ #( cd rt; make install )
+ ##hack the build dir out of RT. yeah, sucky.
+ #perl -p -i -e "\
+ # s'${TMP}''g;\
+ #" ${RT_PATH}/etc/RT_Config.pm \
+ # ${RT_PATH}/lib/RT.pm \
+ # ${RT_PATH}/bin/mason_handler.fcgi \
+ # ${RT_PATH}/bin/mason_handler.scgi \
+ # ${RT_PATH}/bin/standalone_httpd \
+ # ${RT_PATH}/bin/webmux.pl \
+ # ${RT_PATH}/bin/rt-crontool \
+ # ${RT_PATH}/sbin/rt-dump-database \
+ # ${RT_PATH}/sbin/rt-setup-database
+ #
+ ##hack @INC dir out of RT (well, handler.pl) too.
+ #perl -p -i -e "\
+ # s'/opt/rt3/'/var/opt/freeside/rt/'g;\
+ #" ${TMP}-webui/usr/share/freeside/handler.pl
+
+ #mv ${RT_PATH}/etc/RT_Config.pm ${RT_PATH}/etc/RT_Config.pm.dbc
+
+ #perl -p -i -e "\
+ # s'%%%RT_DOMAIN%%%'${RT_DOMAIN}'g;\
+ # s'%%%RT_TIMEZONE%%%'${RT_TIMEZONE}'g;\
+ # s'%%%FREESIDE_URL%%%'${FREESIDE_URL}'g;\
+ #" ${RT_PATH}/etc/RT_SiteConfig.pm
+
+ #install -D debian/dbconfig-common.install $(DBC_SCRIPTS)/install/pgsql
+ #install -D debian/dbconfig-common.install $(DBC_SCRIPTS)/install/mysql
+
+ #install -D debian/dbconfig-common.upgrade $(DBC_SCRIPTS)/upgrade/pgsql/$(DEBVERSION)
+ #install -D debian/dbconfig-common.upgrade $(DBC_SCRIPTS)/upgrade/mysql/$(DEBVERSION)
+
+ dh_install
+
+ touch $@