[Lsb-messages] /var/www/bzr/lsb/devel/lsbspec r3929: consistency tweaks in two gen scripts

Mats Wichmann mats at linuxfoundation.org
Fri Aug 30 18:34:29 UTC 2013


------------------------------------------------------------
revno: 3929
committer: Mats Wichmann <mats at linuxfoundation.org>
branch nick: lsbspec
timestamp: Fri 2013-08-30 12:34:29 -0600
message:
  consistency tweaks in two gen scripts
modified:
  mkcmdlist
  mklibapnd
-------------- next part --------------
=== modified file 'mkcmdlist'
--- a/mkcmdlist	2012-11-09 14:54:01 +0000
+++ b/mkcmdlist	2013-08-30 18:34:29 +0000
@@ -20,7 +20,7 @@
 # We can get submodule id from SubModule Table. 
 # Commands list will be generated as per submodules.
 
-GetOptions("m=s" => \$module,
+GetOptions("m=s" => \$submodule,
             "v=s" => \$lsbversion);
 if( !$lsbversion ) { usage(); }
 
@@ -30,11 +30,11 @@
 my $dbh = DBI->connect('DBI:mysql:database='.$LSBDB.';host='.$LSBDBHOST, $LSBUSER, $LSBDBPASSWD)
     or die "Couldn't connect to database: ".DBI->errstr;
 
-if( !$module ) {
-    $module='LSB_Base';
+if( !$submodule ) {
+    $submodule='LSB_Base';
 }
-($moduleid) = $dbh->selectrow_array("SELECT SMid FROM SubModule WHERE SMname='$module'");
-die("Incorrect SubModule name") if not $moduleid;
+($submoduleid) = $dbh->selectrow_array("SELECT SMid FROM SubModule WHERE SMname='$submodule'");
+die("Incorrect SubModule name") if not $submoduleid;
 
 printf("<!-- Start of generated text - do not edit! -->\n");
 printf("<!-- generated from the LSB specification database by mkcmdlist -->\n");
@@ -54,7 +54,7 @@
 $select.= "LEFT JOIN SModCmd ON SMCcid=Cid ";
 $select.= "LEFT JOIN CmdStd ON CScid=Cid ";
 $select.= "LEFT JOIN Standard ON Sid=CSsid ";
-$select.= "WHERE SMCsmid=$moduleid AND SMCappearedin <= '$lsbversion' AND SMCappearedin > '' ";
+$select.= "WHERE SMCsmid=$submoduleid AND SMCappearedin <= '$lsbversion' AND SMCappearedin > '' ";
 $select.= "AND (SMCwithdrawnin IS NULL OR SMCwithdrawnin > '$lsbversion') ";
 $select.= "AND CSappearedin <= '$lsbversion' AND CSappearedin > '' ";
 $select.= "AND (CSwithdrawnin IS NULL OR CSwithdrawnin > '$lsbversion') ";

=== modified file 'mklibapnd'
--- a/mklibapnd	2012-12-06 00:17:48 +0000
+++ b/mklibapnd	2013-08-30 18:34:29 +0000
@@ -19,9 +19,9 @@
 #
 GetOptions("a=s" => \$archname,
 	   "v=s" => \$lsbversion,
-           "m=s" => \$module);
+           "m=s" => \$submodule);
 
-if( !$module ) { $module='LSB_Base'; }
+if( !$submodule ) { $submodule='LSB_Base'; }
 
 if( !$archname ) { usage(); }
 if( !$lsbversion ) { usage(); }
@@ -52,8 +52,8 @@
 #
 # 4) get & print the library info
 #
-if ( ! $module ) {
-    $module = "LSB_Base";
+if ( ! $submodule ) {
+    $submodule = "LSB_Base";
 }
 $select = "SELECT * FROM Library ";
 $select.= "LEFT JOIN ArchLib ON ALlid=Lid ";
@@ -63,7 +63,7 @@
 $select.= "AND (ALwithdrawnin IS NULL OR ALwithdrawnin > '$lsbversion') ) ";
 $select.= "AND (SMLappearedin <= '$lsbversion' AND SMLappearedin > '' ";
 $select.= "AND (SMLwithdrawnin IS NULL OR SMLwithdrawnin > '$lsbversion') ) ";
-$select.= "AND SMname='".$module."' ";
+$select.= "AND SMname='".$submodule."' ";
 
 if( $Aid != 1 ) {
 	$select.= "AND (ALaid=$Aid OR (ALaid=1 AND Lid NOT IN ( ";



More information about the lsb-messages mailing list