[Pkg-mono-svn-commits] [SCM] xsp branch, master, updated. debian/2.6.5-3-42-g87885a0

Jo Shields directhex at apebox.org
Mon Mar 28 07:59:54 UTC 2011


The following commit has been merged in the master branch:
commit da96272c41ac9d7d00fad111c5b716a141e8c000
Author: Jo Shields <directhex at apebox.org>
Date:   Sun Mar 27 21:16:44 2011 +0100

    Update to 4.0, and rename Debian XSP manglement scripts, to remove useless ".conf" filename which is only removed anyway

diff --git a/debian/mono-apache-server2.install b/debian/mono-apache-server2.install
index 922cc47..ec52cd9 100644
--- a/debian/mono-apache-server2.install
+++ b/debian/mono-apache-server2.install
@@ -1,5 +1,5 @@
 debian/tmp/usr/lib/mono/2.0/mod-mono-server2.exe
 debian/tmp/usr/lib/mono/gac/mod-mono-server2
 debian/tmp/usr/bin/mod-mono-server2
-debian/tmp/usr/sbin/mono-server2-admin
-debian/tmp/usr/sbin/mono-server2-update
+debian/mono-server2-admin	/usr/sbin/
+debian/mono-server2-update	/usr/sbin/
diff --git a/debian/mono-apache-server4.install b/debian/mono-apache-server4.install
index cdd8f64..6aca5a3 100644
--- a/debian/mono-apache-server4.install
+++ b/debian/mono-apache-server4.install
@@ -1,5 +1,5 @@
 debian/tmp/usr/lib/mono/4.0/mod-mono-server4.exe
 debian/tmp/usr/lib/mono/gac/mod-mono-server4
 debian/tmp/usr/bin/mod-mono-server4
-debian/tmp/usr/sbin/mono-server4-admin
-debian/tmp/usr/sbin/mono-server4-update
+debian/mono-server4-admin	/usr/sbin/
+debian/mono-server4-update	/usr/sbin/
diff --git a/debian/mono-server2-admin.conf b/debian/mono-server2-admin
similarity index 100%
rename from debian/mono-server2-admin.conf
rename to debian/mono-server2-admin
diff --git a/debian/mono-server2-update.conf b/debian/mono-server2-update
similarity index 100%
rename from debian/mono-server2-update.conf
rename to debian/mono-server2-update
diff --git a/debian/mono-server-admin.conf b/debian/mono-server4-admin
similarity index 78%
rename from debian/mono-server-admin.conf
rename to debian/mono-server4-admin
index 8d9c914..7001bd1 100755
--- a/debian/mono-server-admin.conf
+++ b/debian/mono-server4-admin
@@ -1,10 +1,10 @@
 #!/usr/bin/perl
-# mono-server hosts file creator
+# mono-server4 hosts file creator
 #
 # With this script the user can create a host file in one step, 
-# these hosts file are installed in /etc/mono-server/conf.d/package and 
-# then used in a 'big' host file (/etc/mono-server/mono-server*-hosts.conf) 
-# that will be used by mono-server
+# these hosts file are installed in /etc/mono-server4/conf.d/package and 
+# then used in a 'big' host file (/etc/mono-server4/mono-server2-hosts.conf) 
+# that will be used by mono-server4
 #
 # Under GPL, please read: 
 # http://www.gnu.org/copyleft/gpl.html
@@ -13,17 +13,17 @@
 
 =head1 NAME
 
-mono-server-admin - mono-server hosts file creator, hosts file is part of the debianized mod_mono package
+mono-server4-admin - mono-server4 hosts file creator, hosts file is part of the debianized mod_mono package
     
 =head1 SYNOPSIS
     
-mono-server-admin.conf [action] [args]
+mono-server4-admin [action] [args]
 
 =head2 OPTIONS
 
   Actions:
     
-    add        Use 'add' if you want to create an application and want mono-server scripts to manage it
+    add        Use 'add' if you want to create an application and want mono-server4 scripts to manage it
     del        If you want to remove an application
 
   Args:
@@ -36,16 +36,16 @@ mono-server-admin.conf [action] [args]
 
 =head1 DESCRIPTION
 
- mono-server-admin.conf is a perl tool to adminstrate your ASP.NET webapps that will be executed with 
+ mono-server4-admin is a perl tool to adminstrate your ASP.NET webapps that will be executed with 
  mod_mono.
 
- When you try to add an application, admin.conf will verify that your path exists, if it is, it will 
- add a directory inside /etc/xsp/conf.d with the name of your app, and also as a file with the 
+ When you try to add an application, mono-server4-admin  will verify that your path exists, if it is, 
+ it will add a directory inside /etc/xsp/conf.d with the name of your app, and also as a file with the 
  filename format: 10_appname. This file will have the information (path, app).
 
- So, when mono-xsp-update.conf is executed it will read those dirs and create a debian.webapp in
- /etc/xsp that the xsp daemon will read, also with a mono-server-hosts.conf that will have your 
- directory settings with apache directives. Apache will read mono-server-hosts.conf!
+ So, when mono-xsp-update is executed it will read those dirs and create a debian.webapp in
+ /etc/xsp that the xsp daemon will read, also with a mono-server4-hosts that will have your 
+ directory settings with apache directives. Apache will read mono-server4-hosts.conf!
 
 =head1 AUTHOR
 
@@ -61,7 +61,7 @@ my (%OPT);
 $OPT{'port'} = "80";
 $OPT{'vhost'} = "*";
 
-my $confd_directory = "/etc/mono-server/conf.d";
+my $confd_directory = "/etc/mono-server4/conf.d";
 
 #Read the opts
 foreach my $opt (@ARGV) {
@@ -163,7 +163,7 @@ sub add_host() {
     }
     close(PACKAGEFILE);
     
-    system("/usr/sbin/mono-server-update.conf");
+    system("/usr/sbin/mono-server4-update");
     print "done!\n";
 }
 
@@ -171,20 +171,20 @@ sub add_host() {
 sub del_host() {
     
     system("rm -Rf $confd_directory/$OPT{'app'}");
-    system("/usr/sbin/mono-server-update.conf");
+    system("/usr/sbin/mono-server4-update");
     
     print "done!\n";
 }
     
 sub help() {
     print "This script let the user to create a application host file in one step \n";
-    print "for mono-server (/etc/mono-server/conf.d/application\n\n";
+    print "for mono-server4 (/etc/mono-server4/conf.d/application\n\n";
     print "Use:\n";
-    print " mono-server-admin.conf [action] --path=/real/path --app=/applicationame\n\n";
+    print " mono-server4-admin [action] --path=/real/path --app=/applicationame\n\n";
     print "Where:\n";
     print " action:\n";
     print " add                   Creates an application\n";
-    print " del                   Delete an application (the directory /etc/mono-server/conf.d/application\n";
+    print " del                   Delete an application (the directory /etc/mono-server4/conf.d/application\n";
     print " --path=/real/path     A real and true path where you have your ASP.NET applicatio running\n";
     print " --app=/application    The name of the application\n";
     print " --libs=/libs          If you have your libs out of path\n";
@@ -201,8 +201,3 @@ if($OPT{'action'} eq "add") {
 elsif($OPT{'action'} eq "del") {
     &del_host;
 }
-
-    
-
-
-
diff --git a/debian/mono-server-update.conf b/debian/mono-server4-update
similarity index 71%
rename from debian/mono-server-update.conf
rename to debian/mono-server4-update
index ac50d6a..cd4ed38 100755
--- a/debian/mono-server-update.conf
+++ b/debian/mono-server4-update
@@ -1,10 +1,10 @@
 #!/usr/bin/perl -w
-# Automatic mono-server file generator
+# Automatic mono-server4 file generator
 #
 # With this script the user can update the host files 
-# that are installed in /etc/mono-server/conf.d/package and create a 
-# 'big' host file (/etc/mono-server/mono-server*-hosts.conf) that will be used
-# by mono-server to setup the virtual hosts needed by 
+# that are installed in /etc/mono-server4/conf.d/package and create a 
+# 'big' host file (/etc/mono-server4/mono-server4-hosts.conf) that will be used
+# by mono-server4 to setup the virtual hosts needed by 
 # the user.
 #
 # Under GPL, please read: 
@@ -14,23 +14,23 @@
 
 =head1 NAME
 
-mono-server-update - creates .webapp and .host file for mod_mono and mono-server
+mono-server4-update - creates .webapp and .host file for mod_mono and mono-server4
 
 =head1 SYNOPSIS
 
-mono-server-update
+mono-server4-update
 
 =head1 DESCRIPTION
 
- mono-server-update is a perl tool to update/create a .webapp and a .host file in 
- /etc/mono-server.
+ mono-server4-update is a perl tool to update/create a .webapp and a .host file in 
+ /etc/mono-server4.
 
  These two files are needed by mod_mono (apache), they setup the alias, directory permissions, 
  and ASP.NET applications.
 
- Both files are created with other host configuration files that are in /etc/mono-server/conf.d
+ Both files are created with other host configuration files that are in /etc/mono-server4/conf.d
 
- For more information read the README.Debian of this package (/usr/share/doc/mono-server/README.Debian).
+ For more information read the README.Debian of this package (/usr/share/doc/mono-server4/README.Debian).
 
 =head1 AUTHOR
 
@@ -42,30 +42,30 @@ use strict;
 use Digest::MD5;
 
 #Main vars..
-my ($monoserver_dir, $monoserver_confd, $monoserver_hostfile, $monoserver_webapp,
+my ($monoserver4_dir, $monoserver4_confd, $monoserver4_hostfile, $monoserver4_webapp,
     $daemon, $daemon_pid, $default_file,
-    $applications, $libs, $daemon2, $daemon2_pid);
+    $applications, $libs, $daemon4, $daemon4_pid);
 
 #Setup main vars
-$monoserver_dir = "/etc/mono-server";
-$monoserver_confd = "$monoserver_dir/conf.d";
-$monoserver_webapp = "$monoserver_dir/debian.webapp";
-$monoserver_hostfile = "$monoserver_dir/mono-server-hosts.conf";
+$monoserver4_dir = "/etc/mono-server4";
+$monoserver4_confd = "$monoserver4_dir/conf.d";
+$monoserver4_webapp = "$monoserver4_dir/debian.webapp";
+$monoserver4_hostfile = "$monoserver4_dir/mono-server4-hosts.conf";
 $daemon = "/etc/init.d/apache";
 $daemon_pid = "/var/run/apache.pid";
-$daemon2 = "/etc/init.d/apache2";
-$daemon2_pid = "/var/run/apache2.pid";
+$daemon4 = "/etc/init.d/apache2";
+$daemon4_pid = "/var/run/apache2.pid";
 $applications = "";
-$default_file = "/etc/default/mono-apache-server";
+$default_file = "/etc/default/mono-apache-server4";
 $libs = "";
 
 my $restart = "yes";
 my $first_file = "yes";
 my ($orig_md5, $new_md5);
 
-#Check write access to $monoserver_hostfile
-if( ( -e "$monoserver_hostfile" && ! -w "$monoserver_hostfile" ) || ! -w "$monoserver_dir" ) {
-    print "mono-xsp-update requires write access to $monoserver_hostfile or 
+#Check write access to $monoserver4_hostfile
+if( ( -e "$monoserver4_hostfile" && ! -w "$monoserver4_hostfile" ) || ! -w "$monoserver4_dir" ) {
+    print "mono-xsp-update requires write access to $monoserver4_hostfile or 
 be executed by root\n" ; 
     exit 1 ;
 }
@@ -76,21 +76,21 @@ be executed by root\n" ;
 $orig_md5 = &get_md5;
 #Read directory..
 &read_dir;
-if(-f "$monoserver_hostfile.tmp") {
+if(-f "$monoserver4_hostfile.tmp") {
     #Prepare the application string
     $applications =~ s/,$//;
     #and the libs..
-    $libs = "/usr/lib/mono/1.0:/usr/lib:$libs"; 
+    $libs = "/usr/lib/mono/4.0:/usr/lib:$libs"; 
     $libs =~ s/:$//;
-    #sed the $monoserver_hostfile to replace the Applications
+    #sed the $monoserver4_hostfile to replace the Applications
 #    &replace_applications;
     #Replace the MONOPATH
     &replace_monopath;
     &write_tempdefault_end;
     #cp the temp file to the original one..    
-    system("cp -f $monoserver_hostfile.tmp $monoserver_hostfile");    
+    system("cp -f $monoserver4_hostfile.tmp $monoserver4_hostfile");    
     #rm the temp
-    system("rm -Rf $monoserver_hostfile.tmp");
+    system("rm -Rf $monoserver4_hostfile.tmp");
     #Final md5
     $new_md5 = &get_md5;
     #Equal?
@@ -99,16 +99,16 @@ if(-f "$monoserver_hostfile.tmp") {
 	    system("$daemon reload");
 	    system("$daemon restart");
 	}
-	if(( -f $daemon2 ) && ( -f $daemon2_pid )) {
-	    system("$daemon2 reload");
-	    system("$daemon2 restart");
+	if(( -f $daemon4 ) && ( -f $daemon4_pid )) {
+	    system("$daemon4 reload");
+	    system("$daemon4 restart");
 	}
     }
 }
 
 sub get_md5 {
-    if( -e $monoserver_hostfile ) {
-	open(HOSTFILE, $monoserver_hostfile);
+    if( -e $monoserver4_hostfile ) {
+	open(HOSTFILE, $monoserver4_hostfile);
 	binmode(HOSTFILE);
 	return Digest::MD5->new->addfile(*HOSTFILE)->hexdigest;
 	
@@ -138,16 +138,16 @@ sub read_default_file {
 
 
 sub read_dir {
-    opendir(DIR, $monoserver_confd);
-    my @host_dirs = sort (grep { -d "$monoserver_confd/$_" } readdir(DIR));
+    opendir(DIR, $monoserver4_confd);
+    my @host_dirs = sort (grep { -d "$monoserver4_confd/$_" } readdir(DIR));
     closedir(DIR);
 
     #to verify that the cfg file is new.. we should create a new one
-    system("rm -Rf $monoserver_hostfile");
-    system("touch $monoserver_hostfile");
+    system("rm -Rf $monoserver4_hostfile");
+    system("touch $monoserver4_hostfile");
     #also to the debian.webapp
-    system("rm -Rf $monoserver_webapp");
-    system("touch $monoserver_webapp");
+    system("rm -Rf $monoserver4_webapp");
+    system("touch $monoserver4_webapp");
 
     #How many dirs?
     if($#host_dirs ne "0") {
@@ -156,7 +156,7 @@ sub read_dir {
 	foreach my $dir (@host_dirs) {
 	    if(($dir ne "..") && ($dir ne ".")) {
 		#Ok, in the dir.. we have more files, so read them
-		opendir(DIR, "$monoserver_confd/$dir");
+		opendir(DIR, "$monoserver4_confd/$dir");
 		my @host_files = sort (readdir(DIR));
 		closedir(DIR);
 		#Is it empty?		
@@ -165,7 +165,7 @@ sub read_dir {
 		    foreach my $hostfile (@host_files) {
 			#Just remember.. we don't like directories inside directories!
 			if(($hostfile ne "..") && ($hostfile ne ".")) {
-			    $hostfile = "$monoserver_confd/$dir/$hostfile";
+			    $hostfile = "$monoserver4_confd/$dir/$hostfile";
 			    write_tempxsphostfile($hostfile);
 			}
 		    }
@@ -178,7 +178,7 @@ sub read_dir {
 sub replace_applications {
     local $/;
 
-    open(TEMPHOST, "$monoserver_hostfile.tmp");
+    open(TEMPHOST, "$monoserver4_hostfile.tmp");
     my $content = <TEMPHOST>;
     close(TEMPHOST);
 
@@ -189,7 +189,7 @@ sub replace_applications {
 	$content =~ s/MonoApplications//gi;
     }
     
-    open(TEMPHOST, "> $monoserver_hostfile.tmp");
+    open(TEMPHOST, "> $monoserver4_hostfile.tmp");
     print TEMPHOST $content;
     close(TEMPHOST);
 }
@@ -198,7 +198,7 @@ sub replace_applications {
 sub replace_monopath {
     local $/;
 
-    open(TEMPHOST, "$monoserver_hostfile.tmp");
+    open(TEMPHOST, "$monoserver4_hostfile.tmp");
     my $content = <TEMPHOST>;
     close(TEMPHOST);
 
@@ -209,37 +209,37 @@ sub replace_monopath {
 	$content =~ s/MonoPath default//gi;
     }
     
-    open(TEMPHOST, "> $monoserver_hostfile.tmp");
+    open(TEMPHOST, "> $monoserver4_hostfile.tmp");
     print TEMPHOST $content;
     close(TEMPHOST);
 }
 
 sub write_tempdefault_start {
-    open(TEMPHOST, ">> $monoserver_hostfile.tmp");
+    open(TEMPHOST, ">> $monoserver4_hostfile.tmp");
 
     print TEMPHOST "# Default configuration, don't edit it!\n";
     print TEMPHOST "<IfModule mod_mono.c>\n";
-    print TEMPHOST "  MonoUnixSocket default /tmp/.mod_mono_server\n";
-    print TEMPHOST "  MonoServerPath default /usr/bin/mod-mono-server\n";
+    print TEMPHOST "  MonoUnixSocket default /tmp/.mod_mono_server4\n";    
+    print TEMPHOST "  MonoServerPath default /usr/bin/mod-mono-server4\n";
     print TEMPHOST "  AddType application/x-asp-net .aspx .ashx .asmx .ascx .asax .config .ascx\n";
-    print TEMPHOST "  MonoApplicationsConfigDir default /etc/mono-server\n";
+    print TEMPHOST "  MonoApplicationsConfigDir default /etc/mono-server4\n";
     print TEMPHOST "  MonoPath default \n";
 
     close(TEMPHOST);
 
-    open(TEMPWEBAPP, ">> $monoserver_webapp");
+    open(TEMPWEBAPP, ">> $monoserver4_webapp");
     print TEMPWEBAPP "<apps>\n";
     close(TEMPWEBAPP);
     
 }
 
 sub write_tempdefault_end {
-    open(TEMPHOST, ">> $monoserver_hostfile.tmp");
+    open(TEMPHOST, ">> $monoserver4_hostfile.tmp");
     print TEMPHOST "</IfModule>\n";
     close(TEMPHOST);
 
     #Now the debian.webapp
-    open(TEMPWEBAPP, ">> $monoserver_webapp");
+    open(TEMPWEBAPP, ">> $monoserver4_webapp");
     print TEMPWEBAPP "</apps>\n";
     close(TEMPWEBAPP);
 
@@ -250,8 +250,8 @@ sub write_tempxsphostfile {
     my $hostfile = shift;
 
     #Write the content to a temp file..
-    open(TEMPHOST, ">> $monoserver_hostfile.tmp");
-    open(TEMPWEBAPP, ">> $monoserver_webapp");
+    open(TEMPHOST, ">> $monoserver4_hostfile.tmp");
+    open(TEMPWEBAPP, ">> $monoserver4_webapp");
 
     #And open the hostfile..
     open(HOSTFILE, "$hostfile");
@@ -259,7 +259,7 @@ sub write_tempxsphostfile {
     my @content_hostfile = <HOSTFILE>;
     #Close it..
     close(HOSTFILE);
-    #Write the header to the monoserver_hostfile
+    #Write the header to the monoserver4_hostfile
     
     my ($path, $alias, $vhost, $port, $name);
 
diff --git a/debian/mono-xsp1.install b/debian/mono-xsp1.install
index 843b58e..2d01f89 100644
--- a/debian/mono-xsp1.install
+++ b/debian/mono-xsp1.install
@@ -7,5 +7,5 @@ debian/tmp/usr/lib/xsp/1.0/dbsessmgr.exe
 debian/tmp/usr/lib/xsp/1.0/dbsessmgr.exe.config
 debian/tmp/usr/lib/mono/1.0/xsp.exe
 debian/tmp/usr/lib/mono/gac/xsp
-debian/tmp/usr/sbin/mono-xsp-update
-debian/tmp/usr/sbin/mono-xsp-admin
+debian/mono-xsp-update	/usr/sbin/
+debian/mono-xsp-admin	/usr/sbin/
diff --git a/debian/mono-xsp2-admin.conf b/debian/mono-xsp2-admin
similarity index 100%
rename from debian/mono-xsp2-admin.conf
rename to debian/mono-xsp2-admin
diff --git a/debian/mono-xsp2-update.conf b/debian/mono-xsp2-update
similarity index 100%
rename from debian/mono-xsp2-update.conf
rename to debian/mono-xsp2-update
diff --git a/debian/mono-xsp2.install b/debian/mono-xsp2.install
index 784d19e..2bd737b 100644
--- a/debian/mono-xsp2.install
+++ b/debian/mono-xsp2.install
@@ -7,5 +7,5 @@ debian/tmp/usr/lib/xsp/2.0/dbsessmgr2.exe
 debian/tmp/usr/lib/xsp/2.0/dbsessmgr2.exe.config
 debian/tmp/usr/lib/mono/2.0/xsp2.exe
 debian/tmp/usr/lib/mono/gac/xsp2
-debian/tmp/usr/sbin/mono-xsp2-update
-debian/tmp/usr/sbin/mono-xsp2-admin
+debian/mono-xsp2-update	/usr/sbin/
+debian/mono-xsp2-admin	/usr/sbin/
diff --git a/debian/mono-xsp-admin.conf b/debian/mono-xsp4-admin
similarity index 76%
rename from debian/mono-xsp-admin.conf
rename to debian/mono-xsp4-admin
index 254a72d..430df33 100644
--- a/debian/mono-xsp-admin.conf
+++ b/debian/mono-xsp4-admin
@@ -1,10 +1,10 @@
 #!/usr/bin/perl
-# mono-xsp hosts file creator
+# mono-xsp4 hosts file creator
 #
 # With this script the user can create a host file in one step, 
-# these hosts file are installed in /etc/xsp/conf.d/package and 
-# then used in a 'big' host file (/etc/xsp/mono-server*-hosts.conf) 
-# that will be used by XSP
+# these hosts file are installed in /etc/xsp4/conf.d/package and 
+# then used in a 'big' host file (/etc/xsp4/mono-server4-hosts) 
+# that will be used by XSP4
 #
 # Under GPL, please read: 
 # http://www.gnu.org/copyleft/gpl.html
@@ -13,17 +13,17 @@
 
 =head1 NAME
 
-mono-xsp-admin.conf - mono-xsp hosts file creator
+mono-xsp4-admin - mono-xsp4 hosts file creator
     
 =head1 SYNOPSIS
     
-mono-xsp-admin.conf [action] [args]
+mono-xsp4-admin [action] [args]
 
-=head2 OPTIONS
+=head4 OPTIONS
 
   Actions:
     
-    add        Use 'add' if you want to create an application and want mono-xsp scripts to manage it
+    add        Use 'add' if you want to create an application and want mono-xsp4 scripts to manage it
     del        If you want to remove an application
 
   Args:
@@ -33,15 +33,15 @@ mono-xsp-admin.conf [action] [args]
 
 =head1 DESCRIPTION
 
- mono-xsp-admin.conf is a perl tool to adminstrate your ASP.NET webapps that will be executed with 
- xsp.
+ mono-xsp4-admin is a perl tool to adminstrate your ASP.NET webapps that will be executed with 
+ xsp4.
 
- When you try to add an application, admin.conf will verify that your path exists, if it is, it will 
- add a directory inside /etc/xsp/conf.d with the name of your app, and also as a file with the 
+ When you try to add an application, mono-xsp4-admin will verify that your path exists, if it is, it will 
+ add a directory inside /etc/xsp4/conf.d with the name of your app, and also as a file with the 
  filename format: 10_appname. This file will have the information (path, app).
 
- So, when mono-xsp-update.conf is executed it will read those dirs and create a debian.webapp in
- /etc/xsp that the xsp daemon will read.
+ So, when mono-xsp4-update is executed it will read those dirs and create a debian.webapp in
+ /etc/xsp4 that the xsp4 daemon will read.
 
 =head1 AUTHOR
 
@@ -53,7 +53,7 @@ use strict;
 
 my (%OPT);
 
-my $confd_directory = "/etc/xsp/conf.d";
+my $confd_directory = "/etc/xsp4/conf.d";
 
 #Read the opts
 foreach my $opt (@ARGV) {
@@ -131,7 +131,7 @@ sub clean_opts() {
 	print PACKAGEFILE "alias = /$OPT{'app'}\n";
 	close(PACKAGEFILE);
 	
-	system("/usr/sbin/mono-xsp-update.conf");
+	system("/usr/sbin/mono-xsp4-update");
 	print "done!\n";
     }
 
@@ -139,16 +139,16 @@ sub clean_opts() {
     sub del_host() {
 	
 	system("rm -Rf $confd_directory/$OPT{'app'}");
-	system("/usr/sbin/mono-xsp-update.conf");
+	system("/usr/sbin/mono-xsp4-update");
 	
 	print "done!\n";
     }
     
     sub help() {
 	print "This script let the user to create a application host file in one step \n";
-	print "for XSP (/etc/xsp/conf.d/application\n\n";
+	print "for XSP4 (/etc/xsp4/conf.d/application\n\n";
 	print "Use:\n";
-	print " mono-xsp-admin.conf [action] --path=/real/path --app=/applicationame\n\n";
+	print " mono-xsp4-admin [action] --path=/real/path --app=/applicationame\n\n";
 	print "Where:\n";
 	print " action:\n";
 	print " add                   Creates an application\n";
diff --git a/debian/mono-xsp-update.conf b/debian/mono-xsp4-update
similarity index 70%
rename from debian/mono-xsp-update.conf
rename to debian/mono-xsp4-update
index 0c99c39..f9d30eb 100755
--- a/debian/mono-xsp-update.conf
+++ b/debian/mono-xsp4-update
@@ -3,7 +3,7 @@
 #
 # With this script the user can update the host files 
 # that are installed in /etc/mono-server/conf.d/package and create a 
-# 'big' host file (/etc/mono-server/mono-server*-hosts.conf) that will be used
+# 'big' host file (/etc/mono-server/mono-server4-hosts) that will be used
 # by mono-server to setup the virtual hosts needed by 
 # the user.
 #
@@ -14,22 +14,22 @@
 
 =head1 NAME
 
-mono-xsp-update.conf - creates .webapp needed by xsp
+mono-xsp4-update - creates .webapp needed by xsp4
 
 =head1 SYNOPSIS
 
-mono-xsp-update.conf
+mono-xsp4-update
 
 =head1 DESCRIPTION
 
- mono-xsp-update.conf is a perl tool to update/create a .webapp in /etc/xsp
+ mono-xsp4-update is a perl tool to update/create a .webapp in /etc/xsp4
 
- This file is needed by xsp cause it has all each ASP.NET application with a path and alias, needed 
- by xsp to setup these applications.
+ This file is needed by xsp4 cause it has all each ASP.NET application with a path and alias, needed 
+ by xsp4 to setup these applications.
 
- The .webapp is created with other host configuration files that are in /etc/xsp/conf.d
+ The .webapp is created with other host configuration files that are in /etc/xsp4/conf.d
 
- For more information read the README.Debian of this package (/usr/share/doc/mono-xsp/README.Debian).
+ For more information read the README.Debian of this package (/usr/share/doc/mono-xsp4/README.Debian).
 
 =head1 AUTHOR
 
@@ -41,26 +41,26 @@ use strict;
 use Digest::MD5;
 
 #Main vars..
-my ($monoxsp_dir, $monoxsp_confd, $monoxsp_hostfile, $monoxsp_webapp,
+my ($monoxsp4_dir, $monoxsp4_confd, $monoxsp4_hostfile, $monoxsp4_webapp,
     $daemon, $daemon_pid, $default_file,
     $applications, $libs);
 
 #Setup main vars
-$monoxsp_dir = "/etc/xsp";
-$monoxsp_confd = "$monoxsp_dir/conf.d";
-$monoxsp_webapp = "$monoxsp_dir/debian.webapp";
-$daemon = "/etc/init.d/mono-xsp1";
-$daemon_pid = "/var/run/mono-xsp1.pid";
+$monoxsp4_dir = "/etc/xsp4";
+$monoxsp4_confd = "$monoxsp4_dir/conf.d";
+$monoxsp4_webapp = "$monoxsp4_dir/debian.webapp";
+$daemon = "/etc/init.d/mono-xsp4";
+$daemon_pid = "/var/run/mono-xsp4.pid";
 $applications = "";
-$default_file = "/etc/default/mono-xsp1";
+$default_file = "/etc/default/mono-xsp4";
 
 my $restart = "yes";
 my $first_file = "yes";
 my ($orig_md5, $new_md5);
 
-#Check write access to $monoxsp_hostfile
-if( ( -e "$monoxsp_webapp" && ! -w "$monoxsp_webapp" ) || ! -w "$monoxsp_dir" ) {
-    print "mono-xsp-update.conf requires write access to $monoxsp_webapp or 
+#Check write access to $monoxsp4_hostfile
+if( ( -e "$monoxsp4_webapp" && ! -w "$monoxsp4_webapp" ) || ! -w "$monoxsp4_dir" ) {
+    print "mono-xsp4-update requires write access to $monoxsp4_webapp or 
 be executed by root\n" ; 
     exit 1 ;
 }
@@ -86,8 +86,8 @@ if(("$new_md5" ne "$orig_md5") && ($restart eq "yes")) {
 
 
 sub get_md5 {
-    if( -e $monoxsp_webapp ) {
-	open(WEBAPP, $monoxsp_webapp);
+    if( -e $monoxsp4_webapp ) {
+	open(WEBAPP, $monoxsp4_webapp);
 	binmode(WEBAPP);
 	return Digest::MD5->new->addfile(*WEBAPP)->hexdigest;
 	
@@ -117,12 +117,12 @@ sub read_default_file {
 
 
 sub read_dir {
-    opendir(DIR, $monoxsp_confd);
-    my @host_dirs = sort (grep { -d "$monoxsp_confd/$_" } readdir(DIR));
+    opendir(DIR, $monoxsp4_confd);
+    my @host_dirs = sort (grep { -d "$monoxsp4_confd/$_" } readdir(DIR));
     closedir(DIR);
 
-    system("rm -Rf $monoxsp_webapp");
-    system("touch $monoxsp_webapp");
+    system("rm -Rf $monoxsp4_webapp");
+    system("touch $monoxsp4_webapp");
 
     #How many dirs?
     if($#host_dirs ne "0") {
@@ -131,7 +131,7 @@ sub read_dir {
 	foreach my $dir (@host_dirs) {
 	    if(($dir ne "..") && ($dir ne ".")) {
 		#Ok, in the dir.. we have more files, so read them
-		opendir(DIR, "$monoxsp_confd/$dir");
+		opendir(DIR, "$monoxsp4_confd/$dir");
 		my @host_files = sort (readdir(DIR));
 		closedir(DIR);
 		#Is it empty?		
@@ -140,8 +140,8 @@ sub read_dir {
 		    foreach my $hostfile (@host_files) {
 			#Just remember.. we don't like directories inside directories!
 			if(($hostfile ne "..") && ($hostfile ne ".")) {
-			    $hostfile = "$monoxsp_confd/$dir/$hostfile";
-			    write_tempxsphostfile($hostfile);
+			    $hostfile = "$monoxsp4_confd/$dir/$hostfile";
+			    write_tempxsp4hostfile($hostfile);
 			}
 		    }
 		}
@@ -152,7 +152,7 @@ sub read_dir {
 
 sub write_tempdefault_start {
 
-    open(TEMPWEBAPP, ">> $monoxsp_webapp");
+    open(TEMPWEBAPP, ">> $monoxsp4_webapp");
     print TEMPWEBAPP "<apps>\n";
     close(TEMPWEBAPP);
     
@@ -161,24 +161,24 @@ sub write_tempdefault_start {
 
 sub write_tempdefault_end {
 
-    open(TEMPWEBAPP, ">> $monoxsp_webapp");
+    open(TEMPWEBAPP, ">> $monoxsp4_webapp");
     print TEMPWEBAPP "</apps>\n";
     close(TEMPWEBAPP);
 
 }  
 
-sub write_tempxsphostfile {
+sub write_tempxsp4hostfile {
     my $hostfile = shift;
 
     #Write the content to a temp file..
-    open(TEMPWEBAPP, ">> $monoxsp_webapp");
+    open(TEMPWEBAPP, ">> $monoxsp4_webapp");
     #And open the hostfile..
     open(HOSTFILE, "$hostfile");
     #Read it..
     my @content_hostfile = <HOSTFILE>;
     #Close it..
     close(HOSTFILE);
-    #Write the header to the monoxsp_hostfile
+    #Write the header to the monoxsp4_hostfile
     
     my ($path, $alias, $name);
 
diff --git a/debian/rules b/debian/rules
index 35b2772..6e24113 100755
--- a/debian/rules
+++ b/debian/rules
@@ -35,22 +35,22 @@ build-stamp: configure-stamp
 	$(MAKE)
 	#/usr/bin/docbook-to-man debian/xsp.sgml > xsp.1
 	pod2man --section=8 \
-		$(CURDIR)/debian/mono-server-admin.conf \
+		$(CURDIR)/debian/mono-server-admin \
 		> $(CURDIR)/debian/mono-server-admin.8
-	pod2man --section=8 $(CURDIR)/debian/mono-server-update.conf \
+	pod2man --section=8 $(CURDIR)/debian/mono-server-update \
 		> $(CURDIR)/debian/mono-server-update.8
 	pod2man --section=8 \
-		$(CURDIR)/debian/mono-server2-admin.conf \
+		$(CURDIR)/debian/mono-server2-admin \
 		> $(CURDIR)/debian/mono-server2-admin.8
-	pod2man --section=8 $(CURDIR)/debian/mono-server2-update.conf \
+	pod2man --section=8 $(CURDIR)/debian/mono-server2-update \
 		> $(CURDIR)/debian/mono-server2-update.8
-	pod2man --section=8 $(CURDIR)/debian/mono-xsp-admin.conf \
+	pod2man --section=8 $(CURDIR)/debian/mono-xsp-admin \
 		> $(CURDIR)/debian/mono-xsp-admin.8
-	pod2man --section=8 $(CURDIR)/debian/mono-xsp-update.conf \
+	pod2man --section=8 $(CURDIR)/debian/mono-xsp-update \
 		> $(CURDIR)/debian/mono-xsp-update.8
-	pod2man --section=8 $(CURDIR)/debian/mono-xsp2-admin.conf \
+	pod2man --section=8 $(CURDIR)/debian/mono-xsp2-admin \
 		> $(CURDIR)/debian/mono-xsp2-admin.8
-	pod2man --section=8 $(CURDIR)/debian/mono-xsp2-update.conf \
+	pod2man --section=8 $(CURDIR)/debian/mono-xsp2-update \
 		> $(CURDIR)/debian/mono-xsp2-update.8
 
 	cp $(CURDIR)/debian/mono-server-update.8 \
@@ -130,17 +130,6 @@ install: build
 	  for x in dh_installxsp; \
 	    do chmod +x $$x; pod2man $$x > $$x.1 ; done
 
-#	Debian control files
-	mkdir -p debian/tmp/usr/sbin
-	for f in mono-xsp-update mono-xsp-admin \
-		 mono-xsp2-update mono-xsp2-admin \
-		 mono-server-admin mono-server-update \
-	         mono-server2-admin mono-server2-update; \
-	do \
-		install -m 755 debian/$$f.conf \
-			debian/tmp/usr/sbin/$$f; \
-	done
-
 binary: binary-arch binary-indep
 
 binary-arch:

-- 
xsp



More information about the Pkg-mono-svn-commits mailing list