OS:
daz#daz:/rom/aosp-mirror/android-test$ uname -ar
Linux daz 5.4.0-28-generic #32-Ubuntu SMP Wed Apr 22 17:40:10 UTC 2020 x86_64 x86_64 x86_64 GNU/Linux
Building with bazel-2.2.0 with the target in the code below:
daz#daz:/rom/aosp-mirror/android-test$ bazel-2.2.0 build :axt_m2repository
I am trying to build the android-test repo here:
https://github.com/android/android-test
The definition for these rules appears to be this:
# Kotlin toolchains
rules_kotlin_version = "4c71740a1b63b785fc90afd8d4d4d5bfda527107"
http_archive(
name = "io_bazel_rules_kotlin",
sha256 = "c0ca7b66d9f466067635482592634703bf0a648d51ec958f41796d43ca8256b3",
strip_prefix = "rules_kotlin-%s" % rules_kotlin_version,
type = "zip",
urls = ["https://github.com/bazelbuild/rules_kotlin/archive/%s.zip" % rules_kotlin_version],
)
load("#io_bazel_rules_kotlin//kotlin:kotlin.bzl", "kotlin_repositories", "kt_register_toolchains")
kotlin_repositories()
kt_register_toolchains()
But I get the following exception when trying to build:
ERROR: error loading package '': Encountered error while reading extension file 'kotlin/kotlin.bzl': no such package '#io_bazel_rules_kotlin//kotlin': error loading package 'external': Could not load //external package
The full output is here:
ERROR: /home/daz/.cache/bazel/_bazel_daz/ff62db25b941d7730a4c94ee1d6f2c41/external/robolectric/bazel/robolectric.bzl:2:5: Traceback (most recent call last):
File "/rom/aosp-mirror/android-test/WORKSPACE", line 130
robolectric_repositories()
File "/home/daz/.cache/bazel/_bazel_daz/ff62db25b941d7730a4c94ee1d6f2c41/external/robolectric/bazel/robolectric.bzl", line 381, in robolectric_repositories
android_all_jars()
File "/home/daz/.cache/bazel/_bazel_daz/ff62db25b941d7730a4c94ee1d6f2c41/external/robolectric/bazel/robolectric.bzl", line 2, in android_all_jars
native.maven_jar
no native function or rule 'maven_jar'
Available attributes: aar_import, action_listener, alias, android_binary, android_device, android_device_script_fixture, android_host_service_fixture, android_instrumentation_test, android_library, android_local_test, android_ndk_repository, android_sdk, android_sdk_repository, android_tools_defaults_jar, apple_binary, apple_cc_toolchain, apple_static_library, available_xcodes, bazel_version, bind, cc_binary, cc_host_toolchain_alias, cc_import, cc_libc_top_alias, cc_library, cc_proto_library, cc_test, cc_toolchain, cc_toolchain_alias, cc_toolchain_suite, config_feature_flag, config_setting, constraint_setting, constraint_value, environment, existing_rule, existing_rules, exports_files, extra_action, fdo_prefetch_hints, fdo_profile, filegroup, genquery, genrule, glob, j2objc_library, java_binary, java_import, java_library, java_lite_proto_library, java_package_configuration, java_plugin, java_proto_library, java_runtime, java_runtime_alias, java_test, java_toolchain, java_toolchain_alias, label_flag, label_setting, local_config_platform, local_repository, new_local_repository, ninja_build, ninja_graph, objc_import, objc_library, package_group, package_name, platform, proto_lang_toolchain, proto_library, py_binary, py_library, py_runtime, py_test, register_execution_platforms, register_toolchains, repository_name, sh_binary, sh_library, sh_test, test_suite, toolchain, toolchain_type, xcode_config, xcode_config_alias, xcode_version
ERROR: error loading package '': Encountered error while reading extension file 'kotlin/kotlin.bzl': no such package '#io_bazel_rules_kotlin//kotlin': error loading package 'external': Could not load //external package
INFO: Elapsed time: 0.061s
INFO: 0 processes.
FAILED: Build did NOT complete successfully (0 packages loaded)
WORKAROUND
Build branch:
androidx-test-1.3.0-beta01
Use bazel-2.2.0
bazel-2.2.0 build :axt_m2repository
This is the related issue in the android-test github issue tracker:
https://github.com/android/android-test/issues/626
Make sure that you're using the latest version of Bazel and the android-test repo.
The maven_jar native rule was removed in Bazel 2.0 (Bazel tracking ticket). Have you tried building with a Bazel version < 2.0 (e.g. 1.2.1)?
Try to install mod_antiloris. Getting compile error, when running the below command:
apxs -a -i -c mod_antiloris.c
Compile Error:
mod_antiloris.c:126:37: error: 'conn_rec' has no member named
'remote_ip'
apr_cpystrn(ws_record->client, c->remote_ip, sizeof(ws_record->client));
mod_antiloris.c:133:10: warning: passing argument 1 of
'ap_get_scoreboard_worker' makes pointer from integer without a cast
[enabled by default]
ws_record = ap_get_scoreboard_worker(i, j);
Apache version: Apache/2.4.6 (SLES Expanded Support platform)
O/S Redhat 7.4
Any advise please?
Thanks
Nic
It looks like the module is outdated: according to doxygen the existing fields are either client_ip or remote_host.
Edit: someone posted a patch here.
I'm trying to install SCIP on OSX mavericks. I've downloaded the tarball here, extracted it, and have tried to compile it using
make scipoptlib GMP=false ZLIB=false READLINE=false SHARED=true
This gives me error 1 below. My interpretation of error 1 is that /usr/local/lib/libisl.10.dylib does not exist. That's correct: I have isl.0.14.1, located at /usr/local/Cellar/isl/0.14.1. And in fact I can't install isl.0.10.1, because the compiler options it expects don't work with the current version of gcc (I think; see error 2 below).
Can I tell SCIP to use isl.0.14.1, and if so, how?
**error 1:**
** Extracting SoPlex archive "/Applications/scipoptsuite-3.2.0/soplex-2.2.0.tgz".
** Extracting ZIMPL archive "/Applications/scipoptsuite-3.2.0/zimpl-3.3.3.tgz".
** Extracting SCIP archive "/Applications/scipoptsuite-3.2.0/scip-3.2.0.tgz".
** compile libraries statically with compiler flag -fPIC
rm -rf obj/O.darwin.x86_64.gnu.normal.opt/* bin/zimpl-3.3.3.darwin.x86_64.gnu.normal.opt lib/libzimpl-3.3.3.darwin.x86_64.gnu.opt.a lib/libzimpl-3.3.3.darwin.x86_64.gnu.opt.dbl.a lib/libzimpl.darwin.x86_64.gnu.opt.a bin/zimpl.darwin.x86_64.gnu.opt bin/zimpl
** Creating directory "/Applications/scipoptsuite-3.2.0/scip-3.2.0/lib".
** Creating directory "/Applications/scipoptsuite-3.2.0/scip-3.2.0/lib/zimplinc".
** Building SoPlex library "/Applications/scipoptsuite-3.2.0/soplex-2.2.0/lib/libsoplex.darwin.x86_64.gnu.opt.a".
-> compiling obj/O.darwin.x86_64.gnu.opt/lib/changesoplex.o
dyld: Library not loaded: /usr/local/lib/libisl.10.dylib
Referenced from: /usr/local/Cellar/gcc/4.9.1/libexec/gcc/x86_64-apple-darwin13.2.0/4.9.1/cc1plus
Reason: image not found
g++: internal compiler error: Trace/BPT trap: 5 (program cc1plus)
make[4]: *** [obj/O.darwin.x86_64.gnu.opt/lib/changesoplex.o] Abort trap: 6
make[3]: [makelibfile] Error 2 (ignored)
-> compiling obj/O.darwin.x86_64.gnu.opt/lib/changesoplex.o
dyld: Library not loaded: /usr/local/lib/libisl.10.dylib
Referenced from: /usr/local/Cellar/gcc/4.9.1/libexec/gcc/x86_64-apple-darwin13.2.0/4.9.1/cc1plus
Reason: image not found
g++: internal compiler error: Trace/BPT trap: 5 (program cc1plus)
make[4]: *** [obj/O.darwin.x86_64.gnu.opt/lib/changesoplex.o] Abort trap: 6
make[3]: [all] Error 2 (ignored)
** ZIMPL support disabled.
** Creating necessary soft-links.
** Building SCIP libraries and executable.
-> generating necessary links
- Current settings: LPS=spx OSTYPE=darwin ARCH=x86_64 COMP=gnu SUFFIX= ZIMPL=false ZIMPLOPT=opt IPOPT=false IPOPTOPT=opt EXPRINT=cppad GAMS=false
* SCIP needs some softlinks to external programs, in particular, LP-solvers.
* Please insert the paths to the corresponding directories/libraries below.
* The links will be installed in the 'lib' directory.
* For more information and if you experience problems see the INSTALL file.
-> "spxinc" is the path to the SoPlex "src" directory, e.g., "../../soplex/src".
-> "libsoplex.*" is the path to the SoPlex library, e.g., "../../soplex/lib/libsoplex.darwin.x86_64.gnu.opt.a"
-> compiling obj/O.darwin.x86_64.gnu.opt/lib/scip/branch_allfullstrong.o
dyld: Library not loaded: /usr/local/lib/libisl.10.dylib
Referenced from: /usr/local/Cellar/gcc/4.9.1/libexec/gcc/x86_64-apple-darwin13.2.0/4.9.1/cc1
Reason: image not found
gcc: internal compiler error: Trace/BPT trap: 5 (program cc1)
make[4]: *** [obj/O.darwin.x86_64.gnu.opt/lib/scip/branch_allfullstrong.o] Abort trap: 6
make[3]: *** [makesciplibfile] Error 2
make[2]: *** [scipbinary] Error 2
make[1]: *** [scipbinary] Error 2
make: *** [scipoptlib] Error 2
error 2, produced by running ./configure in libisl.10 directory:
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
It was created by isl configure 0.10, which was
generated by GNU Autoconf 2.68. Invocation command line was
$ ./configure
## --------- ##
## Platform. ##
## --------- ##
hostname = dhcp-143-183.caltech.edu
uname -m = x86_64
uname -r = 13.4.0
uname -s = Darwin
uname -v = Darwin Kernel Version 13.4.0: Wed Mar 18 16:20:14 PDT 2015; root:xnu-2422.115.14~1/RELEASE_X86_64
/usr/bin/uname -p = i386
/bin/uname -X = unknown
/bin/arch = unknown
/usr/bin/arch -k = unknown
/usr/convex/getsysinfo = unknown
/usr/bin/hostinfo = Mach kernel version:
Darwin Kernel Version 13.4.0: Wed Mar 18 16:20:14 PDT 2015; root:xnu-2422.115.14~1/RELEASE_X86_64
Kernel configured for up to 4 processors.
2 processors are physically available.
4 processors are logically available.
Processor type: i486 (Intel 80486)
Processors active: 0 1 2 3
Primary memory available: 16.00 gigabytes
Default processor set: 327 tasks, 1905 threads, 4 processors
Load average: 4.32, Mach factor: 0.47
/bin/machine = unknown
/usr/bin/oslevel = unknown
/bin/universe = unknown
PATH: /Users/madeleine/anaconda/bin/
PATH: /usr/local/bin
PATH: /usr/bin
PATH: /bin
PATH: /usr/sbin
PATH: /sbin
PATH: /usr/local/bin
PATH: /opt/X11/bin
PATH: /usr/local/go/bin
PATH: /usr/texbin
PATH: /usr/bin
PATH: /bin
PATH: /usr/sbin
PATH: /sbin
PATH: /opt/local/bin
PATH: /opt/local/sbin
PATH: /Applications/spark-0.9.1-bin-hadoop2/bin
PATH: /Applications/Julia-0.3.8.app/Contents/Resources/julia/bin
## ----------- ##
## Core tests. ##
## ----------- ##
configure:2762: checking for a BSD-compatible install
configure:2830: result: /usr/bin/install -c
configure:2841: checking whether build environment is sane
configure:2891: result: yes
configure:3032: checking for a thread-safe mkdir -p
configure:3071: result: ./install-sh -c -d
configure:3084: checking for gawk
configure:3114: result: no
configure:3084: checking for mawk
configure:3114: result: no
configure:3084: checking for nawk
configure:3114: result: no
configure:3084: checking for awk
configure:3100: found /usr/bin/awk
configure:3111: result: awk
configure:3122: checking whether make sets $(MAKE)
configure:3144: result: yes
configure:3287: checking for gcc
configure:3303: found /usr/local/bin/gcc
configure:3314: result: gcc
configure:3543: checking for C compiler version
configure:3552: gcc --version >&5
gcc (Homebrew gcc 4.9.1) 4.9.1
Copyright (C) 2014 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
configure:3563: $? = 0
configure:3552: gcc -v >&5
Using built-in specs.
COLLECT_GCC=gcc
COLLECT_LTO_WRAPPER=/usr/local/Cellar/gcc/4.9.1/libexec/gcc/x86_64-apple-darwin13.2.0/4.9.1/lto-wrapper
Target: x86_64-apple-darwin13.2.0
Configured with: ../configure --build=x86_64-apple-darwin13.2.0 --prefix=/usr/local/Cellar/gcc/4.9.1 --enable-languages=c,c++,objc,obj-c++,fortran --program-suffix=-4.9 --with-gmp=/usr/local/opt/gmp --with-mpfr=/usr/local/opt/mpfr --with-mpc=/usr/local/opt/libmpc --with-cloog=/usr/local/opt/cloog --with-isl=/usr/local/opt/isl --with-system-zlib --enable-version-specific-runtime-libs --enable-libstdcxx-time=yes --enable-stage1-checking --enable-checking=release --enable-lto --disable-werror --with-pkgversion='Homebrew gcc 4.9.1' --with-bugurl=https://github.com/Homebrew/homebrew/issues --enable-plugin --disable-nls --enable-multilib
Thread model: posix
gcc version 4.9.1 (Homebrew gcc 4.9.1)
configure:3563: $? = 0
configure:3552: gcc -V >&5
gcc: error: unrecognized command line option '-V'
gcc: fatal error: no input files
compilation terminated.
configure:3563: $? = 1
configure:3552: gcc -qversion >&5
gcc: error: unrecognized command line option '-qversion'
gcc: fatal error: no input files
compilation terminated.
configure:3563: $? = 1
configure:3583: checking whether the C compiler works
configure:3605: gcc conftest.c >&5
dyld: Library not loaded: /usr/local/lib/libisl.10.dylib
Referenced from: /usr/local/Cellar/gcc/4.9.1/libexec/gcc/x86_64-apple-darwin13.2.0/4.9.1/cc1
Reason: image not found
gcc: internal compiler error: Trace/BPT trap: 5 (program cc1)
./configure: line 3607: 9063 Abort trap: 6 $CC $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5
I can't see where or why the SCIP Optimization Suite would be using isl. To be precise, in your case not SCIP fails to compile but SoPlex. Have you checked whether you can compile SoPlex alone? Just go into the subdirectory and type make or make SHARED=true GMP=false ZLIB=false to match the original command.
Have you compiled some other code with your compiler? It may also be that your gcc itself is broken.
I have the impression that the C++ compiler itself is broken:
dyld: Library not loaded: /usr/local/lib/libisl.10.dylib
Referenced from: /usr/local/Cellar/gcc/4.9.1/libexec/gcc/x86_64-apple-darwin13.2.0/4.9.1/cc1plus
Maybe try a simple (hello-world) C++ program first to test that the compiler itself is ok.
I am trying to install mod_perl 2.0.9 with Apache 2.2.31 on Ubuntu 14.04. I got stuck with a missing file mod_perl.so. Below are the details.
Followed the instructions https://perl.apache.org/docs/2.0/user/install/install.html#Prerequisites,
I downloaded httpd-2.2.31.tar.gz and mod_perl-2.0.9.tar.gz.
I unziped them by
tar -xvzf httpd-2.2.31.tar.gz
tar -xvzf mod_perl-2.0.9.tar.gz
and got directories httpd-2.2.31 and mod_perl-2.0.9.
Then I typed command (following the link):
perl Makefile.PL MP_APXS=/path/to/httpd-2.2.31/server/mpm/prefork/bin/apxs
I got:
[warning] mod_perl dso library will be built as mod_perl.so
[warning] You'll need to add the following to httpd.conf:
[warning]
[warning] LoadModule perl_module modules/mod_perl.so
[warning]
[warning] depending on your build, mod_perl might not live in
[warning] the modules/ directory.
[warning] Check the results of
[warning]
[warning] $ /path/to/httpd-2.2.31/server/mpm/prefork/bin/apxs -q LIBEXECDIR
[warning]
[warning] and adjust the LoadModule directive accordingly.
But, I could not find mod_perl.so anywhere.
Can anybody let me know where to get mod_perl.so or where it is supposed to be?
Without properly set mod_perl.so, I ran
make
and got
/usr/bin/ld: cannot find -lperl
collect2: error: ld returned 1 exit status
make[1]: *** [mod_perl.so] Error 1
make[1]: Leaving directory `/home/guohua/stas/mod_perl-2.0.9/src/modules/perl'
make: *** [modperl_lib] Error 2
How can I fix this?
Thank you in advance.
On Ubuntu/debian, install libperl-dev which provides /usr/lib/libperl.so
I'm trying to add DKMS support in a kernel module i'm working on.
I have placed the kernel module source with a static lib to be linked against in the following directory:
/usr/src/dpx/1.0
With the following files:
dkms.conf
Makefile
dpxmtt.c
lib.a
dkms.conf file is like this:
MAKE="make"
CLEAN="make clean"
BUILT_MODULE_NAME=dpx
BUILT_MODULE_LOCATION=src/
DEST_MODULE_LOCATION=/kernel/drivers/input/touchscreen
PACKAGE_NAME=dpxm
PACKAGE_VERSION=1.0
REMAKE_INITRD=yes
And the makefile is like this:
EXTRA_CFLAGS+=-DLINUX_DRIVER -mhard-float
obj-m += dpx.o
dpx-objs:= dpxmtt.o ../source/lib.a
all:
make -C /lib/modules/$(shell uname -r)/build M=$(PWD) modules
clean:
make -C /lib/modules/$(shell uname -r)/build M=$(PWD) clean
The ../source/lib.a is an hack since when the makefile is invoked by the dkms building system it was saying that it couldn't be found in directory (the build directory), but since it was being copied to the source directory, i'm referencing it relatively.
When I call
sudo dkms build -m dpx -v 1.0
The result is almost perfect:
santos#NS-PC:~$ sudo dkms build -m dpx -v 1.0
Kernel preparation unnecessary for this kernel. Skipping...
Building module:
cleaning build area....
make KERNELRELEASE=3.0.0-14-generic....
ERROR (dkms apport): binary package for dpx: 1.0 not found
Error! Build of dpx.ko failed for: 3.0.0-14-generic (i686)
Consult the make.log in the build directory
/var/lib/dkms/dpx/1.0/build/ for more information.
nsantos#NS-PC:~$
And the content of the log file is:
DKMS make.log for dpx-1.0 for kernel 3.0.0-14-generic (i686)
Thu Jan 19 11:07:54 WET 2012
make -C /lib/modules/3.0.0-14-generic/build M=/var/lib/dkms/dpx/1.0/build modules
make[1]: Entering directory `/usr/src/linux-headers-3.0.0-14-generic'
CC [M] /var/lib/dkms/dpx/1.0/build/dpxmtt.o
LD [M] /var/lib/dkms/dpx/1.0/build/dpx.o
Building modules, stage 2.
MODPOST 1 modules
CC /var/lib/dkms/dpx/1.0/build/dpx.mod.o
LD [M] /var/lib/dkms/dpx/1.0/build/dpx.ko
make[1]: Leaving directory `/usr/src/linux-headers-3.0.0-14-generic'
The module was built correctly but it ends with the error:
ERROR (dkms apport): binary package for dpx: 1.0 not found
Error! Build of dpx.ko failed for: 3.0.0-14-generic (i686)
And I don't know what it means. Does anybody know?
Using:
$(shell uname -r)
in the Makefile it might be also wrong! The "shell uname -r" refers to the currently running kernel, but the main reason to use the dkms it's because it offers an automated method to recompile the kernel modules that reside outside of the kernel tree for every newly installed kernel. What i mean is that the Makefile might refers to a different kernel which the dkms is building the module for.
Use:
${kernelver} instead.
I had a similar problem. I think your BUILT_MODULE_LOCATION is set incorrectly to the src directory. It should be set in your example to the current directory, or you can just omit this variable and dkms would default to the current directory.