]> git.ipfire.org Git - thirdparty/strongswan.git/commitdiff
Renamed option 'checkout' to 'treeish'.
authorTobias Brunner <tobias@strongswan.org>
Fri, 12 Jun 2009 16:01:08 +0000 (18:01 +0200)
committerTobias Brunner <tobias@strongswan.org>
Tue, 15 Sep 2009 12:15:17 +0000 (14:15 +0200)
testing/lib/kernel_config.rb
testing/lib/strongswan_config.rb

index deb609655fe62c43c9e10507d417b404a10de5d3..913f04f4923a0df813e4d89d989d6362afb6cd9f 100644 (file)
@@ -39,7 +39,7 @@ module Dumm
         @source_path = config.path
         unless @source == :dir
           raise "'#{@source_path} is not a git repository!" unless Testing.git?(@source_path)
-          @checkout = config.checkout if Testing.git_tree?(@source_path, config.checkout)
+          @treeish = config.treeish if Testing.git_tree?(@source_path, config.treeish)
         end
       when :tar
         raise "Tarball '#{config.path}' not found!" unless Testing.tarball?(config.path)
@@ -57,8 +57,8 @@ module Dumm
       build_path = @source_path
       case @source
       when :git
-        if @checkout
-          tarball = Testing.archive_git(@source_path, @checkout, "kernel-#{@name}", Testing.build_dir)
+        if @treeish
+          tarball = Testing.archive_git(@source_path, @treeish, "kernel-#{@name}", Testing.build_dir)
           build_path = Testing.extract_tarball(tarball, Testing.build_dir)
         end
       when :tar
@@ -95,7 +95,8 @@ module Dumm
       end
     end
 
-    # Ensure that we have a kernel config.
+    # Ensure that we have a kernel config. Either set in the configuration
+    # or found in the given dir.
     def ensure_config(dir)
       config = File.join(dir, ".config")
       @config ||= config
@@ -106,7 +107,7 @@ module Dumm
     # Build the kernel and move it to the given location.
     def build_kernel(dir, kernel)
       Dir.chdir(dir) do
-        # TODO what about logging
+        # TODO what about logging and error handling
         `make clean ARCH=um 2>&1`
         # the next command might interact with the user. since '`' redirects
         # stdout we would have to use 'system'. currently we use 'yes' to
index 4eeda1ada4fbe2ad348e418a9dea5b1aa58d7e70..fbb9d427e0614aa47bf98d8533398cfb55184405 100644 (file)
@@ -32,7 +32,7 @@ module Dumm
         @source_path = config.path
         unless @source == :dir
           raise "'#{@source_path} is not a git repository!" unless Testing.git?(@source_path)
-          @checkout = config.checkout if Testing.git_tree?(@source_path, config.checkout)
+          @treeish = config.treeish if Testing.git_tree?(@source_path, config.treeish)
         end
       when :tar
         raise "Tarball '#{config.path}' not found!" unless config.path && Testing.tarball?(config.path)
@@ -50,8 +50,8 @@ module Dumm
       @build_path = File.join(Testing.build_dir, "strongswan-#{name}")
       case @source
       when :git
-        if @checkout
-          tarball = Testing.archive_git(@source_path, @checkout, "strongswan-#{@name}", Testing.build_dir)
+        if @treeish
+          tarball = Testing.archive_git(@source_path, @treeish, "strongswan-#{@name}", Testing.build_dir)
           @source_path = @build_path = Testing.extract_tarball(tarball, Testing.build_dir)
         end
       when :tar
@@ -76,8 +76,8 @@ module Dumm
   private
 
     # Run the configure script located in directory 'sources' within the
-    # directory given as 'build'. autogen.sh is run if configure does not yet
-    # exist.
+    # directory given as 'build'. autogen.sh is run if configure does not
+    # yet exist.
     def configure(sources, build)
       script = File.join(sources, "configure")
       unless File.executable?(script)