TriForceX / MiyooCFW

Custom firmware source code and resources for BittBoy, PocketGo, PowKiddy V90-Q90-Q20 and third party handheld consoles
GNU General Public License v2.0
1.11k stars 112 forks source link

[Question] Building from source #523

Closed EchedelleLR closed 1 month ago

EchedelleLR commented 1 year ago

I have been reading the build guide you host at https://github.com/TriForceX/MiyooCFW/wiki/Build-Source but there are several faulty things:

  1. buildroot seems to include now the toolchain, does this affect to the guide described here or the building process?
  2. The uboot section seems faulty to where to flash it. If a person wants to use it in the sdcard, to which partition should they flash it or is indeed saved at MBR or similar?
  3. The building kernel section, what is the difference between hardware revisions to know which to choose? or I must choose both? (I guess is only one given the next steps) Does it depend on the console?, the microSD?
  4. Is firmware (real one, not this OS) and/or drivers built/added with this process or I must gather it from somewhere? I don't know the difference between the releases for each console.
szymor commented 1 year ago

Ad 1. You use buildroot to build the toolchain. The toolchain is not a part of buildroot. Ad 2. There is no mistake - you do not flash U-Boot to a partition but to a specific SD card sector/range of sectors. Ad 3. Hardware revision is specified by the console you own. Different revisions have slight differences in PCB layout and components. Ad 4. This is real firmware. It includes u-boot, kernel, drivers and some user apps.

EchedelleLR commented 1 year ago

I don't understand the first reply, but I do with the rest.

Where is the toolchain hosted, build then? The link referenced references to the old repo which is now deprecated in favor of buildroot and it affirms that the code is there now or so.

Apaczer commented 1 year ago

Our WIKI refers to the build process of the NxHope (first custom firmware for Miyoo) written by @steward-fu. The method to make MiyooCFW from scratch has changed since that time, which derived from former - sorry but we didn't update it since then much.

What you really need TBH is only the buildroot (see README there). If you want to make modifications to different packages just add *.patch in correspoding package/<package_name/ directory. You can also run make <package_name>-extract to fetch extracted tarbal src, which you will find then in output/build/<package_name>-<version> dir to apply changes directly to source. More info in buildroot's manual.

EchedelleLR commented 1 year ago

I guess I will wait for the process to be documented. The buildroot manual is too big and includes information that does not seem to be needed for the current use case and are more general and modular like if I wanted to tweak.

My current objective is getting a reproducible build of the firmware as far as you released it or you would release it so I can automate some parts and then use it in my console.

Apaczer commented 1 month ago

building CFW img and other important parts have been documented via https://github.com/TriForceX/MiyooCFW/wiki and https://github.com/MiyooCFW/docs