Actions.py'nin global sembollerinden WorkDir ayıklanıyor, eğer değer varsa kullanılıyor yoksa eski paketismi-versiyon ikilisi seçiliyor
This commit is contained in:
+16
-6
@@ -53,11 +53,6 @@ class PisiBuild:
|
|||||||
#finished its work in the work_dir
|
#finished its work in the work_dir
|
||||||
curDir = os.getcwd()
|
curDir = os.getcwd()
|
||||||
|
|
||||||
# FIXME: It's wrong to assume that unpacked archive
|
|
||||||
# will create a name-version top-level directory.
|
|
||||||
# Archive module should give the exact location.
|
|
||||||
# (from the assumption is evil dept.)
|
|
||||||
os.chdir(self.ctx.pkg_work_dir() + "/" + self.spec.source.name + "-" + self.spec.source.version)
|
|
||||||
locals = globals = {}
|
locals = globals = {}
|
||||||
|
|
||||||
try:
|
try:
|
||||||
@@ -65,7 +60,9 @@ class PisiBuild:
|
|||||||
except SyntaxError, e:
|
except SyntaxError, e:
|
||||||
ui.error ("Error : %s\n" % e)
|
ui.error ("Error : %s\n" % e)
|
||||||
return
|
return
|
||||||
|
|
||||||
|
self.goToWorkDir(globals)
|
||||||
|
|
||||||
self.configureSource(locals)
|
self.configureSource(locals)
|
||||||
self.buildSource(locals)
|
self.buildSource(locals)
|
||||||
self.installSource(locals)
|
self.installSource(locals)
|
||||||
@@ -81,6 +78,19 @@ class PisiBuild:
|
|||||||
def applyPatches(self):
|
def applyPatches(self):
|
||||||
pass
|
pass
|
||||||
|
|
||||||
|
def goToWorkDir(self, globals):
|
||||||
|
path = globals['WorkDir']
|
||||||
|
if globals['WorkDir'] is not None:
|
||||||
|
path = self.ctx.pkg_work_dir() + "/" + path
|
||||||
|
else:
|
||||||
|
path = self.ctx.pkg_work_dir() + "/" + self.spec.source.name + "-" + self.spec.source.version
|
||||||
|
|
||||||
|
try:
|
||||||
|
os.chdir(path)
|
||||||
|
except OSError, e:
|
||||||
|
ui.error ("No such file or directory: %s\n" % e)
|
||||||
|
sys.exit()
|
||||||
|
|
||||||
def configureSource(self, locals):
|
def configureSource(self, locals):
|
||||||
func = self.ctx.const.setup_func
|
func = self.ctx.const.setup_func
|
||||||
if func in locals:
|
if func in locals:
|
||||||
|
|||||||
@@ -4,6 +4,8 @@
|
|||||||
from pisi.actionsapi import gnuconfig
|
from pisi.actionsapi import gnuconfig
|
||||||
from pisi.actionsapi import autotools
|
from pisi.actionsapi import autotools
|
||||||
|
|
||||||
|
WorkDir='popt-1.7'
|
||||||
|
|
||||||
def setup():
|
def setup():
|
||||||
gnuconfig.gnuconfig_update()
|
gnuconfig.gnuconfig_update()
|
||||||
# libtoolize.libtoolize()
|
# libtoolize.libtoolize()
|
||||||
|
|||||||
Reference in New Issue
Block a user