[flashrom] One Build System Working Group Meeting

2022-10-01 Thread Thomas Heijligen
Hi flashrom community,

In the last weeks we got some big improvements merged to build flashrom with 
meson. The programmer selection got an complete overhaul and now it's also 
possible to use meson on non linux systems.

To plan the next step under this Topic we will meet us again on Friday October 
14th, at 5:00 utc (7:00 Berlin) on https://meet.google.com/cnw-cegw-rad

Everyone is welcome to join!

The working document can be found on 
https://docs.google.com/document/d/1TVso_VbrLEbGc7BNrYxqlrP8jMxB23TuMqEI3PnCzGU

-- Thomas___
flashrom mailing list -- flashrom@flashrom.org
To unsubscribe send an email to flashrom-le...@flashrom.org


[flashrom] One Build System Working Group

2022-05-18 Thread Thomas Heijligen
Hi folks,

we want to meet again to discuss the progress and problems under the
One Build Sytem Topic. If you are interested, please participate on the
poll [0] to find a suitable date.

On Gerrit, relevant patches can be found under the `one_build_system`
topic. [1]
The working document can be found on Google Docs [3] and gets also
posted in plain text to the mailing list after the meeting.

-- Thomas

[0] https://terminplaner4.dfn.de/Eha1mJJ8jS2z2dkw
[1]
https://review.coreboot.org/q/project:flashrom+topic:one_build_system
[3]
https://docs.google.com/document/d/1TVso_VbrLEbGc7BNrYxqlrP8jMxB23TuMqEI3PnCzGU/edit#heading=h.s4e4f1wg7ujz
___
flashrom mailing list -- flashrom@flashrom.org
To unsubscribe send an email to flashrom-le...@flashrom.org


[flashrom] One Build System Working Group

2022-04-06 Thread Thomas Heijligen
Hi,

Here an overview about the One Build System Project for flashrom. I'm
sorry for the extreme late anouncement of the passed meeting. We had
some diffent ideas about it. The next one will be anounced in a prper
advanced and with a survay to choose a time.

Please feel free to contribute, take over a task, start a discousion,
comment in the document or reply to this mail.


https://docs.google.com/document/d/1TVso_VbrLEbGc7BNrYxqlrP8jMxB23TuMqEI3PnCzGU/edit?usp=sharing
---
# Flashrom One Build System Working Group [Draft]

## Goal
  Make meson the only build system for flashrom. Support all currently
supported platforms.

## Abstract
  Modify, extend, rewrite the meson based build system to accommodate
all requirements from flashrom. Rearrange the code for a best fit with
the meson build system. Adapt the Makefile to these changes to have it
working until its end.

## Notify me
  Add me to all to all build system related patches. (Or only to Make /
Meson related one.)
  * Thomas Heijligen 

## Platforms to support
  * Systems
* Linux (Distros / ChromeOS)
* BSD (Free, Net, Open, Dragonfly)
* MacOS
* Android?
* SunOS / Solaris / the current version of it
* Debian kFreeBSD
* GNU / HURD 
* Windows (mingw cross / cygwin)
* DOS (djgpp cross from Linux)
* libpayload (cross from Linux)
  * Architectures
* X86
* ARM
* MIPS
* POWER
x86 supports port I/O (mostly relevant to PCI), others may through
MMIO emulation

## Tasks
  * Update the meson programmer selection to a positive list (see meson
snippets)
  * Clean up the meson file and use best practices for meson
  * PoC: crosscompile “Hello World” for dos / djgpp with meson (with
pci support)
  * PoC: crosscompile “Hello World” for libpayload with meson (with pci
support)
  * Identify the active programmer in the man page
* Add a note for each programmer that is not active in the build
  * Integrate getopt for dos based builds
  * Write documentation
* Build instructions for all platforms
* Design of meson.build 
  * Reason for minimal meson version
* How to add programmer
  * Sync compile options (WIP
https://review.coreboot.org/c/flashrom/+/58561)
  * Create directories for platform abstraction, programmer, include
files (https://review.coreboot.org/c/flashrom/+/62899)

## Open questions
  * System requirements
* How long should we support systems / libraries?
  * As long as they have vendor support
* What should be the minimum required version of meson?
  * The version of the oldest supported system.
  * MacOS and DirectHW
* What is the current status?
* What is useful to support?
* Can we integrate it into flashrom?
* How to test it?
  * Internal programmer
* Should a programmer call / access another programmer?
* Can we split the internal programmer into smaller units
(x86_bios, mips_longson, xyz_superio, linux_mtd) and use internal as a
keyword to select one of those?
* Would that make it easier to build and modify?
  * Build dependencies
* Can we fetch dependencies like cmocka? This makes building for
some systems easier
  * Unit tests
* Can we build the cmoka test on top of libflashrom.a?
* Can this replace self tests?
  * Meson feature options
* Build the shared library as feature
* Build the classic_cli as feature
  * Can be easily deselectet if not needed of not supported
(libpayload)
* Build the tests as feature
* Build man-pages as feature
* Build ich_descriptor_tool as feature
  * Shared libflashrom
* How to handle versioning?

## Sequence for switching the primary build system
  * Meson is feature equivalente with the Makefile
  * Switch to meson as default build system, update the documentation
  * Make a release with meson as the primary build system, keep the
Makefile for legacy compatible.
  * Drop the Makefile
  * Drop dead code from Makefile only based option

## meson snippets - Ideas
  | option('programmer', type : 'array', choices : ['auto' 'all' 
'group_pci' 'group_usb' 'ch341a_spi' ‘drkaiser’])
  * auto selects all programmer available on the platform if the
dependencies are found
  * all selects all programmer available on the platform, failing id a
dependency is not found
  * group_* selects all programmer in this group, fails if the system
does not support the group or a dependency is not found
  *  selects this programmer, fails if not available
on system or missing dependency

  | libusb1 = dependency(...)
  | libusb1_systems = [ ‘linux’ ‘freebsd’ ‘windows’ ‘mac’ … ]
  | libpci = dependency(...)
  | libpci_systems = [...] # systems where libpci is available
  | port_io = declare_dependency(...) # files needed for port I/O
support
  | programmer = {
  |   'ch341a_spi' {
  | 'system' = libusb1_systems,
  | 'srcs' = [ 'ch341a_spi.c' 'usbdev.c' ],
  | 'flags' = [ 'CONFIG_CH341A_SPI=1

[flashrom] One Build System Working Group

2022-04-06 Thread Thomas Heijligen
Hi,

As discoursed last dev meeting, we are going to start a working group
to adopt meson as single, all cases covering, build system for
flashrom.

The first step will be to write down all requirements that we need to
meet. Therefor, we'll meet today at 8:30 UTC at
https://meet.google.com/sag-dyik-bbr and posting the working draft
afterwards on the mailing list. The google doc can be visited at any
time.
https://docs.google.com/document/d/1TVso_VbrLEbGc7BNrYxqlrP8jMxB23TuMqEI3PnCzGU/edit?usp=sharing

Please feel free to join the meetings, the next ones will be announced
much earlier, add comments to the document or reply to this mail with
and question or suggestion.

-- Thomas
___
flashrom mailing list -- flashrom@flashrom.org
To unsubscribe send an email to flashrom-le...@flashrom.org