From mboxrd@z Thu Jan  1 00:00:00 1970
Return-Path: <gentoo-soc+bounces-2486-garchives=archives.gentoo.org@lists.gentoo.org>
Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80])
	(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
	(No client certificate requested)
	by finch.gentoo.org (Postfix) with ESMTPS id 7FF9D1382C5
	for <garchives@archives.gentoo.org>; Tue, 23 Jun 2020 04:45:23 +0000 (UTC)
Received: from pigeon.gentoo.org (localhost [127.0.0.1])
	by pigeon.gentoo.org (Postfix) with SMTP id 47737E0839;
	Tue, 23 Jun 2020 04:45:20 +0000 (UTC)
Received: from mail-pj1-x102c.google.com (mail-pj1-x102c.google.com [IPv6:2607:f8b0:4864:20::102c])
	(using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits))
	(No client certificate requested)
	by pigeon.gentoo.org (Postfix) with ESMTPS id 0BACFE0839
	for <gentoo-soc@lists.gentoo.org>; Tue, 23 Jun 2020 04:45:19 +0000 (UTC)
Received: by mail-pj1-x102c.google.com with SMTP id b7so683081pju.0
        for <gentoo-soc@lists.gentoo.org>; Mon, 22 Jun 2020 21:45:19 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
        d=jsteward.moe; s=google;
        h=from:to:references:in-reply-to:subject:date:message-id:thread-index
         :content-language:mime-version;
        bh=Run7dRHjOxoxO0aB/Ji3vPbDh4v5uxXMk1JEzO1rnJE=;
        b=YBByTdejzvPYGhU1po23fp3yV5dKGVnj6Zg341XkZLD+Il3/P+/e0tXVZmErjL6Ihj
         FxKWTyNs/QwIMiZHYWFEeIjCwsClhOTAUAPsFw0iaoucOuEjob7KC+zSJBiz+4QDrfC+
         SAtn3+SrwH1E/OkzGrHaSxrhsWdkJEpN96fqSQvsuG0ys0E4+0hsnp63B9WWhTjp2z2X
         rOaozi8Fd2jD1utipt13POO74v0ZZXeWHhihWwMew2J+8bqG9eCZDIyb6I0HYePMv8so
         jxi9mWsdbaOaWSXVCUIcpMC9Xzoe4wFlWSZrYZo8Kf0lmVC2a10oGDv7k99PGdCOKM6K
         BQeA==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
        d=1e100.net; s=20161025;
        h=x-gm-message-state:from:to:references:in-reply-to:subject:date
         :message-id:thread-index:content-language:mime-version;
        bh=Run7dRHjOxoxO0aB/Ji3vPbDh4v5uxXMk1JEzO1rnJE=;
        b=PJHy0Iq94WnFuSI6dcaQBxMc6mH2JxAlF5+6J3bucLPs7pX2xSxmac/D3Y023Kt3FS
         q/Quu28vaZsZIGM1repeKd8hrVoL7c7B6JAiuf7rA8AKfUCQ91rf3azi5plOAbYCUJjD
         1C/Jg103/VBm3UfL7CnTuaw7N2YooUZq8O9TnLOjdhrmckGWTJRdxVWhA/yuHXeJ145a
         0VLX52AC1GjRCDlEUw4xS/b5O7mQdnOQ4o5Tz2ZJoZisrWgEPBTFLKSQXt3uuS+TICTa
         JVHX85Zf3qeWl3IoYTnBHDnVBJ2KCx7zL118OOXUmQ5Kg0rHXTidSeF7jAZK0crMYvu+
         DxfA==
X-Gm-Message-State: AOAM530u1K8cBBfa329BIJTJ5GsqXGUAOl2r9URHNoaRZ3PuyF2mfrBt
	pJ3nZTWmZLf+ePlznG6f43hyDRaL92puZQ7u
X-Google-Smtp-Source: ABdhPJw+WCJ0n0eHhZ2tkOae/I7grjrFWbDgtkg1MBuJg0dCKwsw4JoPLOgWRNzUeOifCby6U4+jXQ==
X-Received: by 2002:a17:90a:1b69:: with SMTP id q96mr647502pjq.198.1592887518350;
        Mon, 22 Jun 2020 21:45:18 -0700 (PDT)
Received: from KAGE ([2400:8901:e001:ab:4c2a:f0f0:0:4])
        by smtp.gmail.com with ESMTPSA id l195sm15981695pfd.18.2020.06.22.21.45.14
        for <gentoo-soc@lists.gentoo.org>
        (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128);
        Mon, 22 Jun 2020 21:45:17 -0700 (PDT)
From: "Pengcheng Xu" <i@jsteward.moe>
To: <gentoo-soc@lists.gentoo.org>
References: <20200622191553.2rodmf6heg6my25d@tardis.localdomain>
In-Reply-To: <20200622191553.2rodmf6heg6my25d@tardis.localdomain>
Subject: RE: [gentoo-soc] Weekly Report: Portage Powered Android
Date: Tue, 23 Jun 2020 12:45:12 +0800
Message-ID: <01b501d64919$16a1f090$43e5d1b0$@jsteward.moe>
X-Mailer: Microsoft Outlook 16.0
Thread-Index: AQJPHbP6kal+h6Uwtw+/cujDhB18Qqfz9DCw
Content-Language: ja
Precedence: bulk
List-Post: <mailto:gentoo-soc@lists.gentoo.org>
List-Help: <mailto:gentoo-soc+help@lists.gentoo.org>
List-Unsubscribe: <mailto:gentoo-soc+unsubscribe@lists.gentoo.org>
List-Subscribe: <mailto:gentoo-soc+subscribe@lists.gentoo.org>
List-Id: Gentoo Linux mail <gentoo-soc.gentoo.org>
X-BeenThere: gentoo-soc@lists.gentoo.org
Reply-to: gentoo-soc@lists.gentoo.org
X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply
MIME-Version: 1.0
Content-Type: multipart/signed;
	boundary="=-=dzUyE779hrdG9x=-=";
	protocol="application/pgp-signature";
	micalg=pgp-sha256
X-Archives-Salt: 28055ab7-a869-4d90-9d1e-de0dfad4338b
X-Archives-Hash: a23ec8b05548c311665818d568fc0ae0

This is a multipart message in MIME format.

--=-=dzUyE779hrdG9x=-=
Content-Type: text/plain;
	charset="utf-8"
Content-Transfer-Encoding: quoted-printable

Sorry for not getting back for some time; I had some other affairs that kep=
t my hands busy.  I have some comments for this week's report.

> -----Original Message-----
> From: Gunwant Jain <therealgunwant@gmail.com>
> Sent: Tuesday, June 23, 2020 3:16 AM
> To: gentoo-soc@lists.gentoo.org
> Cc: heroxbd@gentoo.org
> Subject: [gentoo-soc] Weekly Report: Portage Powered Android
>=20
> Hello Everyone,
>=20
> I was supposed to integrate `bootstrap-init` and `sar-preinit` into Shark=
Bait
> this week. I couldn't quite do that.
> `bootstrap-init` was initially cross-compiled for aarch64 using NDK. So t=
he
> first job was to get rid of NDK and use a different "build-system".
> I opted for CMake and ported the project to use it [1]. But the binary co=
mpiled
> by CMake on my phone (arm64 Gentoo), would not boot Android.
> The build rules can be inspected on [1].

Have you figured out _why_ Android is not booting?  I can think of a bunch =
of reasons, such as missing dependencies for a dynamically-linked executabl=
e, crashing on execution, etc.  Simply saying "would not boot Android" does=
 not convey any information.

Besides, I don't think you need NDK for something as low-level as an init; =
you shouldn=E2=80=99t need one as long as the code does not use Android-spe=
cific functions or call into Android service (e.g. vold).  You should be ab=
le to get away with something standard, i.e. newlib/musl/glibc.  I haven't =
read the source code though, and I might be wrong here; do your survey.

>=20
> I believe this is because of the fact that I am not using a Bionic based =
toolchain.
> So, I started working on building such a toolchain mid-week.
> And this is where my current task starts coinciding with my next schedule=
d task
> of providing a aarch64-linux-android toolchain where we build Bionic as w=
ell.
> The crux of this task was already performed by KireinaHoro in his GSoC [2=
].
> Since my next scheduled task is required to be finished for my current ta=
sk,
> I propose to merge `bootstrap-init` along with `sar-preinit` together lat=
er
> in the SharkBait workflow.

You may try with bionic toolchain, but just as I said, so long as no Androi=
d-specific APIs are involved, libc should not be the problem.

>=20
> And to cover the installing process for users right now, I will write a b=
log
> and post it on [3] within 24 hours of writing this mail. The blog will pr=
ovide
> a guide on assembling the components required for System-As-Root based An=
droid
> devices and installing SharkBaitOS. Keep in mind that this process will i=
ndeed
> be simplified for the user later.
> And I propose to edit SharkBait's official wiki later in my GSoC tenure e=
xplaining
> the simplified procedure to end-users and porters.
>=20
> Thanks,
> Gunwant
>=20
> [1] https://gitlab.com/WantGuns/bootstrap-init/-/tree/cmake
> [2]
> https://wiki.gentoo.org/wiki/Android/SharkBait/Building_a_toolchain_for_aa
> rch64-linux-android
> [3] https://wantguns.gitlab.io/

Regards,
--=20
Pengcheng Xu
https://jsteward.moe

--=-=dzUyE779hrdG9x=-=
Content-Type: application/pgp-signature;
	name="openpgp-digital-signature.asc"
Content-Transfer-Encoding: 7bit

-----BEGIN PGP SIGNATURE-----

iQIzBAEBCAAdFiEEDwqrvuDZbn+NMYrRObYNsFSJJP8FAl7xiNIACgkQObYNsFSJ
JP8Bbg/+LPX0XTCxM7D5BODuzG2PySW7UJDm7HN4q6LnpAN9L3gTY7BN7i8041nt
i0XCwdPbshAfZVDg5lGAQLcPNChtqO9xzFlbe0dybc0mTqL57od8qlLNx2XGxJRd
Hc+3tTe7qdWXgAMua+jPbddNeWdVGgWq+O5xDD57kcicnZXS7hurGL7ftBNY8uSu
s/4b47r5nb/1KZdPlQL9tpdRfcSiM7plBiAcr6I6ZmX8VIUKpQIdb1AYXgK5/siw
VhgmBSyZ5xz57MRnaUHbnNtV9PWHb2hovh2JUI/F9rM5nCWvCIt1czHU+x3RQIBz
xBnjBlwbaeIaftwRaRTP9mqRQ97WoFOgSJ+RjgkQVq68S4hwKJmMWPWgCkHjpQX7
Msq+ZFNHwKrY4+R9yPAv8YkWy5/SPDbiFsjT3JQPi3qSbN0UUsdqq1L68Dom8AF1
Y54huCcpKE12MYkjW4KOkVtVipyPuwrvpw8NKk6RgNvyR+BJesTmRvVwBJN8N4Hp
sHEpSiOMuDeU7rBnHOGNIMx+49Pgjx7kvmiB2DNKTudjpUy9MRjcJA2Siwh3q5Mm
/5JB07e5h2H7xRsWWtD6QZJ6QArBrVssN/qdnKHfaQsdzYl0CXJYy4f7aQjxO332
tzxBdk7dcCCgZb4HOaGaevjnqGfJcFzgNBysBO7Qr9kiBneTBbo=
=B1lx
-----END PGP SIGNATURE-----


--=-=dzUyE779hrdG9x=-=--