Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fails to build #10

Closed
matthiasbeyer opened this issue Feb 26, 2020 · 1 comment
Closed

Fails to build #10

matthiasbeyer opened this issue Feb 26, 2020 · 1 comment

Comments

@matthiasbeyer
Copy link

Hi,

I get

The Meson build system
Version: 0.52.1
Source dir: /tmp/nix-build-swappy-2020-02-26.drv-0/source
Build dir: /tmp/nix-build-swappy-2020-02-26.drv-0/source/build
Build type: native build
Project name: swappy
Project version: 1.0.0
C compiler for the host machine: /nix/store/1kn7fi3hhi33jms3113riyzwyn2yqpqd-gcc-wrapper-9.2.0/bin/cc (gcc 9.2.0 "gcc (GCC) 9.2.0")
C linker for the host machine: GNU ld.bfd 2.31.1
Host machine cpu family: x86_64
Host machine cpu: x86_64
Found pkg-config: /nix/store/w6pfcj87889hgz0f77blq59z85mdrsh8-pkg-config-0.29.2/bin/pkg-config (0.29.2)
Run-time dependency cairo found: YES 1.16.0
Run-time dependency pango found: YES 1.44.7
Library m found: YES
Library rt found: YES
Run-time dependency gtk+-3.0 found: YES 3.24.13
Run-time dependency wayland-client found: YES 1.18.0
Run-time dependency wayland-cursor found: YES 1.18.0
Run-time dependency wayland-protocols found: YES 1.18
Run-time dependency libnotify found: YES 0.7.8
Found pkg-config: /nix/store/w6pfcj87889hgz0f77blq59z85mdrsh8-pkg-config-0.29.2/bin/pkg-config (0.29.2)
Program wayland-scanner found: YES (/nix/store/iy3kwxmv486mjm9qd9mszrh7by92bjch-wayland-1.18.0/bin/wayland-scanner)
Program scdoc found: YES (/nix/store/6fl4pl3l742in7pzndxw2syg1hrzykhf-scdoc-1.10.1/bin/scdoc)
Program sh found: YES (/nix/store/1iaxkm0941nj1m4m5g4fxgg4cq5jckf0-bash-4.4-p23/bin/sh)
Build targets in project: 5
Found ninja-1.10.0 at /nix/store/5x6l9s9idzf44np1wz1kv8pyq246q98h-ninja-1.10.0/bin/ninja
meson: enabled parallel building
building
build flags: -j4 -l4
[17/31] Compiling C object 'swappy@exe/src_buffer.c.o'.res_swappy.c.o'.ed_wlr-screencopy-unstable-v1-protocol.c.o'.
FAILED: swappy@exe/src_buffer.c.o 
/nix/store/1kn7fi3hhi33jms3113riyzwyn2yqpqd-gcc-wrapper-9.2.0/bin/cc -Iswappy@exe -I. -I.. -I../include -Ires -I/nix/store/a92yhf0icjl9lh553s4qjchdsm8lyzsy-cairo-1.16.0-dev/include/cairo -I/nix/store/1zlkr4x0bvxw3mn65chw9v3b48n8jh52-freetype-2.10.1-dev/include/freetype2 -I/nix/store/1zlkr4x0bvxw3mn65chw9v3b48n8jh52-freetype-2.10.1-dev/include -I/nix/store/5ad0cyv6lxpkk2m1prcrasdp2pysz73q-glib-2.62.4-dev/include -I/nix/store/5ad0cyv6lxpkk2m1prcrasdp2pysz73q-glib-2.62.4-dev/include/glib-2.0 -I/nix/store/vwvjrh97byihk40gwl26f0lnb3w405cv-glib-2.62.4/lib/glib-2.0/include -I/nix/store/sm843466f7cvhf1b804jjlay1nv7fyq0-pango-1.44.7-dev/include/pango-1.0 -I/nix/store/70yjv9sr9mhf75bliwmmxgyr37mx9lac-harfbuzz-2.6.4-dev/include/harfbuzz -I/nix/store/i5yw4gdhknqahzhkaqjfbgc9ydb2885w-gtk+3-3.24.13-dev/include/gtk-3.0 -I/nix/store/vmm5hrcbqrb7b605dnir17qbiz85x17n-atk-2.34.1-dev/include/atk-1.0 -I/nix/store/4w16ai3cx8sp7av9kc432w34r4fpdmfp-gdk-pixbuf-2.40.0-dev/include/gdk-pixbuf-2.0 -I/nix/store/i1mssjnbih9czf12fcda1883pvkirgss-libnotify-0.7.8-dev/include -I/nix/store/iy3kwxmv486mjm9qd9mszrh7by92bjch-wayland-1.18.0/include -fdiagnostics-color=always -pipe -D_FILE_OFFSET_BITS=64 -Werror -std=c11 -Wno-unused-parameter -DHAVE_LIBNOTIFY -DHAVE_WAYLAND_PROTOCOLS -MD -MQ 'swappy@exe/src_buffer.c.o' -MF 'swappy@exe/src_buffer.c.o.d' -o 'swappy@exe/src_buffer.c.o' -c ../src/buffer.c
../src/buffer.c: In function 'randname':
../src/buffer.c:12:3: error: implicit declaration of function 'clock_gettime' [-Werror=implicit-function-declaration]
   12 |   clock_gettime(CLOCK_REALTIME, &ts);
      |   ^~~~~~~~~~~~~
../src/buffer.c:12:17: error: 'CLOCK_REALTIME' undeclared (first use in this function)
   12 |   clock_gettime(CLOCK_REALTIME, &ts);
      |                 ^~~~~~~~~~~~~~
../src/buffer.c:12:17: note: each undeclared identifier is reported only once for each function it appears in
../src/buffer.c: In function 'create_shm_file':
../src/buffer.c:45:7: error: implicit declaration of function 'ftruncate'; did you mean 'strncat'? [-Werror=implicit-function-declaration]
   45 |   if (ftruncate(fd, size) < 0) {
      |       ^~~~~~~~~
      |       strncat
cc1: all warnings being treated as errors
[20/31] Compiling C object 'swappy@exe/src_render.c.o'.'.
ninja: build stopped: subcommand failed.
@jtheoof
Copy link
Owner

jtheoof commented Feb 26, 2020

Hi @matthiasbeyer it seems some includes are required in your distribution. I would gladly accept a MR for this one.

jtheoof added a commit that referenced this issue May 17, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants