Author: bdubbs
Date: Tue Apr 5 10:50:31 2016
New Revision: 17224
Log:
Update script for bably and gegl
Modified:
trunk/scripts/blfs-chapter10.php
Modified: trunk/scripts/blfs-chapter10.php
==============================================================================
--- trunk/scripts/blfs-chapter10.php Tue Apr 5 03:58:34 2016 (r17223)
+++ trunk/scripts/blfs-chapter10.php Tue Apr 5 10:50:31 2016 (r17224)
@@ -11,7 +11,7 @@
$renames = array();
$ignores = array();
-//$current="graphite2"; // For debugging
+//$current="gegl"; // For debugging
$regex = array();
$regex[ 'aalib' ] = "/^.*Download aalib-([\d\.]+rc\d).tar.*$/";
@@ -155,10 +155,7 @@
// Check for ftp
if ( preg_match( "/^ftp/", $dirpath ) )
{
- // babl and similar
- if ( $book_index == "babl" ||
- $book_index == "gegl" ||
- $book_index == "libart_lgpl" )
+ if ( $book_index == "libart_lgpl" )
{
// Get the max directory and adjust the directory path
$dirpath = rtrim ( $dirpath, "/" ); // Trim any trailing slash
@@ -187,6 +184,19 @@
$dirpath .= "/$dir/";
}
+ // babl and similar
+ if ( $book_index == "babl" ||
+ $book_index == "gegl" )
+ {
+ // Get the max directory and adjust the directory path
+ $dirpath = rtrim ( $dirpath, "/" ); // Trim any trailing slash
+ $position = strrpos( $dirpath, "/" );
+ $dirpath = substr ( $dirpath, 0, $position );
+ $lines = http_get_file( $dirpath );
+ $dir = find_max( $lines, "/\d[\d\.]+\//", "/^.*(\d[\d\.]+)\/.*$/" );
+ $dirpath .= "/$dir/";
+ }
+
// Customize http directories as needed
$lines = http_get_file( $dirpath );
if ( ! is_array( $lines ) ) return $lines;
--
http://lists.linuxfromscratch.org/listinfo/blfs-book
FAQ: http://www.linuxfromscratch.org/blfs/faq.html
Unsubscribe: See the above information page