It's almost complete.
This commit is contained in:
@@ -45,6 +45,8 @@ def __getSuffix():
|
|||||||
if __getFlavour():
|
if __getFlavour():
|
||||||
suffix += "-%s" % __getFlavour()
|
suffix += "-%s" % __getFlavour()
|
||||||
|
|
||||||
|
return suffix
|
||||||
|
|
||||||
def __getExtraVersion():
|
def __getExtraVersion():
|
||||||
extraversion = ""
|
extraversion = ""
|
||||||
try:
|
try:
|
||||||
@@ -64,9 +66,6 @@ def __getExtraVersion():
|
|||||||
|
|
||||||
return extraversion
|
return extraversion
|
||||||
|
|
||||||
def __getHeadersDirectoryName():
|
|
||||||
return "usr/src/linux-headers-%s" % __getSuffix()
|
|
||||||
|
|
||||||
|
|
||||||
# Public callables
|
# Public callables
|
||||||
|
|
||||||
@@ -74,8 +73,6 @@ def configure():
|
|||||||
# Set EXTRAVERSION
|
# Set EXTRAVERSION
|
||||||
extraversion = __getExtraVersion()
|
extraversion = __getExtraVersion()
|
||||||
|
|
||||||
print "******* EV: ", extraversion
|
|
||||||
|
|
||||||
# I don't know what for but let's clean *.orig files
|
# I don't know what for but let's clean *.orig files
|
||||||
shelltools.system("find . -name \"*.orig\" | xargs rm -f")
|
shelltools.system("find . -name \"*.orig\" | xargs rm -f")
|
||||||
|
|
||||||
@@ -85,7 +82,7 @@ def configure():
|
|||||||
if os.getenv("MENUCONFIG"):
|
if os.getenv("MENUCONFIG"):
|
||||||
autotools.make("menuconfig")
|
autotools.make("menuconfig")
|
||||||
else:
|
else:
|
||||||
autotools.make("oldconfig")
|
autotools.make("silentoldconfig")
|
||||||
|
|
||||||
def build():
|
def build():
|
||||||
autotools.make()
|
autotools.make()
|
||||||
@@ -125,8 +122,11 @@ def installHeaders(extra=[]):
|
|||||||
pruned = ["include", "scripts"]
|
pruned = ["include", "scripts"]
|
||||||
wanted = ["Makefile*", "Kconfig*", "Kbuild*", "*.sh", "*.pl", "*.lds"]
|
wanted = ["Makefile*", "Kconfig*", "Kbuild*", "*.sh", "*.pl", "*.lds"]
|
||||||
|
|
||||||
|
suffix = __getSuffix()
|
||||||
|
headersDirectoryName = "usr/src/linux-headers-%s" % suffix
|
||||||
|
|
||||||
# Get the destination directory for header installation
|
# Get the destination directory for header installation
|
||||||
destination = os.path.join(get.installDIR(), __getHeadersDirectoryName())
|
destination = os.path.join(get.installDIR(), headersDirectoryName)
|
||||||
shelltools.makedirs(destination)
|
shelltools.makedirs(destination)
|
||||||
|
|
||||||
# First create the skel
|
# First create the skel
|
||||||
@@ -151,20 +151,19 @@ def installHeaders(extra=[]):
|
|||||||
cpio -pd --preserve-modification-time %s" % destination)
|
cpio -pd --preserve-modification-time %s" % destination)
|
||||||
|
|
||||||
# Settle the correct build symlink to this headers
|
# Settle the correct build symlink to this headers
|
||||||
pisitools.dosym("/%s" % __getHeadersDirectoryName(),
|
pisitools.dosym("/%s" % headersDirectoryName, "/lib/modules/%s/build" % suffix)
|
||||||
"/lib/modules/%s/build" % suffix)
|
|
||||||
|
|
||||||
def installSource():
|
def installSource():
|
||||||
destination = "usr/src/linux-source-%s" % __getSuffix()
|
destination = "usr/src/linux-source-%s" % __getSuffix()
|
||||||
|
|
||||||
pisitools.dodir("/usr/src")
|
pisitools.dodir("/usr/src")
|
||||||
shelltools.copytree("../%s/" % WorkDir, os.path.join(get.installDIR(), destination))
|
shelltools.copytree("../%s/" % os.path.basename(get.curDIR()), os.path.join(get.installDIR(), destination))
|
||||||
|
|
||||||
# Cleanup the installed source
|
# Cleanup the installed source
|
||||||
shelltools.cd(os.path.join(get.installDIR(), destination))
|
shelltools.cd(os.path.join(get.installDIR(), destination))
|
||||||
autotools.make("clean")
|
autotools.make("clean")
|
||||||
autotools.make("modules_prepare")
|
autotools.make("modules_prepare")
|
||||||
|
|
||||||
|
def mkinitramfs():
|
||||||
def installDocumentation():
|
""" Create and install the initramfs image into the package. This will hopefully be done on user's system. """
|
||||||
pass
|
shelltools.system("/sbin/mkinitramfs kernel=%s --full --root-dir=%s --output=/%s/boot" % (__getSuffix(), get.installDIR(), get.installDIR()))
|
||||||
|
|||||||
Reference in New Issue
Block a user