From: Giulio Benetti <giulio.benetti@benettiengineering.com>
To: "Yann E. MORIN" <yann.morin.1998@free.fr>,
Thomas Petazzoni <thomas.petazzoni@bootlin.com>
Cc: Angelo Compagnucci <angelo.compagnucci@gmail.com>,
buildroot@buildroot.org
Subject: Re: [Buildroot] [PATCH] package/mono: allow to select which folders to install to target
Date: Tue, 1 Nov 2022 03:27:30 +0100 [thread overview]
Message-ID: <1e71c677-05cf-89b1-419f-df8e0f73ae63@benettiengineering.com> (raw)
In-Reply-To: <20221031125405.GC1058960@scaer>
Hi Yann,
On 31/10/22 13:54, Yann E. MORIN wrote:
> Giulio, Thomas, All,
>
> On 2022-10-31 13:25 +0100, Thomas Petazzoni via buildroot spake thusly:
>> On Wed, 19 Oct 2022 01:46:17 +0200
>> Giulio Benetti <giulio.benetti@benettiengineering.com> wrote:
>>> At the moment all APIs folders are copied to target increasing the size of
>>> rootfs of ~190MB. Allow to select which API folders we want to copy to
>>> target to shrink rootfs down.
>>>
>>> Signed-off-by: Giulio Benetti <giulio.benetti@benettiengineering.com>
>> Practically speaking, could you describe which folders are needed in a
>> typical scenario you've had?
>
> Yes, can you provide a rationale for when only a subset of APIs is
> needed?
I've answered on previous e-mail. I've realized only now that I could
answer to your e-mail for both.
>> Here, I have these ones:
>>
>> drwxr-xr-x 2 thomas thomas 4096 oct. 25 22:58 2.0-api
>> drwxr-xr-x 2 thomas thomas 4096 oct. 25 22:58 3.5-api
>> drwxr-xr-x 2 thomas thomas 4096 oct. 25 22:56 4.0
>> drwxr-xr-x 2 thomas thomas 12288 oct. 25 22:58 4.0-api
>> drwxr-xr-x 4 thomas thomas 16384 oct. 25 22:58 4.5
>> drwxr-xr-x 3 thomas thomas 12288 oct. 25 22:58 4.5.1-api
>> drwxr-xr-x 3 thomas thomas 12288 oct. 25 22:58 4.5.2-api
>> drwxr-xr-x 3 thomas thomas 12288 oct. 25 22:58 4.5-api
>> drwxr-xr-x 3 thomas thomas 12288 oct. 25 22:58 4.6.1-api
>> drwxr-xr-x 3 thomas thomas 12288 oct. 25 22:58 4.6.2-api
>> drwxr-xr-x 3 thomas thomas 12288 oct. 25 22:58 4.6-api
>> drwxr-xr-x 3 thomas thomas 12288 oct. 25 22:58 4.7.1-api
>> drwxr-xr-x 3 thomas thomas 12288 oct. 25 22:58 4.7.2-api
>> drwxr-xr-x 3 thomas thomas 12288 oct. 25 22:58 4.7-api
>> drwxr-xr-x 3 thomas thomas 12288 oct. 25 22:58 4.8-api
>> drwxr-xr-x 145 thomas thomas 12288 oct. 25 22:56 gac
>> drwxr-xr-x 2 thomas thomas 4096 oct. 25 22:56 lldb
>> drwxr-xr-x 3 thomas thomas 4096 oct. 25 22:56 mono-configuration-crypto
>> drwxr-xr-x 2 thomas thomas 4096 oct. 25 22:56 monodoc
>> drwxr-xr-x 3 thomas thomas 4096 oct. 25 22:56 msbuild
>> drwxr-xr-x 6 thomas thomas 4096 oct. 25 22:56 xbuild
>> drwxr-xr-x 4 thomas thomas 4096 oct. 25 22:56 xbuild-frameworks
>
> It looks like we have three sets of directories here;
> - version-based dirs: from 2.0-api up to 4.8-api
> - gac/: big number of subdirs in there...
> - the rest
>
> Your change trat them all on the same level, but are they all really
> superfluous? Is there a set that absolutely needs to be there, or can we
> really do with just one (or even none, see below)?
>
> Note: can we unconditionally get rid of monodoc/? Of msbuild/? Of lldb/?
To tell the truth I'm not expert in this. I know that my customer's
application only needed the files in those folders.
So I can't find at the moment something that clarifies this, that's why
I've given a very open solution. Of course this can give problems in
runtime. But the mono application should fail immediately if someone
skip some folder.
>>> +config BR2_PACKAGE_MONO_SPECIFY_FOLDERS_TO_INSTALL
>>> + bool "Specify folders to install to target"
>>> + help
>>> + Allow to specify which Mono folder to install to target
>>
>> I don't really have a very good suggestion, but I don't like the name
>> of the option. We rarely have option names that are "sentences", i.e
>> "specify folders to install" is a sentence.
>>
>> Should we instead have a single string option
>> BR2_PACKAGE_MONO_INSTALL_LIB_DIRS, which is empty by default. When
>> empty, it means all folders are installed. Otherwise, only the
>> specified folders are installed.
>
> Agreed. I expect that having no API level installed would yield a
> non-working system, so:
>
> config BR2_PACKAGE_MONO_API_VERSIONS
> string "API versions to install"
> help
> Keep empty to install all.
Ok, I go with that then!
>> The other obvious question is whether this shouldn't simply be left as
>> something to do in a post-build script. Even though I admit that
>> reducing 190 MB down to something reasonable can be seen as something
>> that is almost mandatory.
>>
>> Or alternatively, do we have a better way, where we could automate this
>> selection of which folders are needed?
>
> I would prefer we avoid carrying the list of versionned APIs (and the
> rest, see above).
Yes I agree, otherwise the list would be pretty long.
Best regards
--
Giulio Benetti
CEO/CTO@Benetti Engineering sas
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
next prev parent reply other threads:[~2022-11-01 2:27 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-10-18 23:46 [Buildroot] [PATCH] package/mono: allow to select which folders to install to target Giulio Benetti
2022-10-19 16:16 ` Angelo Compagnucci
2022-10-31 12:25 ` Thomas Petazzoni via buildroot
2022-10-31 12:54 ` Yann E. MORIN
2022-11-01 2:27 ` Giulio Benetti [this message]
2022-11-01 8:32 ` Yann E. MORIN
2022-11-01 9:19 ` Angelo Compagnucci
2022-11-01 17:42 ` Yann E. MORIN
2022-11-01 20:30 ` Angelo Compagnucci
2022-11-01 18:17 ` Giulio Benetti
2022-11-01 16:44 ` Giulio Benetti
2022-11-01 2:19 ` Giulio Benetti
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1e71c677-05cf-89b1-419f-df8e0f73ae63@benettiengineering.com \
--to=giulio.benetti@benettiengineering.com \
--cc=angelo.compagnucci@gmail.com \
--cc=buildroot@buildroot.org \
--cc=thomas.petazzoni@bootlin.com \
--cc=yann.morin.1998@free.fr \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox