Ignore `libseccomp package not found` error in go.mod file - macos

I've been experimenting with libseccomp-golang and I've encountered the following problem in the go.mod file:
pkg-config: exec: "pkg-config": executable file not found in $PATH
This is an expected error because pkg-config is not installed. However, when I install it via brew I receive the following error:
# pkg-config --cflags -- libseccomp
Package libseccomp was not found in the pkg-config search path.
Perhaps you should add the directory containing `libseccomp.pc'
to the PKG_CONFIG_PATH environment variable
No package 'libseccomp' found
pkg-config: exit status 1
I know that libseccomp is a linux-specific package and I do not have a linux distribution installed. However, I would really like to ignore the error in the go.mod file, because everything works as expected when I build the project in a docker container. Is there any way to ignore this error?

Related

Rust build error: failed to run custom build command for `glib-sys v0.8.0`

I am trying to build a Rust program on Windows 10. When trying to compile a Rust file with I keep getting the following error messages.
cargo run
Compiling glib-sys v0.8.0
Compiling const_fn v0.4.9
Compiling quote v1.0.21
Compiling socket2 v0.4.4
Compiling net2 v0.2.37
Compiling winreg v0.7.0
error: failed to run custom build command for `glib-sys v0.8.0`
They are caused by:
Caused by:
process didn't exit successfully: `C:\Users\artem\zabotay\backend\target\debug\build\glib-sys-b1ba74e042d8283d\build-script-build` (exit code: 1)
--- stdout
cargo:rerun-if-env-changed=GLIB_2.0_NO_PKG_CONFIG
cargo:rerun-if-env-changed=PKG_CONFIG_x86_64-pc-windows-msvc
cargo:rerun-if-env-changed=PKG_CONFIG_x86_64_pc_windows_msvc
cargo:rerun-if-env-changed=HOST_PKG_CONFIG
cargo:rerun-if-env-changed=PKG_CONFIG
cargo:rerun-if-env-changed=GLIB_2.0_STATIC
cargo:rerun-if-env-changed=GLIB_2.0_DYNAMIC
cargo:rerun-if-env-changed=PKG_CONFIG_ALL_STATIC
cargo:rerun-if-env-changed=PKG_CONFIG_ALL_DYNAMIC
cargo:rerun-if-env-changed=PKG_CONFIG_PATH_x86_64-pc-windows-msvc
cargo:rerun-if-env-changed=PKG_CONFIG_PATH_x86_64_pc_windows_msvc
cargo:rerun-if-env-changed=HOST_PKG_CONFIG_PATH
cargo:rerun-if-env-changed=PKG_CONFIG_PATH
cargo:rerun-if-env-changed=PKG_CONFIG_LIBDIR_x86_64-pc-windows-msvc
cargo:rerun-if-env-changed=PKG_CONFIG_LIBDIR_x86_64_pc_windows_msvc
cargo:rerun-if-env-changed=HOST_PKG_CONFIG_LIBDIR
cargo:rerun-if-env-changed=PKG_CONFIG_LIBDIR
cargo:rerun-if-env-changed=PKG_CONFIG_SYSROOT_DIR_x86_64-pc-windows-msvc
cargo:rerun-if-env-changed=PKG_CONFIG_SYSROOT_DIR_x86_64_pc_windows_msvc
cargo:rerun-if-env-changed=HOST_PKG_CONFIG_SYSROOT_DIR
cargo:rerun-if-env-changed=PKG_CONFIG_SYSROOT_DIR
--- stderr
`"pkg-config" "--libs" "--cflags" "glib-2.0" "glib-2.0 >= 2.42"` did not exit successfully: exit code: 1
error: could not find system library 'glib-2.0' required by the 'glib-sys' crate
I look through other questions, but found no answer about glib2.0 fix
--- stderr
Package glib-2.0 was not found in the pkg-config search path.
Perhaps you should add the directory containing glib-2.0.pc' to the PKG_CONFIG_PATH environment variable No package 'glib-2.0' found Package glib-2.0 was not found in the pkg-config search path. Perhaps you should add the directory containing glib-2.0.pc'
to the PKG_CONFIG_PATH environment variable
No package 'glib-2.0' found
warning: build failed, waiting for other jobs to finish...
How to fix this error?

Which Protoc Does "Make" Command Use?

I am trying to build LAB which generate robust facial landmark.
In installation guide it says one needs to install Caffe prerequisites which I'd checked CUDA and BLAS well installed on my AWS EC2 instance.
Then I git cloned and typed make under the cloned git folder named in LAB
But it returns following error
CXX .build_release/src/caffe/proto/caffe.pb.cc
In file included from .build_release/src/caffe/proto/caffe.pb.cc:4:0:
.build_release/src/caffe/proto/caffe.pb.h:12:2: error: #error This file was generated by a newer version of protoc which is
#error This file was generated by a newer version of protoc which is
^
.build_release/src/caffe/proto/caffe.pb.h:13:2: error: #error incompatible with your Protocol Buffer headers. Please update
#error incompatible with your Protocol Buffer headers. Please update
^
.build_release/src/caffe/proto/caffe.pb.h:14:2: error: #error your headers.
#error your headers.
^
In file included from .build_release/src/caffe/proto/caffe.pb.cc:4:0:
.build_release/src/caffe/proto/caffe.pb.h:23:35: fatal error: google/protobuf/arena.h: No such file or directory
compilation terminated.
Makefile:588: recipe for target '.build_release/src/caffe/proto/caffe.pb.o' failed
make: *** [.build_release/src/caffe/proto/caffe.pb.o] Error 1
The error above looks like I am using old version of libprotoc so if I type in which protoc it returns
/home/ubuntu/anaconda3/bin//protoc
and for protoc --version it returns libprotoc 3.5.1
and for whereis protoc it returns
protoc: /usr/local/bin/protoc /home/ubuntu/anaconda3/bin/protoc /usr/share/man/man1/protoc.1.gz
Thus since it looks like I have another protoc in /usr/local/bin I had checked its version via /usr/local/bin/protoc --version which returns
libprotoc 3.3.0
Hereby I have two problems:
1) I don't know if I use make cmd, which protoc being referred.
2) I don't know the error requires which version of protoc.
How can I check and get the proper information regarding above two problems?
Try something like PROTOC=/home/ubuntu/anaconda3/bin/protoc make
Make sure compiler got correct path to protobuf headers with appropriate -I option.

Running GO GET SDL2 Error executable file not found in $PATH

Im simplly trying to install go-sdl2 on MACOX from https://github.com/veandco/go-sdl2#installation
go get -v github.com/veandco/go-sdl2/{sdl,img,mix,ttf}
I get following ERROR:
github.com/veandco/go-sdl2/sdl
# pkg-config --cflags sdl2
pkg-config: exec: "pkg-config": executable file not found in $PATH

Error in automake

I’ve trying to create install package for hello world sample C program.
I’ve done following staps.
autoscan
mv configure.scan configure.ac
edit configure.ac to add some macros.
aclocal
create Makefile.am within
bin_PROGRAMS = hello
hello_SOURCES = hello.c
Finally I did automake .
Then I got messages bellow. .
configure.ac:12: error: required file './compile' not found
configure.ac:12: 'automake --add-missing' can install 'compile'
configure.ac:6: error: required file './missing' not found
configure.ac:6: 'automake --add-missing' can install 'missing'
Makefile.am: error: required file './INSTALL' not found
Makefile.am: 'automake --add-missing' can install 'INSTALL'
Makefile.am: error: required file './NEWS' not found
Makefile.am: error: required file './README' not found
Makefile.am: error: required file './AUTHORS' not found
Makefile.am: error: required file './ChangeLog' not found
Makefile.am: error: required file './COPYING' not found
Makefile.am: 'automake --add-missing' can install 'COPYING'
Makefile.am: error: required file './depcomp' not found
Makefile.am: 'automake --add-missing' can install 'depcomp'
There aren’t any strings including compile, missing ,NEW, README or the massage said being required in Makefile.am an configure.ac files.
What should I do?
Those are information about version of some products.
CentOS release 6.4
autocomf-2.69
automake-1.14
m4-1.4
Those files need to exist to conform to the standard 'automake/autoconf' set of files.
Follow the instructions it gives you: "automake --add-missing", and the missing files will be created with dummy information which you would (in a perfect world) fill in appropriately.
Try perusing the autotools tutorial, or perhaps the autobook. See also StackOverflow: Getting started with autotools.
Additionally, read the man pages, try automake --help, read what the utility helpfully output to assist you?
Probably adding foreign to AM_INIT_AUTOMAKE macro in configure.ac could be helpful in this case.

Trouble compiling FUSE filesystems on OS X

OS: OS X Mavericks (v10.9)
FUSE: OSXFUSE v2.6.2
I'm trying to compile the loopback filesystem in C, but I'm getting this error:
$ make
cc -D_FILE_OFFSET_BITS=64 -I/usr/local/include/osxfuse/fuse -Wall -g -F/Library/Frameworks -o loopback loopback.c -losxfuse
ld: library not found for -losxfuse
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make: *** [loopback] Error 1
Trying to compile boxfs2 also produces this error:
$ make
Package libxml-2.0 was not found in the pkg-config search path.
Perhaps you should add the directory containing `libxml-2.0.pc'
to the PKG_CONFIG_PATH environment variable
No package 'libxml-2.0' found
Package libcurl was not found in the pkg-config search path.
Perhaps you should add the directory containing `libcurl.pc'
to the PKG_CONFIG_PATH environment variable
No package 'libcurl' found
Package libapp was not found in the pkg-config search path.
Perhaps you should add the directory containing `libapp.pc'
to the PKG_CONFIG_PATH environment variable
No package 'libapp' found
Package libjson was not found in the pkg-config search path.
Perhaps you should add the directory containing `libjson.pc'
to the PKG_CONFIG_PATH environment variable
No package 'libjson' found
Compiling boxfs.c
cc -c boxfs.c -o boxfs.o
boxfs.c:15:10: fatal error: 'fuse.h' file not found
#include <fuse.h>
^
1 error generated.
make: *** [boxfs.o] Error 1
Can anyone point me in the right direction?
As far as the first problem, you need the OSXFUSE library somewhere the compiler can see it, or you need to tell the compiler where it is.
You may have some success using mdfind to locate the osxfuse library file, then add -L/path/to/osxfuse to the compile/configure script to the makefile.
Similarly, the for the second, try making sure boxfs2 knows about the fuse header: Looks like adding -I/usr/local/include/osxfuse/fuse might do it.

Resources