Pmbootstrap: Aportgen gcc-* requires manual updating of the git checkout of upstream aports

Created on 27 Feb 2018  路  5Comments  路  Source: postmarketOS/pmbootstrap

I'm trying to do the aportgen process from the wiki since it seems like the upstream has updated. I can't do the last step with building GCC since it can't install because unsatisfiable constraints

ERROR: unsatisfiable constraints:
  libstdc++-6.4.0-r7:
    breaks: g++-aarch64-6.4.0-r6[libstdc++=6.4.0-r6]
    satisfies: gcc-6.4.0-r7[so:libstdc++.so.6]
  gcc-6.4.0-r7:
    breaks: g++-aarch64-6.4.0-r6[gcc=6.4.0-r6]
  .pmbootstrap-0:
    masked in: cache
    satisfies: world[.pmbootstrap]

This is after aportgen and after zapping the chroots.

(My current checkout is in https://github.com/postmarketOS/pmbootstrap/tree/fix/compiler-update)

bug pmbootstrap

All 5 comments

Thanks for reporting! I'm looking into this now.

Okay, what happened here, is that aportgen actually downgraded the package, because the git checkout of Alpine's aports were not up to date. This is my faul, as this is not documented yet and pmbootstrap doesn't handle this case gracefully either.

So this works for the first time:

$ pmbootstrap aportgen gcc-armhf gcc-aarch64 gcc-x86_64

But when running it again, the git repo needs to be updated first:

$ pmbootstrap chroot
# apk add git
# su - pmos
$ cd ~/git/aports_upstream
$ git pull
$ exit
# exit

Then you can run:

$ pmbootstrap aportgen gcc-armhf gcc-aarch64 gcc-x86_64

I've updated the gcc-* packages in master and I'm building them right now for the repo. I'll leave this issue open to fix the workflow properly in pmbootstrap.

EDIT: still figuring this out, I'm not sure the build runs through.

The trick is to specify the arch, then building it is working as expected:

$ pmbootstrap build --arch=x86_64 gcc-armhf

Otherwise it build for the first arch it finds in the APKBUILD, which is aarch64 in the case of gcc-armhf and armhf in the case of gcc-aarch64 (which got me really confused at first TBH).
That sounds also like something we could improve from pmbootstrap side, at least warn the user that this will probably not work.
EDIT: Or even better, fix it for real with a sane default, so building on Travis doesn't fail either.

Updated the instructions in the wiki and moved this to the very top:
https://wiki.postmarketos.org/wiki/Troubleshooting#ERROR:_unsatisfiable_constraints

@MartijnBraam: what do you think, are these good? I'm preparing a PR to fix the --arch=x86_64 issue right now, so that's not mentioned.

Yep the updated instructions are clear.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

craftyguy picture craftyguy  路  6Comments

ollieparanoid picture ollieparanoid  路  5Comments

erhoof picture erhoof  路  4Comments

zenety picture zenety  路  5Comments

ollieparanoid picture ollieparanoid  路  3Comments