Re: [gentoo-user] Illegal State in Chroot Environment

2017-08-07 Thread Neil Bothwick
On Mon, 7 Aug 2017 13:29:03 -0400, P Levine wrote:

> > Currently I am rebuilding the whole system using `emerge -e world` and
> > everything is failing as early as the unpack phase.
> > Do I have to download stage from the beginning for the 3rd time!
> >  
> 
> The problem is it looks like you built and installed bzip2 with the
> incompatible CFLAGS.  Because this is used by portage to unpack tar.bz2
> files during the unpack phase, emerge can't really proceed.  Unless you
> have a binary package for bzip2 built with good CFLAGS lying around in
> you system, you should start again.

You might get away with copying bzip2 and libbz2.* from the stage 3 to
your filesystem, then re-emerge bzip2 with same flags.


-- 
Neil Bothwick

Plagarism prohibited. Derive carefully.


pgpY7rT74GUAS.pgp
Description: OpenPGP digital signature


Re: [gentoo-user] Illegal State in Chroot Environment

2017-08-07 Thread P Levine
On Mon, Aug 7, 2017 at 10:11 AM, symack  wrote:
>
> Currently I am rebuilding the whole system using `emerge -e world` and
> everything is failing as early as the unpack phase.
> Do I have to download stage from the beginning for the 3rd time!
>

The problem is it looks like you built and installed bzip2 with the
incompatible CFLAGS.  Because this is used by portage to unpack tar.bz2
files during the unpack phase, emerge can't really proceed.  Unless you
have a binary package for bzip2 built with good CFLAGS lying around in you
system, you should start again.


Re: [gentoo-user] Illegal State in Chroot Environment

2017-08-07 Thread symack
On Sun, Aug 6, 2017 at 11:58 PM, P Levine  wrote:

>
>
> On Sun, Aug 6, 2017 at 9:17 PM, symack  wrote:
>>
>> >>> Installing (4 of 199) app-arch/bzip2-1.0.6-r8::gentoo
>> bash: line 1: 26183 Illegal instruction 
>> ${PORTAGE_BUNZIP2_COMMAND:-${PORTAGE_BZIP2_COMMAND}
>> -d} -c -- /var/db/pkg/app-arch/bzip2-1.0.6-r8/environment.bz2 >
>> /var/tmp/portage/._unmerge_/app-arch/bzip2-1.0.6-r8/temp/environment
>> ​​
>>
> CFLAGS="-O2 -pipe -fomit-frame-pointer -mcx16 -msahf -maes
>> ​​
>> -mpclmul -mpopcnt -mabm -mlwp -mavx -march=native"
>>
>> ​One or more "-m" flags in CFLAGS isn't valid for the host processor​.
> Why have them in the first place if you've enabled -march=native?
>


Hello,

Thank you for your response. I have changed the CFLAGS to look like the
following:

CFLAGS="-O2 -pipe -fomit-frame-pointer -march=native"

Anything I do within chroot is returning `Illegal State` and made the
change from the livecd
environment.

Currently I am rebuilding the whole system using `emerge -e world` and
everything is failing as early as the unpack phase.
Do I have to download stage from the beginning for the 3rd time!

Any help to recover this instance is greatly appreciated.


Re: [gentoo-user] Illegal State in Chroot Environment

2017-08-06 Thread P Levine
On Sun, Aug 6, 2017 at 9:17 PM, symack  wrote:
>
> >>> Installing (4 of 199) app-arch/bzip2-1.0.6-r8::gentoo
> bash: line 1: 26183 Illegal instruction 
> ${PORTAGE_BUNZIP2_COMMAND:-${PORTAGE_BZIP2_COMMAND}
> -d} -c -- /var/db/pkg/app-arch/bzip2-1.0.6-r8/environment.bz2 >
> /var/tmp/portage/._unmerge_/app-arch/bzip2-1.0.6-r8/temp/environment
> ​​
>
CFLAGS="-O2 -pipe -fomit-frame-pointer -mcx16 -msahf -maes
> ​​
> -mpclmul -mpopcnt -mabm -mlwp -mavx -march=native"
>
> ​One or more "-m" flags in CFLAGS isn't valid for the host processor​.
Why have them in the first place if you've enabled -march=native?


[gentoo-user] Illegal State in Chroot Environment

2017-08-06 Thread symack
Hello Everyone, I was able to get as far as installing grub however through
the installation I would find some strange behaviour such as not being able
to mount /dev/sda2 to the boot directory. I would do it on the livecd (ie,
mount /dev/sda2 /mnt/gentoo/boot).

When it came to installing `grub grub-install /dev/sda` I got an 'Illegal
State'. emerge -e world would fail with:

>>> Installing (4 of 199) app-arch/bzip2-1.0.6-r8::gentoo
bash: line 1: 26183 Illegal instruction
${PORTAGE_BUNZIP2_COMMAND:-${PORTAGE_BZIP2_COMMAND} -d} -c --
/var/db/pkg/app-arch/bzip2-1.0.6-r8/environment.bz2 >
/var/tmp/portage/._unmerge_/app-arch/bzip2-1.0.6-r8/temp/environment
!!! FAILED prerm: 132
 * ERROR: app-arch/bzip2-1.0.6-r8::gentoo failed (postrm phase):
 *   eutils.eclass could not be found by inherit()
 *
 * Call stack:
 *   ebuild.sh, line 611:  Called source
'/var/db/pkg/app-arch/bzip2-1.0.6-r8/bzip2-1.0.6-r8.ebuild'
 *   bzip2-1.0.6-r8.ebuild, line   9:  Called inherit 'eutils'
'toolchain-funcs' 'multilib' 'multilib-minimal'
 *   ebuild.sh, line 284:  Called die
 * The specific snippet of code:
 *   [[ -z ${location} ]] && die "${1}.eclass could not be found by
inherit()"
 *
 * If you need support, post the output of `emerge --info
'=app-arch/bzip2-1.0.6-r8::gentoo'`,
 * the complete build log and the output of `emerge -pqv
'=app-arch/bzip2-1.0.6-r8::gentoo'`.
 * The complete build log is located at
'/var/tmp/portage/._unmerge_/app-arch/bzip2-1.0.6-r8/temp/build.log'.
 * The ebuild environment file is located at
'/var/tmp/portage/._unmerge_/app-arch/bzip2-1.0.6-r8/temp/die.env'.
 * Working directory:
'/var/tmp/portage/._unmerge_/app-arch/bzip2-1.0.6-r8/homedir'
 * S: '/var/tmp/portage/._unmerge_/app-arch/bzip2-1.0.6-r8/work/bzip2-1.0.6'
 * QA Notice: ECLASS 'eutils' inherited illegally in
app-arch/bzip2-1.0.6-r8
 * ERROR: app-arch/bzip2-1.0.6-r8::gentoo failed:
 *   eutils.eclass could not be found by inherit()
 *
 * Call stack:
 *   misc-functions.sh, line  17:  Called source
'/var/tmp/portage/._portage_reinstall_.vay4msqy/bin/ebuild.sh'
 *   ebuild.sh, line 611:  Called source
'/var/db/pkg/app-arch/bzip2-1.0.6-r8/bzip2-1.0.6-r8.ebuild'
 *   bzip2-1.0.6-r8.ebuild, line   9:  Called inherit 'eutils'
'toolchain-funcs' 'multilib' 'multilib-minimal'
 *   ebuild.sh, line 284:  Called die
 * The specific snippet of code:
 *   [[ -z ${location} ]] && die "${1}.eclass could not be found by
inherit()"
 *
 * If you need support, post the output of `emerge --info
'=app-arch/bzip2-1.0.6-r8::gentoo'`,
 * the complete build log and the output of `emerge -pqv
'=app-arch/bzip2-1.0.6-r8::gentoo'`.
 * The complete build log is located at
'/var/tmp/portage/._unmerge_/app-arch/bzip2-1.0.6-r8/temp/build.log'.
 * The ebuild environment file is located at
'/var/tmp/portage/._unmerge_/app-arch/bzip2-1.0.6-r8/temp/die.env'.
 * Working directory:
'/var/tmp/portage/._unmerge_/app-arch/bzip2-1.0.6-r8/homedir'
 * S: '/var/tmp/portage/._unmerge_/app-arch/bzip2-1.0.6-r8/work/bzip2-1.0.6'
!!! FAILED postrm: 1
 * The 'postrm' phase of the 'app-arch/bzip2-1.0.6-r8' package has failed
 * with exit value 1.
 *
 * The problem occurred while executing the ebuild file named
 * 'bzip2-1.0.6-r8.ebuild' located in the '/var/db/pkg/app-
 * arch/bzip2-1.0.6-r8' directory. If necessary, manually remove the
 * environment.bz2 file and/or the ebuild file located in that directory.
 *
 * Removal of the environment.bz2 file is preferred since it may allow the
 * removal phases to execute successfully. The ebuild will be sourced and
 * the eclasses from the current portage tree will be used when necessary.
 * Removal of the ebuild file will cause the pkg_prerm() and pkg_postrm()
 * removal phases to be skipped entirely.
Traceback (most recent call last):
  File
"/var/tmp/portage/._portage_reinstall_.vay4msqy/bin/filter-bash-environment.py",
line 157, in 
re.compile(var_pattern), file_in, file_out)
  File
"/var/tmp/portage/._portage_reinstall_.vay4msqy/bin/filter-bash-environment.py",
line 81, in filter_bash_environment
file_out.write(line.replace("\1", ""))
BrokenPipeError: [Errno 32] Broken pipe
 * ERROR: app-arch/bzip2-1.0.6-r8::gentoo failed (postinst phase):
 *   filter-bash-environment.py failed
 *
 * Call stack:
 *ebuild.sh, line 767:  Called __ebuild_main 'postinst'
 *   phase-functions.sh, line 949:  Called __filter_readonly_variables
'--filter-path' '--filter-sandbox' '--allow-extra-vars'
 *   phase-functions.sh, line 137:  Called die
 * The specific snippet of code:
 *   "${PORTAGE_PYTHON:-/usr/bin/python}"
"${PORTAGE_BIN_PATH}"/filter-bash-environment.py "${filtered_vars}" || die
"filter-bash-environment.py failed"
 *
 * If you need support, post the output of `emerge --info
'=app-arch/bzip2-1.0.6-r8::gentoo'`,
 * the complete build log and the output of `emerge -pqv
'=app-arch/bzip2-1.0.6-r8::gentoo'`.
 * The complete build log is located at