I created a fresh crossdev environment and ran the merge user script on it, then I emerged bash inside the crossdev which reset the symlink on /bin and made it back to a normal folder, if I ran the merge user script again after that it put the symlink back and reinstalling bash seemed to no longer reset it Reproducible: Always Steps to Reproduce: 1.Create crossdev, my crossdev is x86_64-linux-gnu same as host 2.Run merge-usr script with --root set to the crossdev folder 3.Select a hardened openrc (merged-usr) profile for the crossdev 4.emerge-(crossdev) app-shells/bash Actual Results: the bin folder was reset back to a normal folder inside the crossdev environment instead of being a symlink Expected Results: the merge user should have stayed and not been reset
This likely has nothing to do with the bash ebuild, and is probably related to the profile you have selected in the cross-root. If you could provide the emerge output showing the /bin symlink being removed, that might help.
Please also provide emerge --info from your cross-emerge.
You were right it has nothing to do with bash, it's the crossdev itself, it doesn't make a /bin folder so there is nothing for the merge-usr script to symlink to /usr/bin, bash if the first program from @system to actually install in /bin rather than /usr/bin and the next package alternatives/sh fails as it sees the /bin folder not symlinked on a merge-usr profile default/linux/amd64/23.0/hardened ls -l of the crossdev drwxr-xr-x 1 root root 21 Sep 30 12:43 etc drwxr-xr-x 2 root root 60 Sep 30 12:43 lib drwxr-xr-x 2 root root 4096 Sep 30 12:43 lib64 drwxr-xr-x 2 root root 33 Sep 30 12:43 sbin lrwxrwxrwx 1 root root 11 Sep 30 12:43 sys-include -> usr/include drwxr-xr-x 8 root root 81 Sep 30 12:43 usr drwxr-xr-x 3 root root 16 Sep 30 12:43 var of course after the merge-usr script drwxr-xr-x 1 root root 21 Sep 30 12:43 etc lrwxrwxrwx 1 root root 7 Oct 3 05:49 lib -> usr/lib lrwxrwxrwx 1 root root 9 Oct 3 05:49 lib64 -> usr/lib64 lrwxrwxrwx 1 root root 7 Oct 3 05:49 sbin -> usr/bin lrwxrwxrwx 1 root root 11 Sep 30 12:43 sys-include -> usr/include drwxr-xr-x 1 root root 42 Oct 3 05:49 usr drwxr-xr-x 3 root root 16 Sep 30 12:43 var ROOT=/usr/x86_64-epic-linux-gnu/ If I run mkdir ${ROOT}/bin and then run merge-usr --root ${ROOT} then installing bash doesn't break anything the crossdev I am using is crossdev --target x86_64-epic-linux-gnu --stable I guess this isn't really a bug but me just not looking well enough.
I would suggest running the following to populate your ROOT after running crossdev: USE=build x86_64-epic-linux-gnu-emerge -v1O sys-apps/baselayout Note the "build" USE flag; this is important. This should install the base directory layout, including an empty /bin directory (or a /bin symlink if on a merged-usr profile).
(In reply to Mike Gilbert from comment #4) > I would suggest running the following to populate your ROOT after running > crossdev: > > USE=build x86_64-epic-linux-gnu-emerge -v1O sys-apps/baselayout > > Note the "build" USE flag; this is important. > > This should install the base directory layout, including an empty /bin > directory (or a /bin symlink if on a merged-usr profile). Thanks, didn't know about this.