unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* Build failure: 'seccomp-filter'
@ 2021-04-11  6:45 Colin Baxter
  2021-04-11  7:41 ` Eli Zaretskii
  0 siblings, 1 reply; 15+ messages in thread
From: Colin Baxter @ 2021-04-11  6:45 UTC (permalink / raw)
  To: emacs-devel

Hello,

I get a build with the latest pull of emacs:

Makefile:415: recipe for target 'seccomp-filter' failed
make[1]: *** [seccomp-filter] Error 1
make[1]: Leaving directory '/home/redknight/git/emacs/lib-src'
Makefile:396: recipe for target 'lib-src' failed
make: *** [lib-src] Error 2

Best wishes,

Colin Baxter.



^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: Build failure: 'seccomp-filter'
  2021-04-11  6:45 Build failure: 'seccomp-filter' Colin Baxter
@ 2021-04-11  7:41 ` Eli Zaretskii
  2021-04-11  7:50   ` Colin Baxter
  0 siblings, 1 reply; 15+ messages in thread
From: Eli Zaretskii @ 2021-04-11  7:41 UTC (permalink / raw)
  To: Colin Baxter; +Cc: emacs-devel

> From: Colin Baxter <m43cap@yandex.com>
> Cc: 
> Date: Sun, 11 Apr 2021 07:45:19 +0100
> 
> I get a build with the latest pull of emacs:
> 
> Makefile:415: recipe for target 'seccomp-filter' failed
> make[1]: *** [seccomp-filter] Error 1
> make[1]: Leaving directory '/home/redknight/git/emacs/lib-src'
> Makefile:396: recipe for target 'lib-src' failed
> make: *** [lib-src] Error 2

Are there no error or warning messages before the "Makefile:415" one?
If there are, please show all the messages.

Thanks.



^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: Build failure: 'seccomp-filter'
  2021-04-11  7:41 ` Eli Zaretskii
@ 2021-04-11  7:50   ` Colin Baxter
  2021-04-11 10:12     ` Philipp Stephani
  0 siblings, 1 reply; 15+ messages in thread
From: Colin Baxter @ 2021-04-11  7:50 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: emacs-devel

>>>>> Eli Zaretskii <eliz@gnu.org> writes:

    >> From: Colin Baxter <m43cap@yandex.com> Cc: Date: Sun, 11 Apr 2021
    >> 07:45:19 +0100
    >> 
    >> I get a build with the latest pull of emacs:
    >> 
    >> Makefile:415: recipe for target 'seccomp-filter' failed make[1]:
    >> *** [seccomp-filter] Error 1 make[1]: Leaving directory
    >> '/home/redknight/git/emacs/lib-src' Makefile:396: recipe for
    >> target 'lib-src' failed make: *** [lib-src] Error 2

    > Are there no error or warning messages before the "Makefile:415"
    > one?  If there are, please show all the messages.

Yes, sorry, I missed the earlier errors. Here is the full list beginning
after the attempt to compile seccomp-filter:

---------- Begin error list ------------

  CCLD     seccomp-filter
seccomp-filter.c: In function ‘main’:
seccomp-filter.c:142:23: error: ‘SCMP_ACT_KILL_PROCESS’ undeclared (first use in this function)
   ctx = seccomp_init (SCMP_ACT_KILL_PROCESS);
                       ^~~~~~~~~~~~~~~~~~~~~
seccomp-filter.c:142:23: note: each undeclared identifier is reported only once for each function it appears in
seccomp-filter.c:151:18: error: ‘SCMP_FLTATR_CTL_LOG’ undeclared (first use in this function)
   set_attribute (SCMP_FLTATR_CTL_LOG, 0);
                  ^~~~~~~~~~~~~~~~~~~
In file included from seccomp-filter.c:55:0:
../lib/verify.h:213:41: error: static assertion failed: "verify (sizeof (void *) == 8)"
 # define _GL_VERIFY(R, DIAGNOSTIC, ...) _Static_assert (R, DIAGNOSTIC)
                                         ^
../lib/verify.h:273:20: note: in expansion of macro ‘_GL_VERIFY’
 # define verify(R) _GL_VERIFY (R, "verify (" #R ")", -)
                    ^~~~~~~~~~
seccomp-filter.c:156:3: note: in expansion of macro ‘verify’
   verify (sizeof (void *) == 8);
   ^~~~~~
seccomp-filter.c:169:9: warning: implicit declaration of function ‘SCMP_A2_32’ [-Wimplicit-function-declaration]
         SCMP_A2_32 (SCMP_CMP_MASKED_EQ,
         ^
seccomp-filter.c:105:48: note: in definition of macro ‘RULE’
       const struct scmp_arg_cmp arg_array[] = {__VA_ARGS__};         \
                                                ^~~~~~~~~~~
seccomp-filter.c:105:20: warning: nested extern declaration of ‘SCMP_A2_32’ [-Wnested-externs]
       const struct scmp_arg_cmp arg_array[] = {__VA_ARGS__};         \
                    ^
seccomp-filter.c:168:3: note: in expansion of macro ‘RULE’
   RULE (SCMP_ACT_ALLOW, SCMP_SYS (mmap),
   ^~~~
seccomp-filter.c:174:9: warning: implicit declaration of function ‘SCMP_A3_32’ [-Wimplicit-function-declaration]
         SCMP_A3_32 (SCMP_CMP_MASKED_EQ,
         ^
seccomp-filter.c:105:48: note: in definition of macro ‘RULE’
       const struct scmp_arg_cmp arg_array[] = {__VA_ARGS__};         \
                                                ^~~~~~~~~~~
seccomp-filter.c:105:20: warning: nested extern declaration of ‘SCMP_A3_32’ [-Wnested-externs]
       const struct scmp_arg_cmp arg_array[] = {__VA_ARGS__};         \
                    ^
seccomp-filter.c:168:3: note: in expansion of macro ‘RULE’
   RULE (SCMP_ACT_ALLOW, SCMP_SYS (mmap),
   ^~~~
seccomp-filter.c:105:47: warning: missing braces around initializer [-Wmissing-braces]
       const struct scmp_arg_cmp arg_array[] = {__VA_ARGS__};         \
                                               ^
seccomp-filter.c:168:3: note: in expansion of macro ‘RULE’
   RULE (SCMP_ACT_ALLOW, SCMP_SYS (mmap),
   ^~~~
seccomp-filter.c:105:47: note: (near initialization for ‘arg_array’)
       const struct scmp_arg_cmp arg_array[] = {__VA_ARGS__};         \
                                               ^
seccomp-filter.c:168:3: note: in expansion of macro ‘RULE’
   RULE (SCMP_ACT_ALLOW, SCMP_SYS (mmap),
   ^~~~
seccomp-filter.c:105:47: warning: missing braces around initializer [-Wmissing-braces]
       const struct scmp_arg_cmp arg_array[] = {__VA_ARGS__};         \
                                               ^
seccomp-filter.c:179:3: note: in expansion of macro ‘RULE’
   RULE (SCMP_ACT_ALLOW, SCMP_SYS (mmap),
   ^~~~
seccomp-filter.c:105:47: note: (near initialization for ‘arg_array’)
       const struct scmp_arg_cmp arg_array[] = {__VA_ARGS__};         \
                                               ^
seccomp-filter.c:179:3: note: in expansion of macro ‘RULE’
   RULE (SCMP_ACT_ALLOW, SCMP_SYS (mmap),
   ^~~~
seccomp-filter.c:105:47: warning: missing braces around initializer [-Wmissing-braces]
       const struct scmp_arg_cmp arg_array[] = {__VA_ARGS__};         \
                                               ^
seccomp-filter.c:189:3: note: in expansion of macro ‘RULE’
   RULE (SCMP_ACT_ALLOW, SCMP_SYS (mprotect),
   ^~~~
seccomp-filter.c:105:47: note: (near initialization for ‘arg_array’)
       const struct scmp_arg_cmp arg_array[] = {__VA_ARGS__};         \
                                               ^
seccomp-filter.c:189:3: note: in expansion of macro ‘RULE’
   RULE (SCMP_ACT_ALLOW, SCMP_SYS (mprotect),
   ^~~~
seccomp-filter.c:196:9: warning: implicit declaration of function ‘SCMP_A1_32’ [-Wimplicit-function-declaration]
         SCMP_A1_32 (SCMP_CMP_EQ, FUTEX_WAKE_PRIVATE));
         ^
seccomp-filter.c:105:48: note: in definition of macro ‘RULE’
       const struct scmp_arg_cmp arg_array[] = {__VA_ARGS__};         \
                                                ^~~~~~~~~~~
seccomp-filter.c:105:20: warning: nested extern declaration of ‘SCMP_A1_32’ [-Wnested-externs]
       const struct scmp_arg_cmp arg_array[] = {__VA_ARGS__};         \
                    ^
seccomp-filter.c:195:3: note: in expansion of macro ‘RULE’
   RULE (SCMP_ACT_ALLOW, SCMP_SYS (futex),
   ^~~~
seccomp-filter.c:105:47: warning: missing braces around initializer [-Wmissing-braces]
       const struct scmp_arg_cmp arg_array[] = {__VA_ARGS__};         \
                                               ^
seccomp-filter.c:195:3: note: in expansion of macro ‘RULE’
   RULE (SCMP_ACT_ALLOW, SCMP_SYS (futex),
   ^~~~
seccomp-filter.c:105:47: note: (near initialization for ‘arg_array’)
       const struct scmp_arg_cmp arg_array[] = {__VA_ARGS__};         \
                                               ^
seccomp-filter.c:195:3: note: in expansion of macro ‘RULE’
   RULE (SCMP_ACT_ALLOW, SCMP_SYS (futex),
   ^~~~
seccomp-filter.c:105:47: warning: missing braces around initializer [-Wmissing-braces]
       const struct scmp_arg_cmp arg_array[] = {__VA_ARGS__};         \
                                               ^
seccomp-filter.c:238:3: note: in expansion of macro ‘RULE’
   RULE (SCMP_ACT_ALLOW, SCMP_SYS (open),
   ^~~~
seccomp-filter.c:105:47: note: (near initialization for ‘arg_array’)
       const struct scmp_arg_cmp arg_array[] = {__VA_ARGS__};         \
                                               ^
seccomp-filter.c:238:3: note: in expansion of macro ‘RULE’
   RULE (SCMP_ACT_ALLOW, SCMP_SYS (open),
   ^~~~
seccomp-filter.c:105:47: warning: missing braces around initializer [-Wmissing-braces]
       const struct scmp_arg_cmp arg_array[] = {__VA_ARGS__};         \
                                               ^
seccomp-filter.c:243:3: note: in expansion of macro ‘RULE’
   RULE (SCMP_ACT_ALLOW, SCMP_SYS (openat),
   ^~~~
seccomp-filter.c:105:47: note: (near initialization for ‘arg_array’)
       const struct scmp_arg_cmp arg_array[] = {__VA_ARGS__};         \
                                               ^
seccomp-filter.c:243:3: note: in expansion of macro ‘RULE’
   RULE (SCMP_ACT_ALLOW, SCMP_SYS (openat),
   ^~~~
seccomp-filter.c:251:9: warning: implicit declaration of function ‘SCMP_A0_32’ [-Wimplicit-function-declaration]
         SCMP_A0_32 (SCMP_CMP_EQ, STDIN_FILENO),
         ^
seccomp-filter.c:105:48: note: in definition of macro ‘RULE’
       const struct scmp_arg_cmp arg_array[] = {__VA_ARGS__};         \
                                                ^~~~~~~~~~~
seccomp-filter.c:105:20: warning: nested extern declaration of ‘SCMP_A0_32’ [-Wnested-externs]
       const struct scmp_arg_cmp arg_array[] = {__VA_ARGS__};         \
                    ^
seccomp-filter.c:250:3: note: in expansion of macro ‘RULE’
   RULE (SCMP_ACT_ALLOW, SCMP_SYS (ioctl),
   ^~~~
seccomp-filter.c:105:47: warning: missing braces around initializer [-Wmissing-braces]
       const struct scmp_arg_cmp arg_array[] = {__VA_ARGS__};         \
                                               ^
seccomp-filter.c:250:3: note: in expansion of macro ‘RULE’
   RULE (SCMP_ACT_ALLOW, SCMP_SYS (ioctl),
   ^~~~
seccomp-filter.c:105:47: note: (near initialization for ‘arg_array’)
       const struct scmp_arg_cmp arg_array[] = {__VA_ARGS__};         \
                                               ^
seccomp-filter.c:250:3: note: in expansion of macro ‘RULE’
   RULE (SCMP_ACT_ALLOW, SCMP_SYS (ioctl),
   ^~~~
seccomp-filter.c:105:47: warning: missing braces around initializer [-Wmissing-braces]
       const struct scmp_arg_cmp arg_array[] = {__VA_ARGS__};         \
                                               ^
seccomp-filter.c:255:3: note: in expansion of macro ‘RULE’
   RULE (SCMP_ACT_ALLOW, SCMP_SYS (fcntl),
   ^~~~
seccomp-filter.c:105:47: note: (near initialization for ‘arg_array’)
       const struct scmp_arg_cmp arg_array[] = {__VA_ARGS__};         \
                                               ^
seccomp-filter.c:255:3: note: in expansion of macro ‘RULE’
   RULE (SCMP_ACT_ALLOW, SCMP_SYS (fcntl),
   ^~~~
seccomp-filter.c:105:47: warning: missing braces around initializer [-Wmissing-braces]
       const struct scmp_arg_cmp arg_array[] = {__VA_ARGS__};         \
                                               ^
seccomp-filter.c:257:3: note: in expansion of macro ‘RULE’
   RULE (SCMP_ACT_ALLOW, SCMP_SYS (fcntl64),
   ^~~~
seccomp-filter.c:105:47: note: (near initialization for ‘arg_array’)
       const struct scmp_arg_cmp arg_array[] = {__VA_ARGS__};         \
                                               ^
seccomp-filter.c:257:3: note: in expansion of macro ‘RULE’
   RULE (SCMP_ACT_ALLOW, SCMP_SYS (fcntl64),
   ^~~~
seccomp-filter.c:274:9: warning: implicit declaration of function ‘SCMP_A2_64’ [-Wimplicit-function-declaration]
         SCMP_A2_64 (SCMP_CMP_EQ, 0) /* new_limit == NULL */);
         ^
seccomp-filter.c:105:48: note: in definition of macro ‘RULE’
       const struct scmp_arg_cmp arg_array[] = {__VA_ARGS__};         \
                                                ^~~~~~~~~~~
seccomp-filter.c:105:20: warning: nested extern declaration of ‘SCMP_A2_64’ [-Wnested-externs]
       const struct scmp_arg_cmp arg_array[] = {__VA_ARGS__};         \
                    ^
seccomp-filter.c:272:3: note: in expansion of macro ‘RULE’
   RULE (SCMP_ACT_ALLOW, SCMP_SYS (prlimit64),
   ^~~~
seccomp-filter.c:105:47: warning: missing braces around initializer [-Wmissing-braces]
       const struct scmp_arg_cmp arg_array[] = {__VA_ARGS__};         \
                                               ^
seccomp-filter.c:272:3: note: in expansion of macro ‘RULE’
   RULE (SCMP_ACT_ALLOW, SCMP_SYS (prlimit64),
   ^~~~
seccomp-filter.c:105:47: note: (near initialization for ‘arg_array’)
       const struct scmp_arg_cmp arg_array[] = {__VA_ARGS__};         \
                                               ^
seccomp-filter.c:272:3: note: in expansion of macro ‘RULE’
   RULE (SCMP_ACT_ALLOW, SCMP_SYS (prlimit64),
   ^~~~
seccomp-filter.c:105:47: warning: missing braces around initializer [-Wmissing-braces]
       const struct scmp_arg_cmp arg_array[] = {__VA_ARGS__};         \
                                               ^
seccomp-filter.c:277:3: note: in expansion of macro ‘RULE’
   RULE (SCMP_ACT_ERRNO (EPERM), SCMP_SYS (prlimit64),
   ^~~~
seccomp-filter.c:105:47: note: (near initialization for ‘arg_array’)
       const struct scmp_arg_cmp arg_array[] = {__VA_ARGS__};         \
                                               ^
seccomp-filter.c:277:3: note: in expansion of macro ‘RULE’
   RULE (SCMP_ACT_ERRNO (EPERM), SCMP_SYS (prlimit64),
   ^~~~
seccomp-filter.c:294:9: warning: implicit declaration of function ‘SCMP_A0_64’ [-Wimplicit-function-declaration]
         SCMP_A0_64 (SCMP_CMP_MASKED_EQ,
         ^
seccomp-filter.c:105:48: note: in definition of macro ‘RULE’
       const struct scmp_arg_cmp arg_array[] = {__VA_ARGS__};         \
                                                ^~~~~~~~~~~
seccomp-filter.c:105:20: warning: nested extern declaration of ‘SCMP_A0_64’ [-Wnested-externs]
       const struct scmp_arg_cmp arg_array[] = {__VA_ARGS__};         \
                    ^
seccomp-filter.c:293:3: note: in expansion of macro ‘RULE’
   RULE (SCMP_ACT_ALLOW, SCMP_SYS (clone),
   ^~~~
seccomp-filter.c:105:47: warning: missing braces around initializer [-Wmissing-braces]
       const struct scmp_arg_cmp arg_array[] = {__VA_ARGS__};         \
                                               ^
seccomp-filter.c:293:3: note: in expansion of macro ‘RULE’
   RULE (SCMP_ACT_ALLOW, SCMP_SYS (clone),
   ^~~~
seccomp-filter.c:105:47: note: (near initialization for ‘arg_array’)
       const struct scmp_arg_cmp arg_array[] = {__VA_ARGS__};         \
                                               ^
seccomp-filter.c:293:3: note: in expansion of macro ‘RULE’
   RULE (SCMP_ACT_ALLOW, SCMP_SYS (clone),
   ^~~~
seccomp-filter.c:105:47: warning: missing braces around initializer [-Wmissing-braces]
       const struct scmp_arg_cmp arg_array[] = {__VA_ARGS__};         \
                                               ^
seccomp-filter.c:306:3: note: in expansion of macro ‘RULE’
   RULE (SCMP_ACT_ALLOW, SCMP_SYS (prctl),
   ^~~~
seccomp-filter.c:105:47: note: (near initialization for ‘arg_array’)
       const struct scmp_arg_cmp arg_array[] = {__VA_ARGS__};         \
                                               ^
seccomp-filter.c:306:3: note: in expansion of macro ‘RULE’
   RULE (SCMP_ACT_ALLOW, SCMP_SYS (prctl),
   ^~~~
Makefile:415: recipe for target 'seccomp-filter' failed
make[1]: *** [seccomp-filter] Error 1
make[1]: Leaving directory '/home/redknight/git/emacs/lib-src'
Makefile:396: recipe for target 'lib-src' failed
make: *** [lib-src] Error 2

--------------- End error list ---------

Best wishes,



^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: Build failure: 'seccomp-filter'
  2021-04-11  7:50   ` Colin Baxter
@ 2021-04-11 10:12     ` Philipp Stephani
  2021-04-11 10:45       ` Colin Baxter
  0 siblings, 1 reply; 15+ messages in thread
From: Philipp Stephani @ 2021-04-11 10:12 UTC (permalink / raw)
  To: Colin Baxter; +Cc: Eli Zaretskii, Emacs developers

Am So., 11. Apr. 2021 um 09:51 Uhr schrieb Colin Baxter <m43cap@yandex.com>:
>
> >>>>> Eli Zaretskii <eliz@gnu.org> writes:
>
>     >> From: Colin Baxter <m43cap@yandex.com> Cc: Date: Sun, 11 Apr 2021
>     >> 07:45:19 +0100
>     >>
>     >> I get a build with the latest pull of emacs:
>     >>
>     >> Makefile:415: recipe for target 'seccomp-filter' failed make[1]:
>     >> *** [seccomp-filter] Error 1 make[1]: Leaving directory
>     >> '/home/redknight/git/emacs/lib-src' Makefile:396: recipe for
>     >> target 'lib-src' failed make: *** [lib-src] Error 2
>
>     > Are there no error or warning messages before the "Makefile:415"
>     > one?  If there are, please show all the messages.
>
> Yes, sorry, I missed the earlier errors. Here is the full list beginning
> after the attempt to compile seccomp-filter:
>
> ---------- Begin error list ------------
>
>   CCLD     seccomp-filter
> seccomp-filter.c: In function ‘main’:
> seccomp-filter.c:142:23: error: ‘SCMP_ACT_KILL_PROCESS’ undeclared (first use in this function)
>    ctx = seccomp_init (SCMP_ACT_KILL_PROCESS);
>                        ^~~~~~~~~~~~~~~~~~~~~


This is an interesting failure. Looks like seccomp.h exists on your
system, but doesn't contain the right definitions?
What does your config.log say about seccomp.h (not linux/seccomp.h)
and seccomp_init?



^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: Build failure: 'seccomp-filter'
  2021-04-11 10:12     ` Philipp Stephani
@ 2021-04-11 10:45       ` Colin Baxter
  2021-04-11 14:31         ` Philipp
  0 siblings, 1 reply; 15+ messages in thread
From: Colin Baxter @ 2021-04-11 10:45 UTC (permalink / raw)
  To: Philipp Stephani; +Cc: Eli Zaretskii, Emacs developers

>>>>> Philipp Stephani <p.stephani2@gmail.com> writes:

    > Am So., 11. Apr. 2021 um 09:51 Uhr schrieb Colin Baxter
    > <m43cap@yandex.com>:
    >> 
    >> >>>>> Eli Zaretskii <eliz@gnu.org> writes:
    >> 
    >> >> From: Colin Baxter <m43cap@yandex.com> Cc: Date: Sun, 11 Apr
    >> 2021 >> 07:45:19 +0100
    >> >>
    >> >> I get a build with the latest pull of emacs:
    >> >>
    >> >> Makefile:415: recipe for target 'seccomp-filter' failed
    >> make[1]: >> *** [seccomp-filter] Error 1 make[1]: Leaving
    >> directory >> '/home/redknight/git/emacs/lib-src' Makefile:396:
    >> recipe for >> target 'lib-src' failed make: *** [lib-src] Error 2
    >> 
    >> > Are there no error or warning messages before the
    >> "Makefile:415" > one?  If there are, please show all the
    >> messages.
    >> 
    >> Yes, sorry, I missed the earlier errors. Here is the full list
    >> beginning after the attempt to compile seccomp-filter:
    >> 
    >> ---------- Begin error list ------------
    >> 
    >> CCLD seccomp-filter seccomp-filter.c: In function ‘main’:
    >> seccomp-filter.c:142:23: error: ‘SCMP_ACT_KILL_PROCESS’
    >> undeclared (first use in this function) ctx = seccomp_init
    >> (SCMP_ACT_KILL_PROCESS); ^~~~~~~~~~~~~~~~~~~~~


    > This is an interesting failure. Looks like seccomp.h exists on
    > your system, but doesn't contain the right definitions?  What does
    > your config.log say about seccomp.h (not linux/seccomp.h) and
    > seccomp_init?

I have appended below the occurrences in config.log for seccomp.h. (Do
you want me to attach the whole config.log in a second email?) The only
other mentions are multiple lines of the form

  5090:| #define HAVE_LINUX_SECCOMP_H 1

ending with

  27758:ac_cv_header_linux_seccomp_h=yes
  27771:ac_cv_header_seccomp_h=yes
  29332:#define HAVE_LINUX_SECCOMP_H 1

Hope this helps.

---------- Begin relevant portion of config.log -----------

configure:17719: checking linux/seccomp.h usability
configure:17719: gcc -c  -g3 -O2 -pthread -isystem /usr/include/librsvg-2.0 -isystem /usr/include/gdk-pixbuf-2.0 -isystem /usr/include/libpng16 -isystem /usr/include/cairo -isystem /usr/include/glib-2.0 -isystem /usr/lib/i386-linux-gnu/glib-2.0/include -isystem /usr/include/pixman-1 -isystem /usr/include/freetype2 -isystem /usr/include/libpng16 -isystem /usr/include/cairo -isystem /usr/include/glib-2.0 -isystem /usr/lib/i386-linux-gnu/glib-2.0/include -isystem /usr/include/pixman-1 -isystem /usr/include/freetype2 -isystem /usr/include/libpng16     conftest.c >&5
configure:17719: $? = 0
configure:17719: result: yes
configure:17719: checking linux/seccomp.h presence
configure:17719: gcc -E     conftest.c
configure:17719: $? = 0
configure:17719: result: yes
configure:17719: checking for linux/seccomp.h
configure:17719: result: yes
configure:17731: checking seccomp.h usability
configure:17731: gcc -c  -g3 -O2 -pthread -isystem /usr/include/librsvg-2.0 -isystem /usr/include/gdk-pixbuf-2.0 -isystem /usr/include/libpng16 -isystem /usr/include/cairo -isystem /usr/include/glib-2.0 -isystem /usr/lib/i386-linux-gnu/glib-2.0/include -isystem /usr/include/pixman-1 -isystem /usr/include/freetype2 -isystem /usr/include/libpng16 -isystem /usr/include/cairo -isystem /usr/include/glib-2.0 -isystem /usr/lib/i386-linux-gnu/glib-2.0/include -isystem /usr/include/pixman-1 -isystem /usr/include/freetype2 -isystem /usr/include/libpng16     conftest.c >&5
configure:17731: $? = 0
configure:17731: result: yes
configure:17731: checking seccomp.h presence
configure:17731: gcc -E     conftest.c
configure:17731: $? = 0
configure:17731: result: yes
configure:17731: checking for seccomp.h
configure:17731: result: yes
configure:17733: checking for seccomp_init in -lseccomp
configure:17758: gcc -o conftest  -g3 -O2 -pthread -isystem /usr/include/librsvg-2.0 -isystem /usr/include/gdk-pixbuf-2.0 -isystem /usr/include/libpng16 -isystem /usr/include/cairo -isystem /usr/include/glib-2.0 -isystem /usr/lib/i386-linux-gnu/glib-2.0/include -isystem /usr/include/pixman-1 -isystem /usr/include/freetype2 -isystem /usr/include/libpng16 -isystem /usr/include/cairo -isystem /usr/include/glib-2.0 -isystem /usr/lib/i386-linux-gnu/glib-2.0/include -isystem /usr/include/pixman-1 -isystem /usr/include/freetype2 -isystem /usr/include/libpng16       conftest.c -lseccomp  -lX11   -lcairo >&5 
configure:17758: $? = 0
configure:17767: result: yes

---------- End relevant portion of config.log ----

Best wishes,



^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: Build failure: 'seccomp-filter'
  2021-04-11 10:45       ` Colin Baxter
@ 2021-04-11 14:31         ` Philipp
  2021-04-11 14:40           ` Philipp Stephani
  2021-04-11 15:18           ` Colin Baxter
  0 siblings, 2 replies; 15+ messages in thread
From: Philipp @ 2021-04-11 14:31 UTC (permalink / raw)
  To: Colin Baxter; +Cc: Eli Zaretskii, Emacs developers



> Am 11.04.2021 um 12:45 schrieb Colin Baxter <m43cap@yandex.com>:
> 
>>>>>> Philipp Stephani <p.stephani2@gmail.com> writes:
> 
>> Am So., 11. Apr. 2021 um 09:51 Uhr schrieb Colin Baxter
>> <m43cap@yandex.com>:
>>> 
>>>>>>>> Eli Zaretskii <eliz@gnu.org> writes:
>>> 
>>>>> From: Colin Baxter <m43cap@yandex.com> Cc: Date: Sun, 11 Apr
>>> 2021 >> 07:45:19 +0100
>>>>> 
>>>>> I get a build with the latest pull of emacs:
>>>>> 
>>>>> Makefile:415: recipe for target 'seccomp-filter' failed
>>> make[1]: >> *** [seccomp-filter] Error 1 make[1]: Leaving
>>> directory >> '/home/redknight/git/emacs/lib-src' Makefile:396:
>>> recipe for >> target 'lib-src' failed make: *** [lib-src] Error 2
>>> 
>>>> Are there no error or warning messages before the
>>> "Makefile:415" > one?  If there are, please show all the
>>> messages.
>>> 
>>> Yes, sorry, I missed the earlier errors. Here is the full list
>>> beginning after the attempt to compile seccomp-filter:
>>> 
>>> ---------- Begin error list ------------
>>> 
>>> CCLD seccomp-filter seccomp-filter.c: In function ‘main’:
>>> seccomp-filter.c:142:23: error: ‘SCMP_ACT_KILL_PROCESS’
>>> undeclared (first use in this function) ctx = seccomp_init
>>> (SCMP_ACT_KILL_PROCESS); ^~~~~~~~~~~~~~~~~~~~~
> 
> 
>> This is an interesting failure. Looks like seccomp.h exists on
>> your system, but doesn't contain the right definitions?  What does
>> your config.log say about seccomp.h (not linux/seccomp.h) and
>> seccomp_init?
> 
> I have appended below the occurrences in config.log for seccomp.h. (Do
> you want me to attach the whole config.log in a second email?) The only
> other mentions are multiple lines of the form
> 
>  5090:| #define HAVE_LINUX_SECCOMP_H 1
> 
> ending with
> 
>  27758:ac_cv_header_linux_seccomp_h=yes
>  27771:ac_cv_header_seccomp_h=yes
>  29332:#define HAVE_LINUX_SECCOMP_H 1
> 
> Hope this helps.
> 
> ---------- Begin relevant portion of config.log -----------
> 
> configure:17719: checking linux/seccomp.h usability
> configure:17719: gcc -c  -g3 -O2 -pthread -isystem /usr/include/librsvg-2.0 -isystem /usr/include/gdk-pixbuf-2.0 -isystem /usr/include/libpng16 -isystem /usr/include/cairo -isystem /usr/include/glib-2.0 -isystem /usr/lib/i386-linux-gnu/glib-2.0/include -isystem /usr/include/pixman-1 -isystem /usr/include/freetype2 -isystem /usr/include/libpng16 -isystem /usr/include/cairo -isystem /usr/include/glib-2.0 -isystem /usr/lib/i386-linux-gnu/glib-2.0/include -isystem /usr/include/pixman-1 -isystem /usr/include/freetype2 -isystem /usr/include/libpng16     conftest.c >&5
> configure:17719: $? = 0
> configure:17719: result: yes
> configure:17719: checking linux/seccomp.h presence
> configure:17719: gcc -E     conftest.c
> configure:17719: $? = 0
> configure:17719: result: yes
> configure:17719: checking for linux/seccomp.h
> configure:17719: result: yes
> configure:17731: checking seccomp.h usability
> configure:17731: gcc -c  -g3 -O2 -pthread -isystem /usr/include/librsvg-2.0 -isystem /usr/include/gdk-pixbuf-2.0 -isystem /usr/include/libpng16 -isystem /usr/include/cairo -isystem /usr/include/glib-2.0 -isystem /usr/lib/i386-linux-gnu/glib-2.0/include -isystem /usr/include/pixman-1 -isystem /usr/include/freetype2 -isystem /usr/include/libpng16 -isystem /usr/include/cairo -isystem /usr/include/glib-2.0 -isystem /usr/lib/i386-linux-gnu/glib-2.0/include -isystem /usr/include/pixman-1 -isystem /usr/include/freetype2 -isystem /usr/include/libpng16     conftest.c >&5
> configure:17731: $? = 0
> configure:17731: result: yes
> configure:17731: checking seccomp.h presence
> configure:17731: gcc -E     conftest.c
> configure:17731: $? = 0
> configure:17731: result: yes
> configure:17731: checking for seccomp.h
> configure:17731: result: yes
> configure:17733: checking for seccomp_init in -lseccomp
> configure:17758: gcc -o conftest  -g3 -O2 -pthread -isystem /usr/include/librsvg-2.0 -isystem /usr/include/gdk-pixbuf-2.0 -isystem /usr/include/libpng16 -isystem /usr/include/cairo -isystem /usr/include/glib-2.0 -isystem /usr/lib/i386-linux-gnu/glib-2.0/include -isystem /usr/include/pixman-1 -isystem /usr/include/freetype2 -isystem /usr/include/libpng16 -isystem /usr/include/cairo -isystem /usr/include/glib-2.0 -isystem /usr/lib/i386-linux-gnu/glib-2.0/include -isystem /usr/include/pixman-1 -isystem /usr/include/freetype2 -isystem /usr/include/libpng16       conftest.c -lseccomp  -lX11   -lcairo >&5 
> configure:17758: $? = 0
> configure:17767: result: yes
> 
> ---------- End relevant portion of config.log ----
> 
> 


OK, looks like libseccomp is available and should be working.  Does /usr/include/seccomp.h contain at least some of the symbols the compiler complains about?




^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: Build failure: 'seccomp-filter'
  2021-04-11 14:31         ` Philipp
@ 2021-04-11 14:40           ` Philipp Stephani
  2021-04-11 14:52             ` Philipp Stephani
  2021-04-11 15:18           ` Colin Baxter
  1 sibling, 1 reply; 15+ messages in thread
From: Philipp Stephani @ 2021-04-11 14:40 UTC (permalink / raw)
  To: Colin Baxter; +Cc: Eli Zaretskii, Emacs developers

Am So., 11. Apr. 2021 um 16:31 Uhr schrieb Philipp <p.stephani2@gmail.com>:
>
>
>
> > Am 11.04.2021 um 12:45 schrieb Colin Baxter <m43cap@yandex.com>:
> >
> >>>>>> Philipp Stephani <p.stephani2@gmail.com> writes:
> >
> >> Am So., 11. Apr. 2021 um 09:51 Uhr schrieb Colin Baxter
> >> <m43cap@yandex.com>:
> >>>
> >>>>>>>> Eli Zaretskii <eliz@gnu.org> writes:
> >>>
> >>>>> From: Colin Baxter <m43cap@yandex.com> Cc: Date: Sun, 11 Apr
> >>> 2021 >> 07:45:19 +0100
> >>>>>
> >>>>> I get a build with the latest pull of emacs:
> >>>>>
> >>>>> Makefile:415: recipe for target 'seccomp-filter' failed
> >>> make[1]: >> *** [seccomp-filter] Error 1 make[1]: Leaving
> >>> directory >> '/home/redknight/git/emacs/lib-src' Makefile:396:
> >>> recipe for >> target 'lib-src' failed make: *** [lib-src] Error 2
> >>>
> >>>> Are there no error or warning messages before the
> >>> "Makefile:415" > one?  If there are, please show all the
> >>> messages.
> >>>
> >>> Yes, sorry, I missed the earlier errors. Here is the full list
> >>> beginning after the attempt to compile seccomp-filter:
> >>>
> >>> ---------- Begin error list ------------
> >>>
> >>> CCLD seccomp-filter seccomp-filter.c: In function ‘main’:
> >>> seccomp-filter.c:142:23: error: ‘SCMP_ACT_KILL_PROCESS’
> >>> undeclared (first use in this function) ctx = seccomp_init
> >>> (SCMP_ACT_KILL_PROCESS); ^~~~~~~~~~~~~~~~~~~~~
> >
> >
> >> This is an interesting failure. Looks like seccomp.h exists on
> >> your system, but doesn't contain the right definitions?  What does
> >> your config.log say about seccomp.h (not linux/seccomp.h) and
> >> seccomp_init?
> >
> > I have appended below the occurrences in config.log for seccomp.h. (Do
> > you want me to attach the whole config.log in a second email?) The only
> > other mentions are multiple lines of the form
> >
> >  5090:| #define HAVE_LINUX_SECCOMP_H 1
> >
> > ending with
> >
> >  27758:ac_cv_header_linux_seccomp_h=yes
> >  27771:ac_cv_header_seccomp_h=yes
> >  29332:#define HAVE_LINUX_SECCOMP_H 1
> >
> > Hope this helps.
> >
> > ---------- Begin relevant portion of config.log -----------
> >
> > configure:17719: checking linux/seccomp.h usability
> > configure:17719: gcc -c  -g3 -O2 -pthread -isystem /usr/include/librsvg-2.0 -isystem /usr/include/gdk-pixbuf-2.0 -isystem /usr/include/libpng16 -isystem /usr/include/cairo -isystem /usr/include/glib-2.0 -isystem /usr/lib/i386-linux-gnu/glib-2.0/include -isystem /usr/include/pixman-1 -isystem /usr/include/freetype2 -isystem /usr/include/libpng16 -isystem /usr/include/cairo -isystem /usr/include/glib-2.0 -isystem /usr/lib/i386-linux-gnu/glib-2.0/include -isystem /usr/include/pixman-1 -isystem /usr/include/freetype2 -isystem /usr/include/libpng16     conftest.c >&5
> > configure:17719: $? = 0
> > configure:17719: result: yes
> > configure:17719: checking linux/seccomp.h presence
> > configure:17719: gcc -E     conftest.c
> > configure:17719: $? = 0
> > configure:17719: result: yes
> > configure:17719: checking for linux/seccomp.h
> > configure:17719: result: yes
> > configure:17731: checking seccomp.h usability
> > configure:17731: gcc -c  -g3 -O2 -pthread -isystem /usr/include/librsvg-2.0 -isystem /usr/include/gdk-pixbuf-2.0 -isystem /usr/include/libpng16 -isystem /usr/include/cairo -isystem /usr/include/glib-2.0 -isystem /usr/lib/i386-linux-gnu/glib-2.0/include -isystem /usr/include/pixman-1 -isystem /usr/include/freetype2 -isystem /usr/include/libpng16 -isystem /usr/include/cairo -isystem /usr/include/glib-2.0 -isystem /usr/lib/i386-linux-gnu/glib-2.0/include -isystem /usr/include/pixman-1 -isystem /usr/include/freetype2 -isystem /usr/include/libpng16     conftest.c >&5
> > configure:17731: $? = 0
> > configure:17731: result: yes
> > configure:17731: checking seccomp.h presence
> > configure:17731: gcc -E     conftest.c
> > configure:17731: $? = 0
> > configure:17731: result: yes
> > configure:17731: checking for seccomp.h
> > configure:17731: result: yes
> > configure:17733: checking for seccomp_init in -lseccomp
> > configure:17758: gcc -o conftest  -g3 -O2 -pthread -isystem /usr/include/librsvg-2.0 -isystem /usr/include/gdk-pixbuf-2.0 -isystem /usr/include/libpng16 -isystem /usr/include/cairo -isystem /usr/include/glib-2.0 -isystem /usr/lib/i386-linux-gnu/glib-2.0/include -isystem /usr/include/pixman-1 -isystem /usr/include/freetype2 -isystem /usr/include/libpng16 -isystem /usr/include/cairo -isystem /usr/include/glib-2.0 -isystem /usr/lib/i386-linux-gnu/glib-2.0/include -isystem /usr/include/pixman-1 -isystem /usr/include/freetype2 -isystem /usr/include/libpng16       conftest.c -lseccomp  -lX11   -lcairo >&5
> > configure:17758: $? = 0
> > configure:17767: result: yes
> >
> > ---------- End relevant portion of config.log ----
> >
> >
>
>
> OK, looks like libseccomp is available and should be working.  Does /usr/include/seccomp.h contain at least some of the symbols the compiler complains about?
>

Looking at https://github.com/seccomp/libseccomp/blob/main/CHANGELOG,
I guess we need at least version 2.4.0 of libseccomp. I'll see that I
can add a few more checks to configure.ac.



^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: Build failure: 'seccomp-filter'
  2021-04-11 14:40           ` Philipp Stephani
@ 2021-04-11 14:52             ` Philipp Stephani
  2021-04-11 15:40               ` Colin Baxter
  2021-04-11 15:55               ` Andreas Schwab
  0 siblings, 2 replies; 15+ messages in thread
From: Philipp Stephani @ 2021-04-11 14:52 UTC (permalink / raw)
  To: Colin Baxter; +Cc: Eli Zaretskii, Emacs developers

Am So., 11. Apr. 2021 um 16:40 Uhr schrieb Philipp Stephani
<p.stephani2@gmail.com>:
>
> Am So., 11. Apr. 2021 um 16:31 Uhr schrieb Philipp <p.stephani2@gmail.com>:
> >
> >
> >
> > > Am 11.04.2021 um 12:45 schrieb Colin Baxter <m43cap@yandex.com>:
> > >
> > >>>>>> Philipp Stephani <p.stephani2@gmail.com> writes:
> > >
> > >> Am So., 11. Apr. 2021 um 09:51 Uhr schrieb Colin Baxter
> > >> <m43cap@yandex.com>:
> > >>>
> > >>>>>>>> Eli Zaretskii <eliz@gnu.org> writes:
> > >>>
> > >>>>> From: Colin Baxter <m43cap@yandex.com> Cc: Date: Sun, 11 Apr
> > >>> 2021 >> 07:45:19 +0100
> > >>>>>
> > >>>>> I get a build with the latest pull of emacs:
> > >>>>>
> > >>>>> Makefile:415: recipe for target 'seccomp-filter' failed
> > >>> make[1]: >> *** [seccomp-filter] Error 1 make[1]: Leaving
> > >>> directory >> '/home/redknight/git/emacs/lib-src' Makefile:396:
> > >>> recipe for >> target 'lib-src' failed make: *** [lib-src] Error 2
> > >>>
> > >>>> Are there no error or warning messages before the
> > >>> "Makefile:415" > one?  If there are, please show all the
> > >>> messages.
> > >>>
> > >>> Yes, sorry, I missed the earlier errors. Here is the full list
> > >>> beginning after the attempt to compile seccomp-filter:
> > >>>
> > >>> ---------- Begin error list ------------
> > >>>
> > >>> CCLD seccomp-filter seccomp-filter.c: In function ‘main’:
> > >>> seccomp-filter.c:142:23: error: ‘SCMP_ACT_KILL_PROCESS’
> > >>> undeclared (first use in this function) ctx = seccomp_init
> > >>> (SCMP_ACT_KILL_PROCESS); ^~~~~~~~~~~~~~~~~~~~~
> > >
> > >
> > >> This is an interesting failure. Looks like seccomp.h exists on
> > >> your system, but doesn't contain the right definitions?  What does
> > >> your config.log say about seccomp.h (not linux/seccomp.h) and
> > >> seccomp_init?
> > >
> > > I have appended below the occurrences in config.log for seccomp.h. (Do
> > > you want me to attach the whole config.log in a second email?) The only
> > > other mentions are multiple lines of the form
> > >
> > >  5090:| #define HAVE_LINUX_SECCOMP_H 1
> > >
> > > ending with
> > >
> > >  27758:ac_cv_header_linux_seccomp_h=yes
> > >  27771:ac_cv_header_seccomp_h=yes
> > >  29332:#define HAVE_LINUX_SECCOMP_H 1
> > >
> > > Hope this helps.
> > >
> > > ---------- Begin relevant portion of config.log -----------
> > >
> > > configure:17719: checking linux/seccomp.h usability
> > > configure:17719: gcc -c  -g3 -O2 -pthread -isystem /usr/include/librsvg-2.0 -isystem /usr/include/gdk-pixbuf-2.0 -isystem /usr/include/libpng16 -isystem /usr/include/cairo -isystem /usr/include/glib-2.0 -isystem /usr/lib/i386-linux-gnu/glib-2.0/include -isystem /usr/include/pixman-1 -isystem /usr/include/freetype2 -isystem /usr/include/libpng16 -isystem /usr/include/cairo -isystem /usr/include/glib-2.0 -isystem /usr/lib/i386-linux-gnu/glib-2.0/include -isystem /usr/include/pixman-1 -isystem /usr/include/freetype2 -isystem /usr/include/libpng16     conftest.c >&5
> > > configure:17719: $? = 0
> > > configure:17719: result: yes
> > > configure:17719: checking linux/seccomp.h presence
> > > configure:17719: gcc -E     conftest.c
> > > configure:17719: $? = 0
> > > configure:17719: result: yes
> > > configure:17719: checking for linux/seccomp.h
> > > configure:17719: result: yes
> > > configure:17731: checking seccomp.h usability
> > > configure:17731: gcc -c  -g3 -O2 -pthread -isystem /usr/include/librsvg-2.0 -isystem /usr/include/gdk-pixbuf-2.0 -isystem /usr/include/libpng16 -isystem /usr/include/cairo -isystem /usr/include/glib-2.0 -isystem /usr/lib/i386-linux-gnu/glib-2.0/include -isystem /usr/include/pixman-1 -isystem /usr/include/freetype2 -isystem /usr/include/libpng16 -isystem /usr/include/cairo -isystem /usr/include/glib-2.0 -isystem /usr/lib/i386-linux-gnu/glib-2.0/include -isystem /usr/include/pixman-1 -isystem /usr/include/freetype2 -isystem /usr/include/libpng16     conftest.c >&5
> > > configure:17731: $? = 0
> > > configure:17731: result: yes
> > > configure:17731: checking seccomp.h presence
> > > configure:17731: gcc -E     conftest.c
> > > configure:17731: $? = 0
> > > configure:17731: result: yes
> > > configure:17731: checking for seccomp.h
> > > configure:17731: result: yes
> > > configure:17733: checking for seccomp_init in -lseccomp
> > > configure:17758: gcc -o conftest  -g3 -O2 -pthread -isystem /usr/include/librsvg-2.0 -isystem /usr/include/gdk-pixbuf-2.0 -isystem /usr/include/libpng16 -isystem /usr/include/cairo -isystem /usr/include/glib-2.0 -isystem /usr/lib/i386-linux-gnu/glib-2.0/include -isystem /usr/include/pixman-1 -isystem /usr/include/freetype2 -isystem /usr/include/libpng16 -isystem /usr/include/cairo -isystem /usr/include/glib-2.0 -isystem /usr/lib/i386-linux-gnu/glib-2.0/include -isystem /usr/include/pixman-1 -isystem /usr/include/freetype2 -isystem /usr/include/libpng16       conftest.c -lseccomp  -lX11   -lcairo >&5
> > > configure:17758: $? = 0
> > > configure:17767: result: yes
> > >
> > > ---------- End relevant portion of config.log ----
> > >
> > >
> >
> >
> > OK, looks like libseccomp is available and should be working.  Does /usr/include/seccomp.h contain at least some of the symbols the compiler complains about?
> >
>
> Looking at https://github.com/seccomp/libseccomp/blob/main/CHANGELOG,
> I guess we need at least version 2.4.0 of libseccomp. I'll see that I
> can add a few more checks to configure.ac.

With commit 725fc96b706c57ef8ceca5e7d82b175d9a72e845, I've now
switched to using pkg-config, which seems cleaner anyway.



^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: Build failure: 'seccomp-filter'
  2021-04-11 14:31         ` Philipp
  2021-04-11 14:40           ` Philipp Stephani
@ 2021-04-11 15:18           ` Colin Baxter
  1 sibling, 0 replies; 15+ messages in thread
From: Colin Baxter @ 2021-04-11 15:18 UTC (permalink / raw)
  To: Philipp; +Cc: Eli Zaretskii, Emacs developers

>>>>> Philipp  <p.stephani2@gmail.com> writes:

    >> Am 11.04.2021 um 12:45 schrieb Colin Baxter <m43cap@yandex.com>:
    >> 
    >>>>>>> Philipp Stephani <p.stephani2@gmail.com> writes:
    >> 
    >>> Am So., 11. Apr. 2021 um 09:51 Uhr schrieb Colin Baxter
    >>> <m43cap@yandex.com>:
    >>>> 
    >>>>>>>>> Eli Zaretskii <eliz@gnu.org> writes:
    >>>> 
>>>>> From: Colin Baxter <m43cap@yandex.com> Cc: Date: Sun, 11 Apr 2021
    >>>> >> 07:45:19 +0100
>>>>> 
>>>>> I get a build with the latest pull of emacs:
>>>>> 
>>>>> Makefile:415: recipe for target 'seccomp-filter' failed make[1]:
    >>>> >> *** [seccomp-filter] Error 1 make[1]: Leaving directory >>
    >>>> '/home/redknight/git/emacs/lib-src' Makefile:396: recipe for >>
    >>>> target 'lib-src' failed make: *** [lib-src] Error 2
    >>>> 
    >>>>> Are there no error or warning messages before the
    >>>> "Makefile:415" > one?  If there are, please show all the
    >>>> messages.
    >>>> 
    >>>> Yes, sorry, I missed the earlier errors. Here is the full list
    >>>> beginning after the attempt to compile seccomp-filter:
    >>>> 
    >>>> ---------- Begin error list ------------
    >>>> 
    >>>> CCLD seccomp-filter seccomp-filter.c: In function ‘main’:
    >>>> seccomp-filter.c:142:23: error: ‘SCMP_ACT_KILL_PROCESS’
    >>>> undeclared (first use in this function) ctx = seccomp_init
    >>>> (SCMP_ACT_KILL_PROCESS); ^~~~~~~~~~~~~~~~~~~~~
    >> 
    >> 
    >>> This is an interesting failure. Looks like seccomp.h exists on
    >>> your system, but doesn't contain the right definitions?  What
    >>> does your config.log say about seccomp.h (not linux/seccomp.h)
    >>> and seccomp_init?
    >> 
    >> I have appended below the occurrences in config.log for
    >> seccomp.h. (Do you want me to attach the whole config.log in a
    >> second email?) The only other mentions are multiple lines of the
    >> form
    >> 
    >> 5090:| #define HAVE_LINUX_SECCOMP_H 1
    >> 
    >> ending with
    >> 
    >> 27758:ac_cv_header_linux_seccomp_h=yes
    >> 27771:ac_cv_header_seccomp_h=yes 29332:#define
    >> HAVE_LINUX_SECCOMP_H 1
    >> 
    >> Hope this helps.
    >> 
    >> ---------- Begin relevant portion of config.log -----------
    >> 
    >> configure:17719: checking linux/seccomp.h usability
    >> configure:17719: gcc -c -g3 -O2 -pthread -isystem
    >> /usr/include/librsvg-2.0 -isystem /usr/include/gdk-pixbuf-2.0
    >> -isystem /usr/include/libpng16 -isystem /usr/include/cairo
    >> -isystem /usr/include/glib-2.0 -isystem
    >> /usr/lib/i386-linux-gnu/glib-2.0/include -isystem
    >> /usr/include/pixman-1 -isystem /usr/include/freetype2 -isystem
    >> /usr/include/libpng16 -isystem /usr/include/cairo -isystem
    >> /usr/include/glib-2.0 -isystem
    >> /usr/lib/i386-linux-gnu/glib-2.0/include -isystem
    >> /usr/include/pixman-1 -isystem /usr/include/freetype2 -isystem
    >> /usr/include/libpng16 conftest.c >&5 configure:17719: $? = 0
    >> configure:17719: result: yes configure:17719: checking
    >> linux/seccomp.h presence configure:17719: gcc -E conftest.c
    >> configure:17719: $? = 0 configure:17719: result: yes
    >> configure:17719: checking for linux/seccomp.h configure:17719:
    >> result: yes configure:17731: checking seccomp.h usability
    >> configure:17731: gcc -c -g3 -O2 -pthread -isystem
    >> /usr/include/librsvg-2.0 -isystem /usr/include/gdk-pixbuf-2.0
    >> -isystem /usr/include/libpng16 -isystem /usr/include/cairo
    >> -isystem /usr/include/glib-2.0 -isystem
    >> /usr/lib/i386-linux-gnu/glib-2.0/include -isystem
    >> /usr/include/pixman-1 -isystem /usr/include/freetype2 -isystem
    >> /usr/include/libpng16 -isystem /usr/include/cairo -isystem
    >> /usr/include/glib-2.0 -isystem
    >> /usr/lib/i386-linux-gnu/glib-2.0/include -isystem
    >> /usr/include/pixman-1 -isystem /usr/include/freetype2 -isystem
    >> /usr/include/libpng16 conftest.c >&5 configure:17731: $? = 0
    >> configure:17731: result: yes configure:17731: checking seccomp.h
    >> presence configure:17731: gcc -E conftest.c configure:17731: $? =
    >> 0 configure:17731: result: yes configure:17731: checking for
    >> seccomp.h configure:17731: result: yes configure:17733: checking
    >> for seccomp_init in -lseccomp configure:17758: gcc -o conftest
    >> -g3 -O2 -pthread -isystem /usr/include/librsvg-2.0 -isystem
    >> /usr/include/gdk-pixbuf-2.0 -isystem /usr/include/libpng16
    >> -isystem /usr/include/cairo -isystem /usr/include/glib-2.0
    >> -isystem /usr/lib/i386-linux-gnu/glib-2.0/include -isystem
    >> /usr/include/pixman-1 -isystem /usr/include/freetype2 -isystem
    >> /usr/include/libpng16 -isystem /usr/include/cairo -isystem
    >> /usr/include/glib-2.0 -isystem
    >> /usr/lib/i386-linux-gnu/glib-2.0/include -isystem
    >> /usr/include/pixman-1 -isystem /usr/include/freetype2 -isystem
    >> /usr/include/libpng16 conftest.c -lseccomp -lX11 -lcairo >&5
    >> configure:17758: $? = 0 configure:17767: result: yes
    >> 
    >> ---------- End relevant portion of config.log ----
    >> 
    >> 


    > OK, looks like libseccomp is available and should be working.
    > Does /usr/include/seccomp.h contain at least some of the symbols
    > the compiler complains about?

Well my /usr/include/seccomp.h does contain SCMP_ACT_KILL,
SCMP_CMP_MASKED_EQ, SCMP_ACT_ALLOW, but I don't understand the contents
of the file.

Best wishes, Colin.



^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: Build failure: 'seccomp-filter'
  2021-04-11 14:52             ` Philipp Stephani
@ 2021-04-11 15:40               ` Colin Baxter
  2021-04-11 15:55               ` Andreas Schwab
  1 sibling, 0 replies; 15+ messages in thread
From: Colin Baxter @ 2021-04-11 15:40 UTC (permalink / raw)
  To: Philipp Stephani; +Cc: Eli Zaretskii, Emacs developers

>>>>> Philipp Stephani <p.stephani2@gmail.com> writes:

    > Am So., 11. Apr. 2021 um 16:40 Uhr schrieb Philipp Stephani
    > <p.stephani2@gmail.com>:
    >> 
    >> Am So., 11. Apr. 2021 um 16:31 Uhr schrieb Philipp
    >> <p.stephani2@gmail.com>:
    >> >
    >> >
    >> >
    >> > > Am 11.04.2021 um 12:45 schrieb Colin Baxter
    >> <m43cap@yandex.com>:
    >> > >
    >> > >>>>>> Philipp Stephani <p.stephani2@gmail.com> writes:
    >> > >
    >> > >> Am So., 11. Apr. 2021 um 09:51 Uhr schrieb Colin Baxter > >>
    >> <m43cap@yandex.com>:
    >> > >>>
    >> > >>>>>>>> Eli Zaretskii <eliz@gnu.org> writes:
    >> > >>>
    >> > >>>>> From: Colin Baxter <m43cap@yandex.com> Cc: Date: Sun, 11
    >> Apr > >>> 2021 >> 07:45:19 +0100
    >> > >>>>>
    >> > >>>>> I get a build with the latest pull of emacs:
    >> > >>>>>
    >> > >>>>> Makefile:415: recipe for target 'seccomp-filter' failed >
    >> >>> make[1]: >> *** [seccomp-filter] Error 1 make[1]: Leaving >
    >> >>> directory >> '/home/redknight/git/emacs/lib-src'
    >> Makefile:396: > >>> recipe for >> target 'lib-src' failed make:
    >> *** [lib-src] Error 2
    >> > >>>
    >> > >>>> Are there no error or warning messages before the > >>>
    >> "Makefile:415" > one?  If there are, please show all the > >>>
    >> messages.
    >> > >>>
    >> > >>> Yes, sorry, I missed the earlier errors. Here is the full
    >> list > >>> beginning after the attempt to compile seccomp-filter:
    >> > >>>
    >> > >>> ---------- Begin error list ------------
    >> > >>>
    >> > >>> CCLD seccomp-filter seccomp-filter.c: In function ‘main’: >
    >> >>> seccomp-filter.c:142:23: error: ‘SCMP_ACT_KILL_PROCESS’ > >>>
    >> undeclared (first use in this function) ctx = seccomp_init > >>>
    >> (SCMP_ACT_KILL_PROCESS); ^~~~~~~~~~~~~~~~~~~~~
    >> > >
    >> > >
    >> > >> This is an interesting failure. Looks like seccomp.h exists
    >> on > >> your system, but doesn't contain the right definitions?
    >> What does > >> your config.log say about seccomp.h (not
    >> linux/seccomp.h) and > >> seccomp_init?
    >> > >
    >> > > I have appended below the occurrences in config.log for
    >> seccomp.h. (Do > > you want me to attach the whole config.log in
    >> a second email?) The only > > other mentions are multiple lines
    >> of the form
    >> > >
    >> > > 5090:| #define HAVE_LINUX_SECCOMP_H 1
    >> > >
    >> > > ending with
    >> > >
    >> > > 27758:ac_cv_header_linux_seccomp_h=yes > >
    >> 27771:ac_cv_header_seccomp_h=yes > > 29332:#define
    >> HAVE_LINUX_SECCOMP_H 1
    >> > >
    >> > > Hope this helps.
    >> > >
    >> > > ---------- Begin relevant portion of config.log -----------
    >> > >
    >> > > configure:17719: checking linux/seccomp.h usability > >
    >> configure:17719: gcc -c -g3 -O2 -pthread -isystem > >
    >> /usr/include/librsvg-2.0 -isystem /usr/include/gdk-pixbuf-2.0 > >
    >> -isystem /usr/include/libpng16 -isystem /usr/include/cairo > >
    >> -isystem /usr/include/glib-2.0 -isystem > >
    >> /usr/lib/i386-linux-gnu/glib-2.0/include -isystem > >
    >> /usr/include/pixman-1 -isystem /usr/include/freetype2 -isystem >
    >> > /usr/include/libpng16 -isystem /usr/include/cairo -isystem > >
    >> /usr/include/glib-2.0 -isystem > >
    >> /usr/lib/i386-linux-gnu/glib-2.0/include -isystem > >
    >> /usr/include/pixman-1 -isystem /usr/include/freetype2 -isystem >
    >> > /usr/include/libpng16 conftest.c >&5 > > configure:17719: $? =
    >> 0 > > configure:17719: result: yes > > configure:17719: checking
    >> linux/seccomp.h presence > > configure:17719: gcc -E conftest.c >
    >> > configure:17719: $? = 0 > > configure:17719: result: yes > >
    >> configure:17719: checking for linux/seccomp.h > >
    >> configure:17719: result: yes > > configure:17731: checking
    >> seccomp.h usability > > configure:17731: gcc -c -g3 -O2 -pthread
    >> -isystem > > /usr/include/librsvg-2.0 -isystem
    >> /usr/include/gdk-pixbuf-2.0 > > -isystem /usr/include/libpng16
    >> -isystem /usr/include/cairo > > -isystem /usr/include/glib-2.0
    >> -isystem > > /usr/lib/i386-linux-gnu/glib-2.0/include -isystem >
    >> > /usr/include/pixman-1 -isystem /usr/include/freetype2 -isystem
    >> > > /usr/include/libpng16 -isystem /usr/include/cairo -isystem >
    >> > /usr/include/glib-2.0 -isystem > >
    >> /usr/lib/i386-linux-gnu/glib-2.0/include -isystem > >
    >> /usr/include/pixman-1 -isystem /usr/include/freetype2 -isystem >
    >> > /usr/include/libpng16 conftest.c >&5 > > configure:17731: $? =
    >> 0 > > configure:17731: result: yes > > configure:17731: checking
    >> seccomp.h presence > > configure:17731: gcc -E conftest.c > >
    >> configure:17731: $? = 0 > > configure:17731: result: yes > >
    >> configure:17731: checking for seccomp.h > > configure:17731:
    >> result: yes > > configure:17733: checking for seccomp_init in
    >> -lseccomp > > configure:17758: gcc -o conftest -g3 -O2 -pthread
    >> -isystem > > /usr/include/librsvg-2.0 -isystem
    >> /usr/include/gdk-pixbuf-2.0 > > -isystem /usr/include/libpng16
    >> -isystem /usr/include/cairo > > -isystem /usr/include/glib-2.0
    >> -isystem > > /usr/lib/i386-linux-gnu/glib-2.0/include -isystem >
    >> > /usr/include/pixman-1 -isystem /usr/include/freetype2 -isystem
    >> > > /usr/include/libpng16 -isystem /usr/include/cairo -isystem >
    >> > /usr/include/glib-2.0 -isystem > >
    >> /usr/lib/i386-linux-gnu/glib-2.0/include -isystem > >
    >> /usr/include/pixman-1 -isystem /usr/include/freetype2 -isystem >
    >> > /usr/include/libpng16 conftest.c -lseccomp -lX11 -lcairo >&5 >
    >> > configure:17758: $? = 0 > > configure:17767: result: yes
    >> > >
    >> > > ---------- End relevant portion of config.log ----
    >> > >
    >> > >
    >> >
    >> >
    >> > OK, looks like libseccomp is available and should be working.
    >> > Does /usr/include/seccomp.h contain at least some of the
    >> symbols > the compiler complains about?
    >> >
    >> 
    >> Looking at
    >> https://github.com/seccomp/libseccomp/blob/main/CHANGELOG, I
    >> guess we need at least version 2.4.0 of libseccomp. I'll see that
    >> I can add a few more checks to configure.ac.

    > With commit 725fc96b706c57ef8ceca5e7d82b175d9a72e845, I've now
    > switched to using pkg-config, which seems cleaner anyway.

This seems to be successful. With commit 725fc96b70, I can now build
emacs-28.0.50.

Thanks you.

Best wishes,

Colin Baxter.



^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: Build failure: 'seccomp-filter'
  2021-04-11 14:52             ` Philipp Stephani
  2021-04-11 15:40               ` Colin Baxter
@ 2021-04-11 15:55               ` Andreas Schwab
  2021-04-11 17:03                 ` Colin Baxter
  2021-04-11 18:50                 ` Philipp Stephani
  1 sibling, 2 replies; 15+ messages in thread
From: Andreas Schwab @ 2021-04-11 15:55 UTC (permalink / raw)
  To: Philipp Stephani; +Cc: Colin Baxter, Eli Zaretskii, Emacs developers

There is still something wrong here:

<https://build.opensuse.org/package/live_build_log/home:AndreasSchwab:emacs:master/emacs/15.1/x86_64>

./seccomp-filter \
  seccomp-filter.bpf seccomp-filter.pfc
seccomp_init
make[2]: *** [Makefile:428: seccomp-filter.bpf] Error 1
make[2]: *** Waiting for unfinished jobs....

Andreas.

-- 
Andreas Schwab, schwab@linux-m68k.org
GPG Key fingerprint = 7578 EB47 D4E5 4D69 2510  2552 DF73 E780 A9DA AEC1
"And now for something completely different."



^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: Build failure: 'seccomp-filter'
  2021-04-11 15:55               ` Andreas Schwab
@ 2021-04-11 17:03                 ` Colin Baxter
  2021-04-11 18:50                 ` Philipp Stephani
  1 sibling, 0 replies; 15+ messages in thread
From: Colin Baxter @ 2021-04-11 17:03 UTC (permalink / raw)
  To: Andreas Schwab; +Cc: Philipp Stephani, Eli Zaretskii, Emacs developers

>>>>> Andreas Schwab <schwab@linux-m68k.org> writes:

    > There is still something wrong here:
    > <https://build.opensuse.org/package/live_build_log/home:AndreasSchwab:emacs:master/emacs/15.1/x86_64>

    > ./seccomp-filter \ seccomp-filter.bpf seccomp-filter.pfc
    > seccomp_init make[2]: *** [Makefile:428: seccomp-filter.bpf] Error
    > 1 make[2]: *** Waiting for unfinished jobs....

I don't see this on Debian. Could it os related?

Best wishes,

Colin Baxter.



^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: Build failure: 'seccomp-filter'
  2021-04-11 15:55               ` Andreas Schwab
  2021-04-11 17:03                 ` Colin Baxter
@ 2021-04-11 18:50                 ` Philipp Stephani
  2021-04-11 22:31                   ` Andreas Schwab
  1 sibling, 1 reply; 15+ messages in thread
From: Philipp Stephani @ 2021-04-11 18:50 UTC (permalink / raw)
  To: Andreas Schwab; +Cc: Colin Baxter, Eli Zaretskii, Emacs developers

Am So., 11. Apr. 2021 um 17:55 Uhr schrieb Andreas Schwab
<schwab@linux-m68k.org>:
>
> There is still something wrong here:
>
> <https://build.opensuse.org/package/live_build_log/home:AndreasSchwab:emacs:master/emacs/15.1/x86_64>
>
> ./seccomp-filter \
>   seccomp-filter.bpf seccomp-filter.pfc
> seccomp_init

OK, this is a bit subtle; seccomp_init doesn't work if the kernel
doesn't support the default action. I've now attempted to fix this
with commit 9a57897ea1a125782ff332814d3f978c38162cf8.



^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: Build failure: 'seccomp-filter'
  2021-04-11 18:50                 ` Philipp Stephani
@ 2021-04-11 22:31                   ` Andreas Schwab
  2021-04-12  7:22                     ` Philipp Stephani
  0 siblings, 1 reply; 15+ messages in thread
From: Andreas Schwab @ 2021-04-11 22:31 UTC (permalink / raw)
  To: Philipp Stephani; +Cc: Colin Baxter, Eli Zaretskii, Emacs developers

There are now different failures:

<https://build.opensuse.org/package/live_build_log/home:AndreasSchwab:emacs:master/emacs/15.2/x86_64>

seccomp-filter.c: In function ‘main’:
seccomp-filter.c:356:34: error: ‘SECCOMP_SET_MODE_FILTER’ undeclared (first use in this function); did you mean ‘HAVE_DECL_SECCOMP_SET_MODE_FILTER’?
         SCMP_A0_32 (SCMP_CMP_EQ, SECCOMP_SET_MODE_FILTER),
                                  ^
seccomp-filter.c:112:48: note: in definition of macro ‘RULE’
       const struct scmp_arg_cmp arg_array[] = {__VA_ARGS__};         \
                                                ^~~~~~~~~~~
/usr/include/libseccomp/seccomp.h:211:2: note: in expansion of macro ‘SCMP_CMP64’
  SCMP_CMP64(x, y, (uint32_t)(z))
  ^~~~~~~~~~
/usr/include/libseccomp/seccomp.h:209:2: note: in expansion of macro ‘_SCMP_CMP32_1’
  func ## nargs
  ^~~~
/usr/include/libseccomp/seccomp.h:244:28: note: in expansion of macro ‘SCMP_CMP32’
 #define SCMP_A0_32(x, ...) SCMP_CMP32(0, x, __VA_ARGS__)
                            ^~~~~~~~~~
seccomp-filter.c:356:9: note: in expansion of macro ‘SCMP_A0_32’
         SCMP_A0_32 (SCMP_CMP_EQ, SECCOMP_SET_MODE_FILTER),
         ^~~~~~~~~~
seccomp-filter.c:356:34: note: each undeclared identifier is reported only once for each function it appears in
         SCMP_A0_32 (SCMP_CMP_EQ, SECCOMP_SET_MODE_FILTER),
                                  ^
seccomp-filter.c:112:48: note: in definition of macro ‘RULE’
       const struct scmp_arg_cmp arg_array[] = {__VA_ARGS__};         \
                                                ^~~~~~~~~~~
/usr/include/libseccomp/seccomp.h:211:2: note: in expansion of macro ‘SCMP_CMP64’
  SCMP_CMP64(x, y, (uint32_t)(z))
  ^~~~~~~~~~
/usr/include/libseccomp/seccomp.h:209:2: note: in expansion of macro ‘_SCMP_CMP32_1’
  func ## nargs
  ^~~~
/usr/include/libseccomp/seccomp.h:244:28: note: in expansion of macro ‘SCMP_CMP32’
 #define SCMP_A0_32(x, ...) SCMP_CMP32(0, x, __VA_ARGS__)
                            ^~~~~~~~~~
seccomp-filter.c:356:9: note: in expansion of macro ‘SCMP_A0_32’
         SCMP_A0_32 (SCMP_CMP_EQ, SECCOMP_SET_MODE_FILTER),
         ^~~~~~~~~~
seccomp-filter.c:357:34: error: ‘SECCOMP_FILTER_FLAG_TSYNC’ undeclared (first use in this function); did you mean ‘SCMP_FLTATR_CTL_TSYNC’?
         SCMP_A1_32 (SCMP_CMP_EQ, SECCOMP_FILTER_FLAG_TSYNC));
                                  ^
seccomp-filter.c:112:48: note: in definition of macro ‘RULE’
       const struct scmp_arg_cmp arg_array[] = {__VA_ARGS__};         \
                                                ^~~~~~~~~~~
/usr/include/libseccomp/seccomp.h:211:2: note: in expansion of macro ‘SCMP_CMP64’
  SCMP_CMP64(x, y, (uint32_t)(z))
  ^~~~~~~~~~
/usr/include/libseccomp/seccomp.h:209:2: note: in expansion of macro ‘_SCMP_CMP32_1’
  func ## nargs
  ^~~~
/usr/include/libseccomp/seccomp.h:255:28: note: in expansion of macro ‘SCMP_CMP32’
 #define SCMP_A1_32(x, ...) SCMP_CMP32(1, x, __VA_ARGS__)
                            ^~~~~~~~~~
seccomp-filter.c:357:9: note: in expansion of macro ‘SCMP_A1_32’
         SCMP_A1_32 (SCMP_CMP_EQ, SECCOMP_FILTER_FLAG_TSYNC));
         ^~~~~~~~~~


Andreas.

-- 
Andreas Schwab, schwab@linux-m68k.org
GPG Key fingerprint = 7578 EB47 D4E5 4D69 2510  2552 DF73 E780 A9DA AEC1
"And now for something completely different."



^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: Build failure: 'seccomp-filter'
  2021-04-11 22:31                   ` Andreas Schwab
@ 2021-04-12  7:22                     ` Philipp Stephani
  0 siblings, 0 replies; 15+ messages in thread
From: Philipp Stephani @ 2021-04-12  7:22 UTC (permalink / raw)
  To: Andreas Schwab; +Cc: Colin Baxter, Eli Zaretskii, Emacs developers

Am Mo., 12. Apr. 2021 um 00:31 Uhr schrieb Andreas Schwab
<schwab@linux-m68k.org>:
>
> There are now different failures:
>
> <https://build.opensuse.org/package/live_build_log/home:AndreasSchwab:emacs:master/emacs/15.2/x86_64>
>
> seccomp-filter.c: In function ‘main’:
> seccomp-filter.c:356:34: error: ‘SECCOMP_SET_MODE_FILTER’ undeclared (first use in this function); did you mean ‘HAVE_DECL_SECCOMP_SET_MODE_FILTER’?
>          SCMP_A0_32 (SCMP_CMP_EQ, SECCOMP_SET_MODE_FILTER),
>                                   ^

I've tried to address this with commit 17d20bb3cb.



^ permalink raw reply	[flat|nested] 15+ messages in thread

end of thread, other threads:[~2021-04-12  7:22 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-04-11  6:45 Build failure: 'seccomp-filter' Colin Baxter
2021-04-11  7:41 ` Eli Zaretskii
2021-04-11  7:50   ` Colin Baxter
2021-04-11 10:12     ` Philipp Stephani
2021-04-11 10:45       ` Colin Baxter
2021-04-11 14:31         ` Philipp
2021-04-11 14:40           ` Philipp Stephani
2021-04-11 14:52             ` Philipp Stephani
2021-04-11 15:40               ` Colin Baxter
2021-04-11 15:55               ` Andreas Schwab
2021-04-11 17:03                 ` Colin Baxter
2021-04-11 18:50                 ` Philipp Stephani
2021-04-11 22:31                   ` Andreas Schwab
2021-04-12  7:22                     ` Philipp Stephani
2021-04-11 15:18           ` Colin Baxter

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).