r708 - /scripts/supported_platforms.php

fst-guest at users.alioth.debian.org fst-guest at users.alioth.debian.org
Tue Sep 18 21:53:13 UTC 2007


Author: fst-guest
Date: Tue Sep 18 21:53:12 2007
New Revision: 708

URL: http://svn.debian.org/wsvn/pkg-boinc/?sc=1&rev=708
Log:
* Updated project list.
* Added get_project_config() function.
* Count how many projects support which architecture.

Modified:
    scripts/supported_platforms.php

Modified: scripts/supported_platforms.php
URL: http://svn.debian.org/wsvn/pkg-boinc/scripts/supported_platforms.php?rev=708&op=diff
==============================================================================
--- scripts/supported_platforms.php (original)
+++ scripts/supported_platforms.php Tue Sep 18 21:53:12 2007
@@ -10,7 +10,7 @@
     'i386' => 'i686-pc-linux-gnu',
     'ia64' => 'ia64-unknown-linux-gnu',
     'kfreebsd-amd64' => 'x86_64-pc-kfreebsd-gnu',
-    'kfreebsd-i386' => 'i486-pc-kfreebsd-gnu',
+    'kfreebsd-i386' => 'i686-pc-kfreebsd-gnu',
     'm68k' => 'm68k-unknown-linux-gnu',
     'mips' => 'mips-unknown-linux-gnu',
     'mipsel' => 'mipsel-unknown-linux-gnu',
@@ -33,6 +33,7 @@
     'depspid' => array('http://www.depspid.net/', 'DepSpid'),
     'docking' => array('http://docking.utep.edu/', 'Docking at Home'),
     'einstein' => array('http://einstein.phys.uwm.edu/', 'Einstein at Home'),
+    'eternity2' => array('http://eternity2.net/', 'Eternity2.net'),
     'hash' => array('http://boinc.banaan.org/hashclash/', 'HashClash'),
     'leiden' => array('http://boinc.gorlaeus.net/', 'Leiden Classical'),
     'lhc' => array('http://lhcathome.cern.ch/', 'LHC at home'),
@@ -54,6 +55,7 @@
     'seasonal' => array('http://attribution.cpdn.org/', 'Seasonal Attribution'),
     'seti' => array('http://setiathome.berkeley.edu/', 'SETI at home'),
     'seti_beta' => array('http://setiweb.ssl.berkeley.edu/beta/', 'SETI at home Beta'),
+    'sha1cs' => array('http://boinc.iaik.tugraz.at/sha1_coll_search/', 'SHA-1 Collision Search'),
     'simap' => array('http://boinc.bio.wzw.tum.de/boincsimap/', 'SIMAP'),
     'spinhenge' => array('http://spin.fh-bielefeld.de/', 'Spinhenge at home'),
     'superlink' => array('http://cbl-link02.cs.technion.ac.il/superlinkattechnion/', 'Superlink at Technion'),
@@ -66,20 +68,25 @@
     'wanless2' => array('http://bearnol.is-a-geek.com/wanless2/', 'WEP-M+2 Project'),
     'wcg' => array('http://www.worldcommunitygrid.org/', 'World Community Grid'),
     'xtrem' => array('http://xw01.lri.fr:4320/', 'XtremLab'),
-    'zivis' => array('http://zivis.bifi.unizar.es/', 'Zivis')
+    'yoyo' => array('http://www.rechenkraft.net/yoyo/', 'yoyo at home')
 );
 
 $xml_dir = 'apps';
+if (! is_dir($xml_dir))
+    mkdir($xml_dir);
 
 function apps_file($project) {
     global $xml_dir;
     return $xml_dir.'/'.$project.'_apps.xml';
 }
 
+function config_file($project) {
+    global $xml_dir;
+    return $xml_dir.'/'.$project.'_config.xml';
+}
+
 function get_project_apps($projects, $force_update = false) {
     global $xml_dir;
-    if (! is_dir($xml_dir))
-        mkdir($xml_dir);
 
     // Only update apps files if $xml_dir was last accessed more than 12h ago.
     if ((time() - fileatime($xml_dir)) < 12*3600 and !$force_update)
@@ -87,6 +94,13 @@
 
     foreach ($projects as $key => $project)
         copy($project[0].'apps.php?xml=1', apps_file($key));
+}
+
+function get_project_config($projects, $force_update = false) {
+    global $xml_dir;
+
+    foreach ($projects as $key => $project)
+        copy($project[0].'get_project_config.php', config_file($key));
 }
 
 function get_supported_platforms($projects) {
@@ -127,10 +141,14 @@
 function print_debian_wiki_table($projects, $supported_debian_platforms) {
     global $debian_platforms;
 
+    $count = array();
+
     // Create table headline with all Debian architectures.
     $out = '|| ||';
-    foreach ($debian_platforms as $arch => $platform)
+    foreach ($debian_platforms as $arch => $platform) {
         $out .= ' '.$arch.' ||';
+        $count[$arch] = 0;
+    }
     $out .= "\n";
 
     // Create a row for each project.
@@ -139,20 +157,28 @@
             $projects[$project][1]);
 
         foreach ($debian_platforms as $arch => $platform) {
-            if (in_array($arch, $platforms))
+            if (in_array($arch, $platforms)) {
                 $out .= '<style="background-color: #80FF80; '
                      .  'text-align: center;">x||';
+                $count[$arch]++;
+            }
             else
                 $out .= ' ||';
         }
         $out .= "\n";
     }
-    print $out;
+
+    $last_line = '|| '.count($supported_debian_platforms) .' ||';
+    foreach ($debian_platforms as $arch => $platform)
+        $last_line .= '<style="text-align: center;">'.$count[$arch] .'||';
+
+    print $out.$last_line."\n";
 }
 
 // main program logic
 
 get_project_apps($projects, true);
+//get_project_config($projects, true);
 
 $supported_platforms = get_supported_platforms($projects);
 




More information about the pkg-boinc-commits mailing list