summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBenda Xu <heroxbd@gentoo.org>2018-08-09 13:16:50 +0900
committerBenda Xu <heroxbd@gentoo.org>2018-08-09 13:16:50 +0900
commit54da45a46cc33c2c37a5a7943a66b9287605b83b (patch)
tree12ccfe8b41efd389596d1788322dbacea92bf12d
parentsys-apps/sharkbait-setup: bump to 0.5 (diff)
downloadandroid-54da45a46cc33c2c37a5a7943a66b9287605b83b.tar.gz
android-54da45a46cc33c2c37a5a7943a66b9287605b83b.tar.bz2
android-54da45a46cc33c2c37a5a7943a66b9287605b83b.zip
Add soong, the android build system.
-rw-r--r--dev-util/soong/Manifest4
-rw-r--r--dev-util/soong/metadata.xml8
-rw-r--r--dev-util/soong/soong-8.1.0_p41.ebuild54
3 files changed, 66 insertions, 0 deletions
diff --git a/dev-util/soong/Manifest b/dev-util/soong/Manifest
new file mode 100644
index 0000000..13b5d25
--- /dev/null
+++ b/dev-util/soong/Manifest
@@ -0,0 +1,4 @@
+DIST blueprint-8.1.0_p41.tar.gz 114223 BLAKE2B c2e0c450fc6bd6b92dfcdeb5f80462e0edb65a2c052beb29d0a8d6b5dbaa92e54f2c402b964acffe733d58926abe4d2ad3c5891ad751f7eab0c8e5ee8ba4d9b8 SHA512 4799d4e6edcb9a5088a427fad39b0641455806e808457d33b2f78d2c22b14004804b4f62a35a75087be799b05e69f8aa171747a90e53eb894f36937acd32343c
+DIST soong-8.1.0_p41.tar.gz 355567 BLAKE2B aeafa2f29e270bde985ff52a2c3c12507f6c2aba37013c14139cc5c8336ac15305f6aa8182799dea0e744355efdf83a331ce4db10e8551a5b2e5efb140c2a592 SHA512 90675ad4623bba3d3fd20620d3a5a42b63c67bc48ade17da5e661ad8cedab31e2cc41a46bac181ebd49a24f0bfb9cfc07857e312a3f7d80458e361311a354245
+EBUILD soong-8.1.0_p41.ebuild 1379 BLAKE2B 0e890c7433c4f1947545f30991cab1906cc1e44cc2bc024c57f122e9e46a509313bb973ef22809984376b71eb630f20661366660b5cd2ffb0396d32527ff1d22 SHA512 4dffe8c8bdc706867616e79b89de5f5b5017658984a9119a7fdd150257e554bc69b5162c03ee998b805b44317c87d98536d59366bd70f21fecd728d481125086
+MISC metadata.xml 242 BLAKE2B 08b4880748ab6d685ce28f65a9f6cc5ad62deff8f85d4e0a55a3dc12aa8bd63cf1de56b28ff89929e054a6831e223d6ef0207e8b19c6887f09ee22621bd76928 SHA512 ae57aaeecc094cffa640d88329a0baa6c2b0703330d84f6406f3f68d8bb9b724d2e19a8478be8708de284db9ac452f95f225a9f79cd1c5d0236aa2f9935b9b21
diff --git a/dev-util/soong/metadata.xml b/dev-util/soong/metadata.xml
new file mode 100644
index 0000000..c080f1d
--- /dev/null
+++ b/dev-util/soong/metadata.xml
@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer type="person">
+ <email>heroxbd@gentoo.org</email>
+ <name>Benda Xu</name>
+ </maintainer>
+</pkgmetadata>
diff --git a/dev-util/soong/soong-8.1.0_p41.ebuild b/dev-util/soong/soong-8.1.0_p41.ebuild
new file mode 100644
index 0000000..c2a4f9e
--- /dev/null
+++ b/dev-util/soong/soong-8.1.0_p41.ebuild
@@ -0,0 +1,54 @@
+# Copyright 1999-2018 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+
+inherit ninja-utils
+
+A_URI=https://android.googlesource.com/platform/build
+
+# blueprint is a source level dependency of soong.
+SRC_URI="${A_URI}/${PN}/+archive/3d83ebe1768d676c90e8fa3d508157f4654821e5.tar.gz -> ${P}.tar.gz
+ ${A_URI}/blueprint/+archive/a011038d864e3faa528ec1037a568e5824955a0f.tar.gz -> blueprint-${PV}.tar.gz"
+DESCRIPTION="JSON-like build system for Android."
+HOMEPAGE="${A_URI}/${PN}"
+LICENSE="Apache-2.0"
+KEYWORDS="~amd64"
+SLOT=0
+
+DEPEND="dev-lang/go
+ dev-util/ninja"
+RDEPEND="dev-lang/go"
+
+src_unpack() {
+ mkdir -p "${WORKDIR}"/${P}/build || die
+ cd "${WORKDIR}"/${P}/build || die
+
+ for a in ${A}; do
+ mkdir ${a/-*//} || die
+ pushd ${a/-*//} > /dev/null || die
+ unpack ${a}
+ popd > /dev/null || die
+ done
+}
+
+src_prepare() {
+ default
+ ln -s build/soong/root.bp Android.bp || die
+ ln -s build/soong/bootstrap.bash
+}
+
+src_compile() {
+ BUILDDIR="${S}"/out bash -xv build/soong/bootstrap.bash || die
+ eninja -v -f out/.minibootstrap/build.ninja
+ eninja -v -f out/.bootstrap/build.ninja
+
+ # go run cmd/microfactory/microfactory.go -s cmd/microfactory \
+ # -pkg-path android/soong=. -o out/soong_ui android/soong/cmd/soong_ui
+ # eninja -v -f .bootstrap/build.ninja
+}
+
+src_install() {
+ dobin out/.bootstrap/bin/*
+ dodoc out/.bootstrap/docs/*
+}