mpsq / emacs-gcc-wayland-devel-builder

Emacs with native compilation ("gcc") and Wayland support
https://aur.archlinux.org/packages/emacs-gcc-wayland-devel-bin/
91 stars 5 forks source link

Error in build() #21

Closed sujay1844 closed 3 years ago

sujay1844 commented 3 years ago

(FYI: I'm a complete noob to emacs) I'm getting the following error when I try to install the AUR package using paru -S emacs-gcc-wayland-devel-bin. I thought the issue was with paru but then I tried using yay and got the same error. The error.log (When using paru) The last few lines of the error.log

../../../gcc-10.2.0/libcpp/expr.c:802:18: error: format not a string literal and no format arguments [-Werror=format-security]
  802 |        0, message);
      |                  ^
../../../gcc-10.2.0/libcpp/expr.c:805:39: error: format not a string literal and no format arguments [-Werror=format-security]
  805 |           virtual_location, 0, message);
      |                                       ^
cc1plus: some warnings being treated as errors
make[2]: *** [Makefile:224: expr.o] Error 1
make[2]: Leaving directory '/home/sujay1844/.cache/paru/clone/libgccjit/src/libgccjit-build/build-x86_64-pc-linux-gnu/libcpp'
make[1]: *** [Makefile:2850: all-build-libcpp] Error 2
make[1]: Leaving directory '/home/sujay1844/.cache/paru/clone/libgccjit/src/libgccjit-build'
make: *** [Makefile:940: all] Error 2
==> ERROR: A failure occurred in build().
    Aborting...
==> Making package: emacs-gcc-wayland-devel-bin 28.0.50.147973-1 (Thu Apr 22 11:42:14 2021)
==> Retrieving sources...
  -> Found 28.0.50.147973.tar.gz
==> Validating source files with sha512sums...
    28.0.50.147973.tar.gz ... Passed
==> Making package: emacs-gcc-wayland-devel-bin 28.0.50.147973-1 (Thu Apr 22 11:42:15 2021)
==> Checking runtime dependencies...
==> Missing dependencies:
  -> libgccjit
==> Checking buildtime dependencies...
==> ERROR: Could not resolve all dependencies.
:: Packages failed to build: libgccjit-10.2.0-2  
    emacs-gcc-wayland-devel-bin-28.0.50.147973-1
sujay1844@Stormbreaker ~ [1]> 

This is my system information:-

           Distro: Arch Linux 
Machine:   Type: Laptop System: Acer product: Swift SF314-42 v: V1.09 serial: <filter> 
           Mobo: RO model: Kona_RN v: V1.09 serial: <filter> UEFI: Insyde v: 1.09 
           date: 11/18/2020 
Battery:   ID-1: BAT1 charge: 38.6 Wh (99.5%) condition: 38.8/47.9 Wh (81.0%) volts: 12.6 
           min: 11.4 model: Murata AP18C4K status: Unknown 
CPU:       Info: 6-Core model: AMD Ryzen 5 4500U with Radeon Graphics bits: 64 type: MCP 
           arch: Zen 2 rev: 1 cache: L2: 3 MiB 
           flags: avx avx2 lm nx pae sse sse2 sse3 sse4_1 sse4_2 sse4a ssse3 svm 
           bogomips: 28446 
           Speed: 1602 MHz min/max: 1400/2375 MHz boost: enabled Core speeds (MHz): 1: 1602 
           2: 1448 3: 1441 4: 1736 5: 3717 6: 2564 
Graphics:  Device-1: AMD Renoir vendor: Acer Incorporated ALI driver: amdgpu v: kernel 
           bus-ID: 03:00.0 
           Device-2: Quanta HD User Facing type: USB driver: uvcvideo bus-ID: 1-3:2 
           Display: wayland server: X.Org 1.21.1.1 compositor: sway driver: loaded: amdgpu 
           unloaded: modesetting,vesa resolution: 1920x1080~60Hz 
           Message: Unable to show advanced data. Required tool glxinfo missing. 
Audio:     Device-1: AMD vendor: Acer Incorporated ALI driver: snd_hda_intel v: kernel 
           bus-ID: 03:00.1 
           Device-2: AMD Raven/Raven2/FireFlight/Renoir Audio Processor 
           vendor: Acer Incorporated ALI driver: snd_rn_pci_acp3x v: kernel bus-ID: 03:00.5 
           Device-3: AMD Family 17h HD Audio vendor: Acer Incorporated ALI 
           driver: snd_hda_intel v: kernel bus-ID: 03:00.6 
           Sound Server-1: ALSA v: k5.10.31-1-lts running: yes 
           Sound Server-2: sndio v: N/A running: no 
           Sound Server-3: JACK v: 0.125.0 running: no 
           Sound Server-4: PulseAudio v: 14.2 running: yes 
           Sound Server-5: PipeWire v: 0.3.25 running: yes 
Network:   Device-1: Intel Wi-Fi 6 AX200 driver: iwlwifi v: kernel bus-ID: 01:00.0 
           IF: wlp1s0 state: up mac: <filter> 
Bluetooth: Device-1: Intel AX200 Bluetooth type: USB driver: btusb v: 0.8 bus-ID: 1-4:3 
           Report: This feature requires one of these tools: hciconfig/bt-adapter 
Drives:    Local Storage: total: 476.94 GiB used: 77.45 GiB (16.2%) 
           ID-1: /dev/nvme0n1 vendor: SK Hynix model: HFM512GDJTNI-82A0A size: 476.94 GiB 
           temp: 38.9 C 
Partition: ID-1: / size: 216.88 GiB used: 77.3 GiB (35.6%) fs: ext4 dev: /dev/nvme0n1p6 
           ID-2: /boot size: 511 MiB used: 149.5 MiB (29.2%) fs: vfat dev: /dev/nvme0n1p4 
Swap:      ID-1: swap-1 type: partition size: 15.87 GiB used: 7.8 MiB (0.0%) 
           dev: /dev/nvme0n1p5 
Sensors:   System Temperatures: cpu: 55.6 C mobo: N/A gpu: amdgpu temp: 44.0 C 
           Fan Speeds (RPM): N/A 
Info:      Processes: 243 Uptime: 3h 10m Memory: 7.21 GiB used: 4.66 GiB (64.6%) 
           Init: systemd Compilers: gcc: 10.2.0 clang: 11.1.0 Packages: 1143 Shell: fish 
           v: 3.2.1 inxi: 3.3.03 
sujay1844 commented 3 years ago

Update: even aura gives the same error. So I don't the issue is with the AUR helper here.

mpsq commented 3 years ago

Your logs say:

==> Missing dependencies:
  -> libgccjit

Did you try to install libgccjit first?

sujay1844 commented 3 years ago

that is because libgccjit had an error and didn't install. You can see it in this part of the log:-

../../../gcc-10.2.0/libcpp/expr.c:802:18: error: format not a string literal and no format arguments [-Werror=format-security]
  802 |        0, message);
      |                  ^
../../../gcc-10.2.0/libcpp/expr.c:805:39: error: format not a string literal and no format arguments [-Werror=format-security]
  805 |           virtual_location, 0, message);
      |                                       ^
cc1plus: some warnings being treated as errors
make[2]: *** [Makefile:224: expr.o] Error 1
make[2]: Leaving directory '/home/sujay1844/.cache/paru/clone/libgccjit/src/libgccjit-build/build-x86_64-pc-linux-gnu/libcpp'
make[1]: *** [Makefile:2850: all-build-libcpp] Error 2
make[1]: Leaving directory '/home/sujay1844/.cache/paru/clone/libgccjit/src/libgccjit-build'
make: *** [Makefile:940: all] Error 2
==> ERROR: A failure occurred in build().

This is extract is from line 2620 to 2632 in the log file

mpsq commented 3 years ago

I see, I just tried and I can't reproduce the issue. libgccjit is not related to this repo though, you could comment on the corresponding AUR package instead: https://aur.archlinux.org/packages/libgccjit/

I would make sure that you are using the correct version of gcc and that you are not compiling the package with custom flags.

sujay1844 commented 3 years ago

When I checked the AUR package, it's flagged as out-dated gccjit

mpsq commented 3 years ago

Yes there is a 10.3.0 available version now -- still though, that should not make any difference

sujay1844 commented 3 years ago
aur/libgccjit 10.2.0-2 [+17 ~2.20] [Out-of-date: 2021-04-17]
    Just-In-Time Compilation using GCC.

This is the version in the AUR. How do I install 10.3.0? I can't find a github repo for libgccjit

mpsq commented 3 years ago

Why do you need 10.3.0? Emacs will work with 10.2.0 just fine.

sujay1844 commented 3 years ago

libgccjit is not related to this repo though, you could comment on the corresponding AUR package instead: https://aur.archlinux.org/packages/libgccjit/

I submitted a bug report Let's see what happens.

mpsq commented 3 years ago

I checked your bug report and as highlighted in my comment above, it looks like you are compiling libgccjit with custom flags (you could check CPPFLAGS). This flag is not set by the PKGBUILD, so it is something on your side.

I will close that issue since it is not related to this emacs-gcc-wayland-devel-builder.