Browse Source

添加 'libreelec 编译'

coolsoul 10 months ago
parent
commit
c731915c07
1 changed files with 40 additions and 0 deletions
  1. 40 0
      libreelec 编译

+ 40 - 0
libreelec 编译

@@ -0,0 +1,40 @@
+scripts/image line 138
+MTADDONBUILD=no start_multithread_build image || die ......
+
+config/multithread line 51
+  ${SCRIPTS}/pkgjson | ${SCRIPTS}/genbuildplan.py --show-wants --with-json "${THREAD_CONTROL}"/plan.json \
+      --build ${@} > "${THREAD_CONTROL}"/plan || result=1
+
+scripts/pkgjson line 29
+cat <<EOF
+  {
+    "name": "${PKG_NAME}",
+    "hierarchy": "${hierarchy}",
+    "section": "${PKG_SECTION}",
+    "bootstrap": "${PKG_DEPENDS_BOOTSTRAP}",
+    "init": "${PKG_DEPENDS_INIT}",
+    "host": "${PKG_DEPENDS_HOST}",
+    "target": "${PKG_DEPENDS_TARGET}",
+    "unpack": "${PKG_DEPENDS_UNPACK}"
+  },
+EOF
+
+scripts/genbuildplan.py line 124
+def loadPackages():
+    jdata = json.loads(f"[{sys.stdin.read().replace(chr(10),'')[:-1]}]")
+
+    map = {}
+
+    # Load "global" packages first
+    for pkg in jdata:
+        if pkg["hierarchy"] == "global":
+            map[pkg["name"]] = initPackage(pkg)
+
+    # Then the "local" packages, as these will replace any matching "global" packages
+    for pkg in jdata:
+        if pkg["hierarchy"] == "local":
+            map[pkg["name"]] = initPackage(pkg)
+
+    return map
+
+