YosysHQ / oss-cad-suite-build

Multi-platform nightly builds of open source digital design and verification tools
ISC License
742 stars 67 forks source link

Added nextpnr-himbaechel #109

Closed lushaylabs closed 1 month ago

lushaylabs commented 3 months ago

Added nextpnr himbaechel for Gowin chips

lushaylabs commented 3 months ago

There is an issue on windows where nextpnr-himbaechel is by default searching for the chibdb under:

/../share/himbaechel/gowin/chipdb-GW1N-1.bin instead of /share/nextpnr/himbaechel/gowin/chipdb-GW1N-1.bin (with the added nextpnr directory) on MacOs this works fine still debugging this as a workaround the path can be manually set using --chipdb
lushaylabs commented 2 months ago

The issue ended up being in nextpnr so I opened a PR there https://github.com/YosysHQ/nextpnr/pull/1314

So this PR is good to go from my side

lushaylabs commented 1 month ago

hi @mmicko this is my first time contributing to this repo, is there anything I should do for this pr? like add a reviewer or something like that

mmicko commented 1 month ago

Sorry @lushaylabs just was too busy. Will take care of this PR.

lushaylabs commented 1 month ago

no worries, and thank you, just wanted to check to make sure I wasn't missing something from my end

mmicko commented 1 month ago

@lushaylabs Sorry was bit busy today, but there are couple of things wrong. You create chipdb files using pip installed apycula and not one from build (that can potentially be different), also you depend on apicula-bba which is not used at all. Himbaechel build should be just binary, and independent of architecture, only chip databases should be built as separate packages as native (so once built since that is just data no code). If you do not mind I would take care of these changes. Idea is to be easy later to add new architecture.

mmicko commented 1 month ago

I guess I should force flat install since apycula does not work when in egg

lushaylabs commented 1 month ago

I used the pip version of apycula, the previous version (nextpnr-gowin) had an option to accept a precalculated bba file so this wasn't needed. It would pull the bba export and build nextpnr. nextpnr-himbaechel doesn't have this option so I had to add the 'python3-native' dependency and install the pip version as a pre-step scripts/nextpnr-himbaechel.sh

mmicko commented 1 month ago

A have merged your changes and added changes I mentioned above. Please do try it in your setup and ping me with results. Sorry I did not took a look at this one before.