diff options
Diffstat (limited to 'abs/core-testing')
-rwxr-xr-x | abs/core-testing/LinHES-config/PKGBUILD | 2 | ||||
-rwxr-xr-x | abs/core-testing/LinHES-config/mv_install.py | 42 |
2 files changed, 43 insertions, 1 deletions
diff --git a/abs/core-testing/LinHES-config/PKGBUILD b/abs/core-testing/LinHES-config/PKGBUILD index 37beb99..56cbd1a 100755 --- a/abs/core-testing/LinHES-config/PKGBUILD +++ b/abs/core-testing/LinHES-config/PKGBUILD @@ -1,6 +1,6 @@ pkgname=LinHES-config pkgver=2.0 -pkgrel=43 +pkgrel=44 conflicts=(MythVantage-config MythVantage-config-dev LinHES-config-dev ) pkgdesc="Install and configure your system" depends=(bc libstatgrab mysql-python expect curl dnsutils parted sg3_utils nmbscan system-templates rsync python-parted ddcxinfo python-pexpect) diff --git a/abs/core-testing/LinHES-config/mv_install.py b/abs/core-testing/LinHES-config/mv_install.py index 9d2e284..efee91e 100755 --- a/abs/core-testing/LinHES-config/mv_install.py +++ b/abs/core-testing/LinHES-config/mv_install.py @@ -770,6 +770,42 @@ def add_to_blacklist(module): f.write(newline) f.close() + +def add_to_modulelist(module): + rcfile = data_config.MOUNTPOINT + "/etc/rc.conf" + logging.debug(" Attempting to add %s to modulelist", module) + newline='' + try: + f = open(rcfile, 'r') + conflines = f.readlines() + f.close() + except: + logging.critical(" *Couldn't open %s for reading",rcfile) + return + + try: + f = open(rcfile, 'w') + except: + logging.critical(" *Couldn't open %s for reading",rcfile) + return + + for line in conflines: + newline = line + if re.match("MODULES=",line): + logging.debug(line) + try: + lastpar = line.rindex(')') + logging.debug(" found ) at %s", lastpar) + newline = line[:lastpar] +" " + module + " " + line[lastpar:] + logging.debug(newline) + except: + logging.debug("Couldn't find ending )") + newline = line + f.write(newline) + f.close() + + + def special_hardware_check(): logging.info("_____Applying special boot parameters_______") try: @@ -789,6 +825,12 @@ def special_hardware_check(): for module in modulelist.split(','): add_to_blacklist(module) + if re.match("modules",item) != None : + logging.debug(" Found modules") + modulelist = item.split("=")[1] + for module in modulelist.split(','): + add_to_modulelist(module) + def swapsearch(): #currently unused! |