* split make install targets in finer granulated targets
authorWilfried Göesgens <willi@citadel.org>
Sun, 7 Jan 2007 16:09:17 +0000 (16:09 +0000)
committerWilfried Göesgens <willi@citadel.org>
Sun, 7 Jan 2007 16:09:17 +0000 (16:09 +0000)
* added editor config option
* updated these to README.txt

* removed all those fixups in debina/rules
* debian: have our templates in /usr/share/citadel-webcit/
* debian: directly point to debian tinyMCE package

webcit/Makefile.in
webcit/README.txt
webcit/aclocal.m4
webcit/config.h
webcit/configure.ac
webcit/debian/control
webcit/debian/rules

index 732301c96e946995a5a91a4e646a05b12f5f741a..5d1661e1a5cf57cc22da34f7e8018ece2e57e203 100644 (file)
@@ -19,6 +19,8 @@ PROG_SUBDIRS=@PROG_SUBDIRS@
 SUBDIRS=$(LIB_SUBDIRS) $(PROG_SUBDIRS) 
 LOCALEDIR=@LOCALEDIR@
 WWWDIR=@WWWDIR@
+EDITORDIR=@EDITORDIR@
+
 # End of configuration section
 
 all: all-progs-recursive webserver setup
@@ -65,10 +67,16 @@ webserver: webserver.o context_loop.o tools.o ical_dezonify.o \
        $(LIBOBJS) $(LIBS) $(LDFLAGS) -o webserver
 
 .c.o:
-       $(CC) $(CFLAGS) $(DEFS) -c $(PTHREAD_DEFS) -DWEBCITDIR=\"$(WWWDIR)\" -DLOCALEDIR=\"$(LOCALEDIR)\" $<
+       $(CC) $(CFLAGS) $(DEFS) -c $(PTHREAD_DEFS) \
+               -DWEBCITDIR=\"$(WWWDIR)\" \
+               -DLOCALEDIR=\"$(LOCALEDIR)\" \
+               -DEDITORDIR=\"$(EDITORDIR)\" $<
 
 .cpp.o:
-       $(CC) $(CFLAGS) $(DEFS) -c $(PTHREAD_DEFS) -DWEBCITDIR=\"$(WWWDIR)\" -DLOCALEDIR=\"$(LOCALEDIR)\" $<
+       $(CC) $(CFLAGS) $(DEFS) -c $(PTHREAD_DEFS) \
+               -DWEBCITDIR=\"$(WWWDIR)\" \
+               -DLOCALEDIR=\"$(LOCALEDIR)\"  \
+               -DEDITORDIR=\"$(EDITORDIR)\"$<
 
 Makefile: $(srcdir)/Makefile.in config.status
        CONFIG_FILES=Makefile CONFIG_HEADERS= $(SHELL) ./config.status
@@ -82,29 +90,37 @@ $(srcdir)/configure: $(srcdir)/configure.ac $(srcdir)/aclocal.m4
 $(srcdir)/aclocal.m4: $(srcdir)/acinclude.m4
        cd $(srcdir) && $(ACLOCAL)
 
-install:  install-bin install-locale install-wwwdata
+install:  install-bin install-setupbin install-locale install-wwwdata install-tinymce
 
 install-bin:
-       test -d $(DESTDIR)$(prefix) || mkdir $(DESTDIR)$(prefix)
-       for i in webserver setup; do \
-               $(INSTALL) $$i $(DESTDIR)$(prefix)/$$i; \
-       done
+       test -d $(DESTDIR)$(prefix) || mkdir -p $(DESTDIR)$(prefix)
+       $(INSTALL) webserver $(DESTDIR)$(prefix)/webserver
+
+
+install-setupbin: install-bin
+       $(INSTALL) setup $(DESTDIR)$(prefix)/setup
+
 
 install-wwwdata:
-       test -d $(DESTDIR)$(prefix)/static || mkdir -p $(DESTDIR)$(prefix)/static
+       test -d $(DESTDIR)$(WWWDIR)/static || mkdir -p $(DESTDIR)$(WWWDIR)/static
+       for i in `find static -type f | grep -v .svn`; do \
+               $(INSTALL) $$i $(DESTDIR)$(WWWDIR)/$$i; \
+       done
+
+install-tinymce:
+       test -d $(DESTDIR)$(WWWDIR)/static || mkdir -p $(DESTDIR)$(WWWDIR)/static
        for i in `find tiny_mce -type d | grep -v .svn` \
                ; do \
                test -d $(DESTDIR)$(WWWDIR)/$$i || mkdir -p $(DESTDIR)$(WWWDIR)/$$i; \
        done
        for i in \
-               `find static -type f | grep -v .svn` \
                `find tiny_mce -type f | grep -v .svn` \
                ; do \
                $(INSTALL) $$i $(DESTDIR)$(WWWDIR)/$$i; \
        done
 
 install-locale:
-       test -d $(DESTDIR)$(prefix)/local || mkdir -p $(DESTDIR)$(prefix)/local
+       test -d $(DESTDIR)$(LOCALEDIR)/local || mkdir -p $(DESTDIR)$(LOCALEDIR)/local
        for i in `find locale -type d | grep -v .svn` \
                ; do \
                test -d $(DESTDIR)$(LOCALEDIR)/$$i || mkdir -p $(DESTDIR)$(LOCALEDIR)/$$i; \
index 5e1916ac0f148a964da848930f3b7924f3f7bb4c..6a8b22a57aef0c054a68caf687686a9b29192ed8 100644 (file)
@@ -296,19 +296,22 @@ Here is how to configure the "subdirectory" method:
 If you are building packages and prefer not to have WebCit reside entirely in
 a single directory, there are several compile-time options available.
 
---with-staticdir defines where webcit should locate and search its templates and images. If you
-want to go with a different installation location then the point at which it is accessed at runtime, 
-you can use --with-staticrundir. This option is meant to ease your needs if you're going
-to install the static files as 'examples' in a location like /usr/share/doc/webcit/examples, 
-and enable the user to copy them over to another dir (like /var/lib/citadel/www), where 
-they're accessed at runtime. (The debian instatll scripts provided with this package 
-do this to preserve user changes to the template system, see debian/citadel-webcit.postinstall)
+--with-wwwdir defines where webcit should locate and search its templates and images. 
+--with-localedir defines where to put webcits locale files.
 
 Also, there are possibilities to load the TinyMCE editor into a system-wide location.  WebCit 
 uses this standard component to compose its messages for messages and postings. Several WebCit installations
 that may differ in design but use the same TinyMCE (which is the default that WebCit ships with)
 (set --with-editordir for that, it defaults to the dir the templates go)
 
+Install targets have diversified to reflect these changes too:
+ (make install-.....)
+locale: the webcit .mo files for gettext & locales.
+tinymce: the editor. if your system brings one, just ommit this.
+wwwdata: our templates.
+setupbin: if you want to use webcits setup facility... but isn't needed in case you provide own init & config scripts.
+bin: the binaries.
+
 
  CONCLUSION
  ----------
index 6af4bc7fa0882385c1bf1baf77bc39563fea9dc7..af52a7f30c300ec7bf87f334390306e55302f34f 100644 (file)
@@ -1,4 +1,4 @@
-# generated automatically by aclocal 1.9.5 -*- Autoconf -*-
+# generated automatically by aclocal 1.9.6 -*- Autoconf -*-
 
 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
 # 2005  Free Software Foundation, Inc.
index ca205a300f1a6d4e16e006ecc9b6d4d8d51301c5..837193b1334e1a79e0db7c24283cb7afd56a3a2e 100644 (file)
@@ -3,7 +3,6 @@
  */
 
 #define _GNU_SOURCE
-#define EDITORDIR      WEBCITDIR "/tiny_mce"
 #define RUNDIR         WEBCITDIR
 #define BASEDIR                WEBCITDIR
 #define DATADIR                WEBCITDIR
index ba592c3d3fa16ea4d7991e731ed6549337943648..b07cd2660dc647ee3fac5dac4387ab2524e63660 100644 (file)
@@ -347,9 +347,11 @@ AC_SUBST(SETUP_LIBS)
 if test "$prefix" = NONE; then
        LOCALEDIR=$ac_default_prefix
        WWWDIR=$ac_default_prefix
+       EDITORDIR=$ac_default_prefix/tiny_mce
 else
        LOCALEDIR=$prefix
        WWWDIR=$prefix
+       EDITORDIR=$prefix/tiny_mce
 fi
 
 dnl where to put the locale files
@@ -372,6 +374,16 @@ AC_ARG_WITH(wwwdir,
 )
 AC_SUBST(WWWDIR)
 
+dnl Checks where to put our editor
+AC_ARG_WITH(editordir, 
+                   [  --with-editordir             directory to put our editor],
+                       [ if test "x$withval" != "xno" ; then
+                                                 EDITORDIR=$withval
+                         fi
+                       ]
+)
+AC_SUBST(EDITORDIR)
+
 
 AC_OUTPUT(Makefile po/Makefile )
 
index 2e689d123bf22c6489c0525806308c9b008e9832..8c1d98ddf1736db5f778ed78c2d22712441b50cf 100644 (file)
@@ -9,7 +9,7 @@ Standards-Version: 3.7.2
 Package: citadel-webcit
 Architecture: any
 Depends: ${shlibs:Depends}, ${misc:Depends}, debconf, tinymce
-Suggests: citadel-server
+Suggests: citadel-server, apache2 | apache
 Description: web-based frontend to Citadel groupware server
  WebCit is a web-based, AJAX-enabled frontend to the Citadel groupware system.
  It is an attractive web middleware layer that allows user-friendly access.
@@ -19,8 +19,3 @@ Description: web-based frontend to Citadel groupware server
  .
   Homepage: http://www.citadel.org
 
-Package: citadel-webcit-apache
-Architecture: any
-Depends: citadel-webcit, apache2 | httpd, debconf
-Description: Integrates Webcit with your local Apache
-
index d46918ae4169349a11fbacbe6a631708dde203f5..f24ca98407f7d909fac2ee70bcdd3f03736597b9 100755 (executable)
@@ -27,11 +27,10 @@ configure-stamp:
        CFLAGS="$(CFLAGS)" ./configure \
                --host=$(DEB_HOST_GNU_TYPE) \
                --build=$(DEB_BUILD_GNU_TYPE) \
-               --prefix=/etc/citadel/www/ \
+               --prefix=/usr/sbin/ \
+               --with-wwwdir=/usr/share/citadel-webcit \
                --with-localedir=/usr/share/locale \
-               --with-sysconfdir=/etc/citadel \
-               --with-spooldir=/var/spool/citadel \
-               --with-datadir=/etc/citadel \
+               --with-editordir=/usr/share/tinymce/www \
                --with-rundir=/var/run/citadel \
                --with-ical --with-db --with-ldap \
                --with-zlib --with-ssl --with-libiconf \
@@ -66,21 +65,8 @@ install: build
        dh_testroot
        dh_clean -k 
        dh_installdirs
+       $(MAKE) install-bin install-locale install-wwwdata DESTDIR=$(DESTDIR)
 
-# Add here commands to install the package into debian/webcit.
-       $(MAKE) -C . install DESTDIR=$(DESTDIR)
-# there are debian tinymce packages arround, so we don't ship it another time.
-       rm -rf $(DESTDIR)/etc/citadel/www/tiny_mce 
-# we don't use the setup anymore, omit it.
-       rm -f $(DESTDIR)/etc/citadel/www/setup
-# locale -> /usr/share/locale
-       mkdir -p $(DESTDIR)/usr/share/
-       mv $(DESTDIR)/etc/citadel/www/locale \
-               $(DESTDIR)/usr/share/locale
-
-       mkdir -p $(DESTDIR)/usr/sbin
-       mv $(DESTDIR)/etc/citadel/www/webserver \
-               $(DESTDIR)/usr/sbin/
 
 
 # Build architecture-independent files here.