[build2] How to append options to dumpmachine ?

Boris Kolpackov boris at codesynthesis.com
Tue Feb 18 09:22:23 UTC 2025


Michael Martin Moro via users <users at build2.org> writes:

> The issue is that when Build2 probes the compiler, it calls:
> 
> /opt/cheerp/bin/clang++ -dumpmachine
> 
> Which returns the default target, cheerp-leaningtech-webbrowser-wasm.
> 
> I want it to return cheerp-leaningtech-webbrowser-genericjs, which would be
> the result of:
> 
> /opt/cheerp/bin/clang++ -dumpmachine -target cheerp-genericjs
> 
> Is there a way to specify the options passed when running -dumpmachine ?

Yes, these types of options should be specified as "compiler mode options":

https://github.com/build2/build2/blob/v0.17.0/NEWS#L1878-L1889

Also see:

https://github.com/build2/build2/blob/v0.17.0/NEWS#L254-L265



More information about the users mailing list