-
-
Notifications
You must be signed in to change notification settings - Fork 781
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Meson build #1033
Meson build #1033
Conversation
Added some fancy user feedback for the build configuration and added target enabling/disbling funtionality, I'm pretty happy with this right now, it still needs porting of the rest of platforms and probes example run with the current configuration, using the default probe and enabling only support for stm:
I used I feature I hadn't before in meson, dictionaries, for the targets in the targets meson file, I think it works pretty well for it, the way it's done now allows us to do some cool stuff like enabling targets that are dependencies of other targets and doing something like target groups, to enable a group of targets with a single keyword on configuration This isn't tested in hardware, so I don't know that this method of disabling targets works, but i believe it should |
988b3a4
to
dfc7479
Compare
all platforms and probes available ported, unknown if they actually work, but they build, might need some tweaking |
642b75b
to
a2d8dcf
Compare
Renamed to avoid plurality and clarity when reading paths
Signed-off-by: Rafael Silva <[email protected]>
Signed-off-by: Rafael Silva <[email protected]>
Signed-off-by: Rafael Silva <[email protected]>
Signed-off-by: Rafael Silva <[email protected]>
Signed-off-by: Rafael Silva <[email protected]>
Signed-off-by: Rafael Silva <[email protected]>
Signed-off-by: Rafael Silva <[email protected]>
Signed-off-by: Rafael Silva <[email protected]>
Signed-off-by: Rafael Silva <[email protected]>
Signed-off-by: Rafael Silva <[email protected]>
Signed-off-by: Rafael Silva <[email protected]>
Signed-off-by: Rafael Silva <[email protected]>
Signed-off-by: Rafael Silva <[email protected]>
Signed-off-by: Rafael Silva <[email protected]>
Signed-off-by: Rafael Silva <[email protected]>
superceeded by #1528 |
Why
This is not a real PR, not for now at least, merely for review and evaluation purposes
I decided to make a quick draft meson build for black magic firmware, to aid in the evaluation of the future buildsystem rework, also because I was bored and enjoy it
I realize all this work may be scrapped, that is fine
What
At the moment only the native probe target and the stm32 platform are implemented, the libopencm3 dependency is not properly handled
How
because libopencm3 is not being handled properly yet, we need to build it manually first
make -C libopencm3 lib/stm32/f1 lib/stm32/f4 lib/lm4f
we create a build directory, where the build configuration and compilation will happen
mkdir build
configuring the build, the default target probe is the
native
we may configure the target probe with-Dprobe=some_probe
in the event that a unsupported probe is configured, a message will be displayed with available probes (although they wont compile right now), the crossfile here tells meson we're cross compiling and selects the toolchainmeson build/ --cross-file crossfile/arm-none-eabi.ini
finally we deply the ninjas (we build)
ninja -C build/
This should generate a valid binary for the native hardware (build/black_magic_firmware.bin), I haven't tested it, fair warning, but the binary looks valid at a glance, I also tried to make the build as similar option for option to the original as i could