dnschneid / crouton

Chromium OS Universal Chroot Environment
https://goo.gl/fd3zc?si=1
BSD 3-Clause "New" or "Revised" License
8.57k stars 1.24k forks source link

Crouton CRAS fails to compile with gcc: error: unrecognized command line option '-Wundef-prefix=HAVE_,CRAS_' #4923

Open DerenCinar opened 1 year ago

DerenCinar commented 1 year ago
Please paste the output of the following command here: sudo edit-chroot -all

chronos@localhost /usr/local $ sudo edit-chroot -all
name: xenial
encrypted: no
Entering /mnt/stateful_partition/crouton/chroots/xenial...
/usr/local/bin/crash_reporter_wrapper: 119: exec: /var/run/crw/crw: Permission denied
WARNING: Unable to register core dump handler.
crouton: version git
release: xenial
architecture: amd64
xmethod: xorg
targets: gnome
host: version 15312.0.0 (Official Build) canary-channel hatch 
kernel: Linux localhost 5.15.87-15831-g3504cc8bdad1 #1 SMP PREEMPT Fri Jan 13 04:45:38 PST 2023 x86_64 x86_64 x86_64 GNU/Linux
freon: yes
Unmounting /mnt/stateful_partition/crouton/chroots/xenial...

Please describe your issue:

I'm doing a fresh installation of crouton. I was able to successfully install Xenial before just fine, but not anymore.

$ sudo crouton -r xenial -t gnome

...
patch is already the newest version (2.7.5-1ubuntu0.16.04.2).
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
Compiling CRAS (native)...
gcc: error:  unrecognized command line option '-Wundef-prefix=HAVE_,CRAS_'

If known, describe the steps to reproduce the issue:

Happens everytime now on ChromeOS Canary channel 111.0.5535.0, with the developer mode turned on.

Temporary fix

I was able to fix the issue, at least for now, by changing the targets/audio file to remove anything with undef-prefix:

Line 286:
        sed -i -e 's/\-Wundef\-prefix=HAVE_,CRAS_//g' Makefile.am                                                                                                                                         
        sed -i -e 's/\-Werror=undef-prefix//g' Makefile.am   
Nico359 commented 1 year ago

Where do I find the targets/audio file you are speaking of? I am sorry if I missed something in the text.

NBT22 commented 1 year ago

It seems as though this is a problem with ChromeOS 111. I had this same problem and was able to fix it by rolling back to the stable channel (109 in my case).

grekpg commented 1 year ago

Any new fixes ? where is targets/audio ?

cicciocanestro commented 1 year ago

Any new fixes ? where is targets/audio ?

probably here:

/mnt/stateful_partition/crouton/chroots/xenial...

02tz commented 1 year ago
Please paste the output of the following command here: sudo edit-chroot -all

chronos@localhost /usr/local $ sudo edit-chroot -all
name: xenial
encrypted: no
Entering /mnt/stateful_partition/crouton/chroots/xenial...
/usr/local/bin/crash_reporter_wrapper: 119: exec: /var/run/crw/crw: Permission denied
WARNING: Unable to register core dump handler.
crouton: version git
release: xenial
architecture: amd64
xmethod: xorg
targets: gnome
host: version 15312.0.0 (Official Build) canary-channel hatch 
kernel: Linux localhost 5.15.87-15831-g3504cc8bdad1 #1 SMP PREEMPT Fri Jan 13 04:45:38 PST 2023 x86_64 x86_64 x86_64 GNU/Linux
freon: yes
Unmounting /mnt/stateful_partition/crouton/chroots/xenial...

Please describe your issue:

I'm doing a fresh installation of crouton. I was able to successfully install Xenial before just fine, but not anymore.

$ sudo crouton -r xenial -t gnome

...
patch is already the newest version (2.7.5-1ubuntu0.16.04.2).
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
Compiling CRAS (native)...
gcc: error:  unrecognized command line option '-Wundef-prefix=HAVE_,CRAS_'

If known, describe the steps to reproduce the issue:

Happens everytime now on ChromeOS Canary channel 111.0.5535.0, with the developer mode turned on.

Temporary fix

I was able to fix the issue, at least for now, by changing the targets/audio file to remove anything with undef-prefix:

Line 286:
        sed -i -e 's/\-Wundef\-prefix=HAVE_,CRAS_//g' Makefile.am                                                                                                                                         
        sed -i -e 's/\-Werror=undef-prefix//g' Makefile.am   

where is that file?

nsrazdan commented 1 year ago

where is that file?

Did you manage to locate it?

KinectTheUnknown commented 1 year ago
Please paste the output of the following command here: sudo edit-chroot -all

chronos@localhost /usr/local $ sudo edit-chroot -all
name: xenial
encrypted: no
Entering /mnt/stateful_partition/crouton/chroots/xenial...
/usr/local/bin/crash_reporter_wrapper: 119: exec: /var/run/crw/crw: Permission denied
WARNING: Unable to register core dump handler.
crouton: version git
release: xenial
architecture: amd64
xmethod: xorg
targets: gnome
host: version 15312.0.0 (Official Build) canary-channel hatch 
kernel: Linux localhost 5.15.87-15831-g3504cc8bdad1 #1 SMP PREEMPT Fri Jan 13 04:45:38 PST 2023 x86_64 x86_64 x86_64 GNU/Linux
freon: yes
Unmounting /mnt/stateful_partition/crouton/chroots/xenial...

Please describe your issue:

I'm doing a fresh installation of crouton. I was able to successfully install Xenial before just fine, but not anymore.

$ sudo crouton -r xenial -t gnome

...
patch is already the newest version (2.7.5-1ubuntu0.16.04.2).
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
Compiling CRAS (native)...
gcc: error:  unrecognized command line option '-Wundef-prefix=HAVE_,CRAS_'

If known, describe the steps to reproduce the issue:

Happens everytime now on ChromeOS Canary channel 111.0.5535.0, with the developer mode turned on.

Temporary fix

I was able to fix the issue, at least for now, by changing the targets/audio file to remove anything with undef-prefix:

Line 286:
        sed -i -e 's/\-Wundef\-prefix=HAVE_,CRAS_//g' Makefile.am                                                                                                                                         
        sed -i -e 's/\-Werror=undef-prefix//g' Makefile.am   

where is that file?

It's in the source code of this repo

gucara commented 1 year ago

Is there any possibility for a fix in https://github.com/dnschneid/crouton/blob/master/targets/audio?

At least to check the fix proposed.

At this point I'm unable to install Crouton on my new Chromebook. Thanks

02tz commented 1 year ago

no

On Sun, Mar 19, 2023 at 9:31 PM Nikhil Razdan @.***> wrote:

where is that file?

Did you manage to locate it?

— Reply to this email directly, view it on GitHub https://github.com/dnschneid/crouton/issues/4923#issuecomment-1475607291, or unsubscribe https://github.com/notifications/unsubscribe-auth/AQPWG2RNUMKP3NARB3MUO7LW47MSVANCNFSM6AAAAAAT3R7A4E . You are receiving this because you commented.Message ID: @.***>

gucara commented 1 year ago

Thanks for #4957 @mkststrahilov

DennisLfromGA commented 1 year ago

Also, see: Figure out a way to build audio target now that autotools is removed #4958