-
Notifications
You must be signed in to change notification settings - Fork 23
/
Copy pathmkinitrd.py
executable file
·41 lines (33 loc) · 1.05 KB
/
mkinitrd.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
#!/usr/bin/env python3
# Copyright 2012-2015 Jonathan Vasquez <[email protected]>
# Licensed under the Simplified BSD License which can be found in the LICENSE file.
from subprocess import call
import pkg.libs.Variables as var
from pkg.libs.Core import Core
from pkg.libs.Tools import Tools
from pkg.hooks.Addon import Addon
class Main(object):
# Let the games begin ...
@classmethod
def start(cls):
Tools.ProcessArguments(Addon)
call(["clear"])
Tools.PrintHeader()
Core.PrintMenu()
if var.kernel or Addon.GetFiles():
Core.GetDesiredKernel()
Core.VerifySupportedArchitecture()
Tools.Clean()
Core.VerifyPreliminaryBinaries()
Core.CreateBaselayout()
Core.VerifyBinaries()
Core.CopyRequiredFiles()
Core.CopyModules()
Core.CopyFirmware()
Core.CreateLinks()
Core.CopyDependencies()
Core.LastSteps()
Core.CreateInitramfs()
Tools.CleanAndExit(var.initrd)
if __name__ == '__main__':
Main.start()