]> Frank Brehm's Git Trees - profitbricks/jenkins-build-scripts.git/commitdiff
correct pathes
authorHolger Levsen <holger@layer-acht.org>
Wed, 9 Nov 2011 16:19:10 +0000 (17:19 +0100)
committerHolger Levsen <holger@layer-acht.org>
Wed, 9 Nov 2011 16:19:10 +0000 (17:19 +0100)
kernel_build.py
kernel_inpbuilder.py

index 24024ad63521a79225c265c5ae88070440c4452e..30db504a8093c4f7aeeefbaf101e641f17cecccc 100644 (file)
@@ -63,7 +63,7 @@ def build_kernel_with_pbuilder(revision, pbuilder_script, dist='stable'):
             '--git-branch-name', '%s' %(GIT_BRANCH_NAME),
             '--revision', '%s' %(revision),
             '--dist', '%s' %(dist),
-            '--overlay-dir', '%s' % os.path.join(CWD,'kernel-package-overlay'),
+            '--overlay-dir', '%s' % os.path.join(sys.path[0],'kernel-package-overlay'),
     ]
 
     os.environ.update({'DIST': '%s' %(dist)})
index efe1297aafb9d65a2eb5a8582da0b3ca8fa77c40..4116f628dc511abb925417f0d7b9d2f8dcdba067 100644 (file)
@@ -352,8 +352,8 @@ if __name__ == '__main__':
 
     OVERLAY_DIR = options.overlay_dir or '/usr/share/kernel-package'
 
-    # add current dir to python search path
-    cmd_folder = os.path.join(os.path.abspath(OVERLAY_DIR), '..')
+    # add directory where current script is in to python search path
+    cmd_folder = sys.path[0]
     sys.path.insert(0, cmd_folder)
     os.environ['WORKSPACE']=cmd_folder  # needed by kernel_persistence
     import kernel_persistence