Re: [pgadmin-support] Feature request - option - Mailing list pgadmin-hackers

From Miha Radej
Subject Re: [pgadmin-support] Feature request - option
Date
Msg-id 4434CA4F.40704@siix.com
Whole thread Raw
In response to Re: [pgadmin-support] Feature request - option to exclude docs  ("Dave Page" <dpage@vale-housing.co.uk>)
List pgadmin-hackers
Hi!

So... something like this?

Regards,
Miha

Dave Page wrote:
>>> Looks good to me in principle - my only thought is that
>> --disable-docs
>>> should probably disable all docs, not just the slony and PG ones.
>>> Perhaps --disable-external-docs?
>>>
>> Agreed. A pgadmin-doc-only-without-pg-and-slony option would
>> require a different help index file without pg or slony references.
>
> That's a point - in which case, --disable-docs seems correct, except it
> should disable everything. We aren't going to start maintaining two sets
> of help indexes (damn things are pita already!).
Index: acinclude.m4
===================================================================
--- acinclude.m4    (revision 5075)
+++ acinclude.m4    (working copy)
@@ -216,6 +216,25 @@
     ])
 ])

+#################################################################################
+# Check whether to skip installation of documentation provided with pgAdmin III #
+#################################################################################
+AC_DEFUN([DISABLE_DOCS],
+[
+    AC_ARG_ENABLE(docs, [  --disable-docs        disable installation of documentation],
+    [
+        if test "$enableval" = yes
+        then
+            INSTALL_DOCS=yes
+        else
+            INSTALL_DOCS=no
+        fi
+    ],
+    [
+        INSTALL_DOCS=yes
+    ])
+])
+
 #########################################
 # Check for libpq libraries and headers #
 #########################################
@@ -447,6 +466,12 @@
     else
         echo "Building a Mac OS X appbundle:        No"
     fi
+    if test "$INSTALL_DOCS" == yes
+    then
+        echo "Include documentation:            Yes"
+    else
+        echo "Include documentation:            No"
+    fi
     echo

     echo "pgAdmin configuration is now complete. You can now compile and"
Index: configure.ac.in
===================================================================
--- configure.ac.in    (revision 5075)
+++ configure.ac.in    (working copy)
@@ -32,7 +32,9 @@
 ENABLE_DEBUG
 ENABLE_STATIC
 ENABLE_APPBUNDLE
+DISABLE_DOCS
 AM_CONDITIONAL([APPBUNDLE], [test x$BUILD_APPBUNDLE = xyes])
+AM_CONDITIONAL([INSTALL_DOCS], [test x$INSTALL_DOCS = xyes])

 LOCATE_POSTGRESQL
 SETUP_POSTGRESQL
Index: Makefile.am
===================================================================
--- Makefile.am    (revision 5075)
+++ Makefile.am    (working copy)
@@ -19,19 +19,15 @@
     $(top_srcdir)/TODO \
     $(top_srcdir)/bootstrap \
     $(top_srcdir)/configure.ac.in \
-        $(top_srcdir)/languages.hwx \
-        $(top_srcdir)/languages.po \
-        $(top_srcdir)/pgadmin3-release.pot \
-        $(top_srcdir)/pgadmin3.pot \
-        $(top_srcdir)/stringextract \
-        $(top_srcdir)/stringextract.bat \
-        $(top_srcdir)/stringmerge
+    $(top_srcdir)/languages.hwx \
+    $(top_srcdir)/languages.po \
+    $(top_srcdir)/pgadmin3-release.pot \
+    $(top_srcdir)/pgadmin3.pot \
+    $(top_srcdir)/stringextract \
+    $(top_srcdir)/stringextract.bat \
+    $(top_srcdir)/stringmerge

-TMP_docs = \
-    $(top_srcdir)/docs/en_US/pg/*.css \
-    $(top_srcdir)/docs/en_US/pg/*.html \
-    $(top_srcdir)/docs/en_US/slony/*.css \
-    $(top_srcdir)/docs/en_US/slony/*.html \
+TMP_docs_local = \
     $(top_srcdir)/docs/en_US/hints/*.html \
     $(top_srcdir)/docs/en_US/images/*.png \
     $(top_srcdir)/docs/en_US/*.html \
@@ -40,7 +36,7 @@
     $(top_srcdir)/docs/en_US/tips.txt \
     $(top_srcdir)/docs/de_DE/tips.txt \
     $(top_srcdir)/docs/de_DE/hints/*.html \
-        $(top_srcdir)/docs/es_ES/tips.txt \
+    $(top_srcdir)/docs/es_ES/tips.txt \
     $(top_srcdir)/docs/es_ES/hints/*.html \
     $(top_srcdir)/docs/fr_FR/*.html \
     $(top_srcdir)/docs/fr_FR/tips.txt \
@@ -48,6 +44,18 @@
     $(top_srcdir)/docs/sl_SI/tips.txt \
     $(top_srcdir)/docs/sl_SI/hints/*.html

+TMP_docs_external =    $(top_srcdir)/docs/en_US/pg/*.css \
+    $(top_srcdir)/docs/en_US/pg/*.html \
+    $(top_srcdir)/docs/en_US/slony/*.css \
+    $(top_srcdir)/docs/en_US/slony/*.html
+
+if INSTALL_DOCS
+TMP_docs = $(TMP_docs_local) \
+    $(TMP_docs_external)
+else
+TMP_docs =
+endif
+
 if !APPBUNDLE
 nobase_dist_pkgdata_DATA = $(TMP_docs)
 else

pgadmin-hackers by date:

Previous
From: "Dave Page"
Date:
Subject: Re: [pgadmin-support] Feature request - option to exclude docs
Next
From: svn@pgadmin.org
Date:
Subject: SVN Commit by dpage: r5076 - trunk/pgadmin3