[SCM] Debian packaging of libhtml-mason-perl branch, master, updated. debian/1%1.46-1-9-g1be3c96

Florian Schlichting fschlich at zedat.fu-berlin.de
Sun Nov 13 02:08:48 UTC 2011


The following commit has been merged in the master branch:
commit bacc056625a693f3c17219aeae98f4ae2755f3e8
Author: Florian Schlichting <fschlich at zedat.fu-berlin.de>
Date:   Fri Nov 11 23:10:36 2011 +0000

    brush up remaining examples files

diff --git a/debian/libhtml-mason-perl-doc.README.Debian b/debian/libhtml-mason-perl-doc.README.Debian
new file mode 100644
index 0000000..fdc3207
--- /dev/null
+++ b/debian/libhtml-mason-perl-doc.README.Debian
@@ -0,0 +1,30 @@
+Enabling HTML::Mason examples
+=============================
+
+This package provides an example configuration file, CGI handler and
+component tree. If you have Apache installed, these can be enabled to be
+visible at http://localhost/mason_example/index.html by following a few
+steps:
+
+- copy the mason_example directory to /var/www/
+- copy mason_apache2_example.conf to /etc/apache2/conf.d/ 
+
+If you're running under mod_perl (package libapache2-mod-perl2), reload
+Apache and you're done. To run as a CGI, you'll also need the following
+additional steps:
+
+- copy mason_example.cgi to /usr/lib/cgi-bin/
+- make it executable with 'chmod +x /usr/lib/cgi-bin/mason_example.cgi'
+- enable mod_actions with 'a2enmod actions'
+- restart Apache with 'service apache restart'
+
+You should then be able to see the components at
+
+    http://localhost/mason_example/index.html
+
+Note that the included server configuration files are intended to work
+in many different scenarios, and thus are not intended for general
+use. Further, they were created for an older version of Mason, and may
+not reflect current best practices. For instructions on configuring
+Mason for your webserver, please see the README.Debian in the main
+libhtml-mason-perl package, as well as the HTML::Mason::Admin manual.
diff --git a/debian/libhtml-mason-perl-doc.examples b/debian/libhtml-mason-perl-doc.examples
index 763c02b..01de2f8 100644
--- a/debian/libhtml-mason-perl-doc.examples
+++ b/debian/libhtml-mason-perl-doc.examples
@@ -1,3 +1,6 @@
 samples
 eg
 debian/mason_example
+debian/mason_example.cgi
+debian/mason_apache2_example.conf
+debian/masontest.html
diff --git a/debian/libhtml-mason-perl-examples.README.Debian b/debian/libhtml-mason-perl-examples.README.Debian
deleted file mode 100644
index 409951f..0000000
--- a/debian/libhtml-mason-perl-examples.README.Debian
+++ /dev/null
@@ -1,58 +0,0 @@
-HTML::Mason examples Debian package
-===================================
-
-This package provides an example configuration file, CGI handler and
-component tree. If you have Apache installed, these can be
-automatically enabled to be visible at
-http://localhost/mason_example/. You should have been asked about this
-as the package got installed-- if not, try "dpkg-reconfigure
-libhtml-mason-perl-examples".
-
-Note that the included server configuration files are intended to work
-in many different scenarios, and thus are not intended for general
-use. Further, they were created for an older version of Mason, and may
-not reflect current best practices. For instructions on configuring
-Mason for your webserver, please see the README.Debian in the main
-libhtml-mason-perl package.
-
-If you have mod_perl enabled in your server, you should be able to see
-the same components at two different locations:
-
-    http://localhost/mason_example/
-    http://localhost/mason_example_cgi/
-
-The second location works by redirecting all requests via a CGI. This
-lets you get a feel for the speed difference. You can also try
-installing speedy-cgi-perl, and changing the shebang (first) line of
-/usr/lib/cgi-bin/mason_example.cgi to "#!/usr/bin/speedy".
-
-In order to get this second location available, you need mod_rewrite
-enabled in your server. The install script will *NOT* do this
-automatically for you. Try:
-
-    modules-config apache$VARIANT enable mod_rewrite
-
-with Apache 1*, or
-
-    a2enmod rewrite
-
-for Apache 2.
-
-If you do not have mod_perl installed, you will only have
-"http://localhost/mason_example/" available via CGI. Even for this,
-you need mod_actions enabled-- the install script will *NOT* do this
-automatically for you. Try:
-
-    modules-config apache$VARIANT enable mod_actions
-
-with Apache 1, or
-
-    a2enmod actions
-
-for Apache 2.
-
-*: for "apache$VARIANT", you need to write "apache-perl" if you have
-the "apache-perl" package loaded rather than using apache and
-libapache-mod-perl.
-
- -- Steve Haslam <araqnid at debian.org>, Mon Mar  8 12:41:52 2004
diff --git a/debian/libhtml-mason-perl-examples.examples b/debian/libhtml-mason-perl-examples.examples
deleted file mode 100644
index 7d55d6c..0000000
--- a/debian/libhtml-mason-perl-examples.examples
+++ /dev/null
@@ -1,6 +0,0 @@
-debian/mason_example
-debian/mason_example.cgi
-debian/mason_example.conf
-debian/mason_apache2_example.conf
-debian/masontest.html
-debian/speedycgi-handler.cgi
diff --git a/debian/libhtml-mason-perl.README.Debian b/debian/libhtml-mason-perl.README.Debian
index 15a5c2b..102abc6 100644
--- a/debian/libhtml-mason-perl.README.Debian
+++ b/debian/libhtml-mason-perl.README.Debian
@@ -10,8 +10,8 @@ found in [2]Mason.html, and the Administrator's Manual in
    2. http://www.masonhq.com/docs/manual/Mason.html
    3. http://www.masonhq.com/docs/manual/Admin.html
 
-Some basic Mason examples can be found in the
-libhtml-mason-perl-examples package.
+Some basic Mason examples can also be found in the
+libhtml-mason-perl-doc package.
 
 Using HTML::Mason with mod_perl
 -------------------------------
@@ -81,8 +81,7 @@ Or equivilantly:
         SetHandler html-mason
     </Location>
 
-Create /usr/lib/cgi-bin/speedycgi-handler.cgi (available in the
-libhtml-mason-perl-examples package):
+Create /usr/lib/cgi-bin/speedycgi-handler.cgi like so:
 
 ====
 #!/usr/bin/speedy
diff --git a/debian/mason_apache2_example.conf b/debian/mason_apache2_example.conf
index 69b3468..3892e0e 100644
--- a/debian/mason_apache2_example.conf
+++ b/debian/mason_apache2_example.conf
@@ -10,34 +10,17 @@
             # CGI was previously required for Mason to work in Apache2
         </FilesMatch>
     </Directory>
-
-     # This chunk allows concurrent use with mod_perl *or* CGI:
-     <IfModule mod_rewrite.c>
-          RewriteEngine On
-          RewriteRule ^/mason_example_cgi/$ /usr/lib/cgi-bin/mason_example.cgi [E=PATH_INFO:/mason_example/index.html,T=application/x-httpd-cgi]
-          RewriteRule ^/mason_example_cgi/(.+)/$ /usr/lib/cgi-bin/mason_example.cgi [E=PATH_INFO:/mason_example/$1/index.html,T=application/x-httpd-cgi]
-          RewriteRule ^/mason_example_cgi/(.+) /usr/lib/cgi-bin/mason_example.cgi [E=PATH_INFO:/mason_example/$1,T=application/x-httpd-cgi]
-     </IfModule>
-     # And so http://localhost/mason_example/     uses mod_perl, and
-     #        http://localhost/mason_example_cgi/ uses CGI
-     # This is *not* the way you would normally use mason-with-cgi, see below for an easier way!
 </IfModule>
 
 <IfModule !mod_perl.c>
-
     # No mod_perl available, just use CGI
-    # We need wither mod_actions or mod_rewrite enabled to do this. What
-    # to do if the user has neither enabled?
-    # (in any case, don't present the user with a broken config)
+    # We still need mod_actions, try 'sudo a2enmod actions' if it doesn't work
     <IfModule mod_actions.c>
-        Action mason_example http://localhost/cgi-bin/mason_example.cgi
+        Action masonexample-handler /cgi-bin/mason_example.cgi
         <Directory /var/www/mason_example>
-            SetHandler mason_example
+            SetHandler masonexample-handler
         </Directory>
     </IfModule>
-    # mod_actions.c
-
 </IfModule>
-# !mod_perl.c
 
 # 2004-03-08 araqnid
diff --git a/debian/speedycgi-handler.cgi b/debian/speedycgi-handler.cgi
deleted file mode 100644
index 5866d60..0000000
--- a/debian/speedycgi-handler.cgi
+++ /dev/null
@@ -1,11 +0,0 @@
-#!/usr/bin/speedy
-# -*- perl -*-
-
-use HTML::Mason::CGIHandler;
-
-BEGIN { warn "Loading speedycgi-handler.cgi"; };
-warn "Executing speedycgi-handler.cgi";
-
-my $h = HTML::Mason::CGIHandler->new(data_dir => "/var/cache/mason" );
-
-$h->handle_request;

-- 
Debian packaging of libhtml-mason-perl



More information about the Pkg-perl-cvs-commits mailing list