|
|
|
@ -31,8 +31,8 @@ class Cache():
|
|
|
|
|
reMerge = re.compile(b"(merge|mergepkg)\(([-\w/]*)(?:\[[^\]]\])?\)[-!=<>]")
|
|
|
|
|
rePatch = re.compile(b"^#\s*Calculate.*ac_install_patch==on")
|
|
|
|
|
|
|
|
|
|
PATCH_TYPE = "patch"
|
|
|
|
|
MERGE_TYPE = "merge"
|
|
|
|
|
PATCH_TYPE = b"patch"
|
|
|
|
|
MERGE_TYPE = b"merge"
|
|
|
|
|
DIRECTORY_TEMPLATE = ".calculate_directory"
|
|
|
|
|
CLT_SUFFIX = ".clt"
|
|
|
|
|
|
|
|
|
@ -109,10 +109,10 @@ class Cache():
|
|
|
|
|
for _type, pkgs in groupby(sorted(all_packages), lambda x: x[0]):
|
|
|
|
|
list_packages = sorted(set(y for x, y in pkgs))
|
|
|
|
|
if _type == self.MERGE_TYPE:
|
|
|
|
|
with writeFile(self.fn_setup) as f:
|
|
|
|
|
f.write("\n".join(list_packages))
|
|
|
|
|
with writeFile(self.fn_setup, binary=True) as f:
|
|
|
|
|
f.write(b"\n".join(list_packages))
|
|
|
|
|
if _type == self.PATCH_TYPE:
|
|
|
|
|
with writeFile(self.fn_patch) as f:
|
|
|
|
|
f.write("\n".join(list_packages))
|
|
|
|
|
with writeFile(self.fn_mtime) as f:
|
|
|
|
|
f.write(str(time.time()))
|
|
|
|
|
with writeFile(self.fn_patch, binary=True) as f:
|
|
|
|
|
f.write(b"\n".join(list_packages))
|
|
|
|
|
with writeFile(self.fn_mtime, binary=True) as f:
|
|
|
|
|
f.write(bytes(time.time()))
|
|
|
|
|