You are not logged in.

#1 2020-09-22 17:06:32

adrianmay
Member
Registered: 2017-12-19
Posts: 64

Zookeeper libs

How do I get the C client libraries for zookeeper installed? I tried the main zookeeper package but it didn't deliver them. Then I found libzookeeper on the AUR but it seems to be about 3 years out of date, which I flagged. I tried various ways to massage it into shape but none of them worked, and I don't know how to write a PKGBUILD anyway. I need this to build my employer's main product so it's kind of a showstopper.

What I also tried was pulling zookeeper off github and building it. It left the libs and headers in its own subdirectory, so I copied them to /usr/lib and /include and called ldconfig on /usr/lib. Then when I built the product it said:

hzk                            > linking .stack-work/dist/x86_64-linux-tinfo6/Cabal-3.0.1.0/build/Database/Zookeeper/CApi_hsc_make.o failed (exit code 1)
hzk                            > rsp file was: ".stack-work/dist/x86_64-linux-tinfo6/Cabal-3.0.1.0/build/Database/Zookeeper/hsc2hscall178615-2.rsp"
hzk                            > command was: /usr/bin/gcc .stack-work/dist/x86_64-linux-tinfo6/Cabal-3.0.1.0/build/Database/Zookeeper/CApi_hsc_make.o .stack-work/dist/x86_64-linux-tinfo6/Cabal-3.0.1.0/build/Database/Zookeeper/CApi_hsc_utils.o -o .stack-work/dist/x86_64-linux-tinfo6/Cabal-3.0.1.0/build/Database/Zookeeper/CApi_hsc_make -fuse-ld=gold -fuse-ld=gold -lzookeeper_mt -L/home/ad/.stack/snapshots/x86_64-linux-tinfo6/0ac2d4becf94b570c7bbc63423ed252c851a250f94049171f6c0c193adbf3762/8.8.4/lib/x86_64-linux-ghc-8.8.4/resource-pool-0.2.3.2-D9L9bFp9PQaABMT3j0K9Ua -Wl,-R,/home/ad/.stack/snapshots/x86_64-linux-tinfo6/0ac2d4becf94b570c7bbc63423ed252c851a250f94049171f6c0c193adbf3762/8.8.4/lib/x86_64-linux-ghc-8.8.4/resource-pool-0.2.3.2-D9L9bFp9PQaABMT3j0K9Ua -L/home/ad/.stack/snapshots/x86_64-linux-tinfo6/34cc163526693e37a87917fdcffc2531c16da6bdb8775aea808b4cbe1c06e18b/8.8.4/lib/x86_64-linux-ghc-8.8.4/vector-0.12.1.2-AWRYcz9jfa25Avs2q9Jg9V -Wl,-R,/home/ad/.stack/snapshots/x86_64-linux-tinfo6/34cc163526693e37a87917fdcffc2531c16da6bdb8775aea808b4cbe1c06e18b/8.8.4/lib/x86_64-linux-ghc-8.8.4/vector-0.12.1.2-AWRYcz9jfa25Avs2q9Jg9V -L/home/ad/.stack/programs/x86_64-linux/ghc-tinfo6-8.8.4/lib/ghc-8.8.4/time-1.9.3 -Wl,-R,/home/ad/.stack/programs/x86_64-linux/ghc-tinfo6-8.8.4/lib/ghc-8.8.4/time-1.9.3 -L/home/ad/.stack/snapshots/x86_64-linux-tinfo6/34cc163526693e37a87917fdcffc2531c16da6bdb8775aea808b4cbe1c06e18b/8.8.4/lib/x86_64-linux-ghc-8.8.4/primitive-0.7.0.1-CN4ea3Jrhra6yENuqrDg51 -Wl,-R,/home/ad/.stack/snapshots/x86_64-linux-tinfo6/34cc163526693e37a87917fdcffc2531c16da6bdb8775aea808b4cbe1c06e18b/8.8.4/lib/x86_64-linux-ghc-8.8.4/primitive-0.7.0.1-CN4ea3Jrhra6yENuqrDg51 -L/home/ad/.stack/snapshots/x86_64-linux-tinfo6/0ac2d4becf94b570c7bbc63423ed252c851a250f94049171f6c0c193adbf3762/8.8.4/lib/x86_64-linux-ghc-8.8.4/monad-control-1.0.2.3-JO74YKryaba7Fk6tMO2Ac8 -Wl,-R,/home/ad/.stack/snapshots/x86_64-linux-tinfo6/0ac2d4becf94b570c7bbc63423ed252c851a250f94049171f6c0c193adbf3762/8.8.4/lib/x86_64-linux-ghc-8.8.4/monad-control-1.0.2.3-JO74YKryaba7Fk6tMO2Ac8 -L/home/ad/.stack/snapshots/x86_64-linux-tinfo6/34cc163526693e37a87917fdcffc2531c16da6bdb8775aea808b4cbe1c06e18b/8.8.4/lib/x86_64-linux-ghc-8.8.4/transformers-base-0.4.5.2-IoBpU3sIpRWA7c6Y1j8JQ7 -Wl,-R,/home/ad/.stack/snapshots/x86_64-linux-tinfo6/34cc163526693e37a87917fdcffc2531c16da6bdb8775aea808b4cbe1c06e18b/8.8.4/lib/x86_64-linux-ghc-8.8.4/transformers-base-0.4.5.2-IoBpU3sIpRWA7c6Y1j8JQ7 -L/home/ad/.stack/snapshots/x86_64-linux-tinfo6/34cc163526693e37a87917fdcffc2531c16da6bdb8775aea808b4cbe1c06e18b/8.8.4/lib/x86_64-linux-ghc-8.8.4/transformers-compat-0.6.5-4FrvPCFBsgnJ9PLf29P7hZ -Wl,-R,/home/ad/.stack/snapshots/x86_64-linux-tinfo6/34cc163526693e37a87917fdcffc2531c16da6bdb8775aea808b4cbe1c06e18b/8.8.4/lib/x86_64-linux-ghc-8.8.4/transformers-compat-0.6.5-4FrvPCFBsgnJ9PLf29P7hZ -L/home/ad/.stack/programs/x86_64-linux/ghc-tinfo6-8.8.4/lib/ghc-8.8.4/transformers-0.5.6.2 -Wl,-R,/home/ad/.stack/programs/x86_64-linux/ghc-tinfo6-8.8.4/lib/ghc-8.8.4/transformers-0.5.6.2 -L/home/ad/.stack/programs/x86_64-linux/ghc-tinfo6-8.8.4/lib/ghc-8.8.4/stm-2.5.0.0 -Wl,-R,/home/ad/.stack/programs/x86_64-linux/ghc-tinfo6-8.8.4/lib/ghc-8.8.4/stm-2.5.0.0 -L/home/ad/.stack/snapshots/x86_64-linux-tinfo6/0ac2d4becf94b570c7bbc63423ed252c851a250f94049171f6c0c193adbf3762/8.8.4/lib/x86_64-linux-ghc-8.8.4/hashable-1.3.0.0-JWT2qDutWgo91wFdMlkvGp -Wl,-R,/home/ad/.stack/snapshots/x86_64-linux-tinfo6/0ac2d4becf94b570c7bbc63423ed252c851a250f94049171f6c0c193adbf3762/8.8.4/lib/x86_64-linux-ghc-8.8.4/hashable-1.3.0.0-JWT2qDutWgo91wFdMlkvGp -L/home/ad/.stack/programs/x86_64-linux/ghc-tinfo6-8.8.4/lib/ghc-8.8.4/text-1.2.4.0 -Wl,-R,/home/ad/.stack/programs/x86_64-linux/ghc-tinfo6-8.8.4/lib/ghc-8.8.4/text-1.2.4.0 -L/home/ad/.stack/programs/x86_64-linux/ghc-tinfo6-8.8.4/lib/ghc-8.8.4/template-haskell-2.15.0.0 -Wl,-R,/home/ad/.stack/programs/x86_64-linux/ghc-tinfo6-8.8.4/lib/ghc-8.8.4/template-haskell-2.15.0.0 -L/home/ad/.stack/programs/x86_64-linux/ghc-tinfo6-8.8.4/lib/ghc-8.8.4/pretty-1.1.3.6 -Wl,-R,/home/ad/.stack/programs/x86_64-linux/ghc-tinfo6-8.8.4/lib/ghc-8.8.4/pretty-1.1.3.6 -L/home/ad/.stack/programs/x86_64-linux/ghc-tinfo6-8.8.4/lib/ghc-8.8.4/ghc-boot-th-8.8.4 -Wl,-R,/home/ad/.stack/programs/x86_64-linux/ghc-tinfo6-8.8.4/lib/ghc-8.8.4/ghc-boot-th-8.8.4 -L/home/ad/.stack/programs/x86_64-linux/ghc-tinfo6-8.8.4/lib/ghc-8.8.4/binary-0.8.7.0 -Wl,-R,/home/ad/.stack/programs/x86_64-linux/ghc-tinfo6-8.8.4/lib/ghc-8.8.4/binary-0.8.7.0 -L/home/ad/.stack/programs/x86_64-linux/ghc-tinfo6-8.8.4/lib/ghc-8.8.4/containers-0.6.2.1 -Wl,-R,/home/ad/.stack/programs/x86_64-linux/ghc-tinfo6-8.8.4/lib/ghc-8.8.4/containers-0.6.2.1 -L/home/ad/.stack/programs/x86_64-linux/ghc-tinfo6-8.8.4/lib/ghc-8.8.4/bytestring-0.10.10.1 -Wl,-R,/home/ad/.stack/programs/x86_64-linux/ghc-tinfo6-8.8.4/lib/ghc-8.8.4/bytestring-0.10.10.1 -L/home/ad/.stack/programs/x86_64-linux/ghc-tinfo6-8.8.4/lib/ghc-8.8.4/deepseq-1.4.4.0 -Wl,-R,/home/ad/.stack/programs/x86_64-linux/ghc-tinfo6-8.8.4/lib/ghc-8.8.4/deepseq-1.4.4.0 -L/home/ad/.stack/snapshots/x86_64-linux-tinfo6/0ac2d4becf94b570c7bbc63423ed252c851a250f94049171f6c0c193adbf3762/8.8.4/lib/x86_64-linux-ghc-8.8.4/base-orphans-0.8.2-1Y1ZqNmIsRFEurBzE3x0AA -Wl,-R,/home/ad/.stack/snapshots/x86_64-linux-tinfo6/0ac2d4becf94b570c7bbc63423ed252c851a250f94049171f6c0c193adbf3762/8.8.4/lib/x86_64-linux-ghc-8.8.4/base-orphans-0.8.2-1Y1ZqNmIsRFEurBzE3x0AA -L/home/ad/.stack/programs/x86_64-linux/ghc-tinfo6-8.8.4/lib/ghc-8.8.4/array-0.5.4.0 -Wl,-R,/home/ad/.stack/programs/x86_64-linux/ghc-tinfo6-8.8.4/lib/ghc-8.8.4/array-0.5.4.0 -L/home/ad/.stack/programs/x86_64-linux/ghc-tinfo6-8.8.4/lib/ghc-8.8.4/base-4.13.0.0 -Wl,-R,/home/ad/.stack/programs/x86_64-linux/ghc-tinfo6-8.8.4/lib/ghc-8.8.4/base-4.13.0.0 -L/home/ad/.stack/programs/x86_64-linux/ghc-tinfo6-8.8.4/lib/ghc-8.8.4/integer-gmp-1.0.2.0 -Wl,-R,/home/ad/.stack/programs/x86_64-linux/ghc-tinfo6-8.8.4/lib/ghc-8.8.4/integer-gmp-1.0.2.0 -lgmp -L/home/ad/.stack/programs/x86_64-linux/ghc-tinfo6-8.8.4/lib/ghc-8.8.4/ghc-prim-0.5.3 -Wl,-R,/home/ad/.stack/programs/x86_64-linux/ghc-tinfo6-8.8.4/lib/ghc-8.8.4/ghc-prim-0.5.3 -lc -lm -L/home/ad/.stack/programs/x86_64-linux/ghc-tinfo6-8.8.4/lib/ghc-8.8.4/rts -Wl,-R,/home/ad/.stack/programs/x86_64-linux/ghc-tinfo6-8.8.4/lib/ghc-8.8.4/rts -lm -lrt -ldl -lpthread
hzk                            > error: /home/ad/build/zookeeper/zookeeper-client/zookeeper-client-c/src/zookeeper.c:608: error: undefined reference to 'SSL_free'
hzk                            > /home/ad/build/zookeeper/zookeeper-client/zookeeper-client-c/src/zookeeper.c:610: error: undefined reference to 'SSL_CTX_free'
hzk                            > /home/ad/build/zookeeper/zookeeper-client/zookeeper-client-c/src/zookeeper.c:362: error: undefined reference to 'SSL_write'
hzk                            > /home/ad/build/zookeeper/zookeeper-client/zookeeper-client-c/src/zookeeper.c:362: error: undefined reference to 'SSL_write'
hzk                            > /home/ad/build/zookeeper/zookeeper-client/zookeeper-client-c/src/zookeeper.c:362: error: undefined reference to 'SSL_write'
hzk                            > /home/ad/build/zookeeper/zookeeper-client/zookeeper-client-c/src/zookeeper.c:362: error: undefined reference to 'SSL_write'
hzk                            > /home/ad/build/zookeeper/zookeeper-client/zookeeper-client-c/src/zookeeper.c:2758: error: undefined reference to 'SSL_connect'
hzk                            > /home/ad/build/zookeeper/zookeeper-client/zookeeper-client-c/src/zookeeper.c:2762: error: undefined reference to 'SSL_get_error'
hzk                            > /home/ad/build/zookeeper/zookeeper-client/zookeeper-client-c/src/zookeeper.c:2687: error: undefined reference to 'OPENSSL_init_ssl'
hzk                            > /home/ad/build/zookeeper/zookeeper-client/zookeeper-client-c/src/zookeeper.c:2688: error: undefined reference to 'TLS_client_method'
hzk                            > /home/ad/build/zookeeper/zookeeper-client/zookeeper-client-c/src/zookeeper.c:2690: error: undefined reference to 'FIPS_mode'
hzk                            > /home/ad/build/zookeeper/zookeeper-client/zookeeper-client-c/src/zookeeper.c:2695: error: undefined reference to 'SSL_CTX_new'
hzk                            > /home/ad/build/zookeeper/zookeeper-client/zookeeper-client-c/src/zookeeper.c:2698: error: undefined reference to 'SSL_CTX_set_verify'
hzk                            > /home/ad/build/zookeeper/zookeeper-client/zookeeper-client-c/src/zookeeper.c:2700: error: undefined reference to 'SSL_CTX_load_verify_locations'
hzk                            > /home/ad/build/zookeeper/zookeeper-client/zookeeper-client-c/src/zookeeper.c:2706: error: undefined reference to 'SSL_CTX_set_default_verify_paths'
hzk                            > /home/ad/build/zookeeper/zookeeper-client/zookeeper-client-c/src/zookeeper.c:2713: error: undefined reference to 'SSL_CTX_use_certificate_chain_file'
hzk                            > /home/ad/build/zookeeper/zookeeper-client/zookeeper-client-c/src/zookeeper.c:2720: error: undefined reference to 'SSL_CTX_set_default_passwd_cb_userdata'
hzk                            > /home/ad/build/zookeeper/zookeeper-client/zookeeper-client-c/src/zookeeper.c:2721: error: undefined reference to 'SSL_CTX_use_PrivateKey_file'
hzk                            > /home/ad/build/zookeeper/zookeeper-client/zookeeper-client-c/src/zookeeper.c:2728: error: undefined reference to 'SSL_CTX_check_private_key'
hzk                            > /home/ad/build/zookeeper/zookeeper-client/zookeeper-client-c/src/zookeeper.c:2735: error: undefined reference to 'SSL_CTX_ctrl'
hzk                            > /home/ad/build/zookeeper/zookeeper-client/zookeeper-client-c/src/zookeeper.c:2737: error: undefined reference to 'SSL_new'
hzk                            > /home/ad/build/zookeeper/zookeeper-client/zookeeper-client-c/src/zookeeper.c:2747: error: undefined reference to 'SSL_set_fd'
hzk                            > /home/ad/build/zookeeper/zookeeper-client/zookeeper-client-c/src/zookeeper.c:2701: error: undefined reference to 'SSL_CTX_free'
hzk                            > /home/ad/build/zookeeper/zookeeper-client/zookeeper-client-c/src/zookeeper.c:2714: error: undefined reference to 'SSL_CTX_free'
hzk                            > /home/ad/build/zookeeper/zookeeper-client/zookeeper-client-c/src/zookeeper.c:2707: error: undefined reference to 'SSL_CTX_free'
hzk                            > /home/ad/build/zookeeper/zookeeper-client/zookeeper-client-c/src/zookeeper.c:371: error: undefined reference to 'SSL_read'
hzk                            > /home/ad/build/zookeeper/zookeeper-client/zookeeper-client-c/src/zookeeper.c:371: error: undefined reference to 'SSL_read'
hzk                            > /home/ad/build/zookeeper/zookeeper-client/zookeeper-client-c/src/zookeeper.c:371: error: undefined reference to 'SSL_read'
hzk                            > /home/ad/build/zookeeper/zookeeper-client/zookeeper-client-c/src/zk_sasl.c:109: error: undefined reference to 'sasl_dispose'
hzk                            > /home/ad/build/zookeeper/zookeeper-client/zookeeper-client-c/src/zk_sasl.c:202: error: undefined reference to 'sasl_dispose'
hzk                            > /home/ad/build/zookeeper/zookeeper-client/zookeeper-client-c/src/zk_sasl.c:236: error: undefined reference to 'sasl_client_new'
hzk                            > /home/ad/build/zookeeper/zookeeper-client/zookeeper-client-c/src/zk_sasl.c:246: error: undefined reference to 'sasl_errstring'
hzk                            > /home/ad/build/zookeeper/zookeeper-client/zookeeper-client-c/src/zk_sasl.c:269: error: undefined reference to 'sasl_client_start'
hzk                            > /home/ad/build/zookeeper/zookeeper-client/zookeeper-client-c/src/zk_sasl.c:273: error: undefined reference to 'sasl_errdetail'
hzk                            > /home/ad/build/zookeeper/zookeeper-client/zookeeper-client-c/src/zk_sasl.c:273: error: undefined reference to 'sasl_errstring'
hzk                            > /home/ad/build/zookeeper/zookeeper-client/zookeeper-client-c/src/zk_sasl.c:354: error: undefined reference to 'sasl_client_step'
hzk                            > /home/ad/build/zookeeper/zookeeper-client/zookeeper-client-c/src/zk_sasl.c:362: error: undefined reference to 'sasl_errdetail'
hzk                            > /home/ad/build/zookeeper/zookeeper-client/zookeeper-client-c/src/zk_sasl.c:362: error: undefined reference to 'sasl_errstring'

hzk is the haskell library for zookeeper. This is odd cos on an earlier arch I got this libzookeeper package working with a few packages and this didn't happen. So something is different about the way I just hacked the zookeeper libraries into place.

Last edited by adrianmay (2020-09-22 17:16:48)

Offline

#2 2020-09-22 17:32:14

WorMzy
Forum Moderator
From: Scotland
Registered: 2010-06-16
Posts: 11,835
Website

Re: Zookeeper libs

Mod note: Moving to AUR Issues.


Sakura:-
Mobo: MSI MAG X570S TORPEDO MAX // Processor: AMD Ryzen 9 5950X @4.9GHz // GFX: AMD Radeon RX 5700 XT // RAM: 32GB (4x 8GB) Corsair DDR4 (@ 3000MHz) // Storage: 1x 3TB HDD, 6x 1TB SSD, 2x 120GB SSD, 1x 275GB M2 SSD

Making lemonade from lemons since 2015.

Offline

#3 2020-09-22 17:50:23

Stefan Husmann
Member
From: Germany
Registered: 2007-08-07
Posts: 1,391

Re: Zookeeper libs

What were the "ways to massage it into shape"? What I would try was to change the pkgver in the libzookeeper PKGBUILD to the most recent release (and the corresponding md5sum) and run makepkg on it.

Offline

#4 2020-09-22 19:11:59

adrianmay
Member
Registered: 2017-12-19
Posts: 64

Re: Zookeeper libs

Well on earlier releases, I just had to patch the length of a sprintf buffer that the newer gcc was warning about. Now though, it complains that it won't target java 1.6 anymore, so I hacked the build.xml to say 1.7, then I got thousands of errors about Record being ambiguous and its knock-on effects. When I pull the newest version of the sources it's moved from ant to maven and everything is different so I have nothing to copy off. I persisted, but right now it seems to be trying to install the package into the same directory where I built it instead of /usr.

Offline

#5 2020-09-22 19:27:43

loqs
Member
Registered: 2014-03-06
Posts: 17,304

Re: Zookeeper libs

Please post the PKGBUILD you are using if you are using one and the output of makepkg ,  if you are not using a PKGBUILD the commands you are using and their outputs.

Offline

#6 2020-09-22 20:31:53

Stefan Husmann
Member
From: Germany
Registered: 2007-08-07
Posts: 1,391

Re: Zookeeper libs

The build system was changed completely upstream. It uses maven now (3.6.2 tarball). There is a file README_packaging.md with build instructions.

Offline

#7 2020-09-22 20:40:00

loqs
Member
Registered: 2014-03-06
Posts: 17,304

Re: Zookeeper libs

pkgname=libzookeeper
_pkgname=apache-zookeeper
pkgver=3.6.2
pkgrel=1
pkgdesc="libzookeeper"
arch=('i686' 'x86_64')
url="https://github.com/apache/zookeeper"
license=('Apache')
depends=('jre-openjdk')
makedepends=(jdk-openjdk inetutils maven)
source=(https://artfiles.org/apache.org/$pkgname/$pkgname-$pkgver/$_pkgname-$pkgver.tar.gz)
md5sums=('676007ad00a8a3e318ce6570c81b2452')

build() {
  export PATH="/usr/lib/jvm/java-14-openjdk/jre/bin/:$PATH"
  cd $_pkgname-$pkgver
  mvn -Pfull-build -DskipTests install
}

package() {
  cd $_pkgname-$pkgver

#  make DESTDIR="$pkgdir/" install
}

prepare() {
  cd $_pkgname-$pkgver
#  mvn --batch-mode validate -Pfull-build -DskipTests
}

Fails in a clean chroot,  skipped the thousands of lines:

....
main:
[INFO] Executed tasks
[INFO] 
[INFO] --- javacc-maven-plugin:2.6:javacc (javacc) @ zookeeper-jute ---
[INFO] Skipping - all parsers are up to date
[INFO] 
[INFO] --- maven-compiler-plugin:3.8.1:compile (pre-compile-jute) @ zookeeper-jute ---
[INFO] Changes detected - recompiling the module!
[INFO] Compiling 106 source files to /build/libzookeeper/src/apache-zookeeper-3.6.2/zookeeper-jute/target/classes
[INFO] 
[INFO] --- exec-maven-plugin:1.6.0:exec (generate-Java-Jute) @ zookeeper-jute ---
/build/libzookeeper/src/apache-zookeeper-3.6.2/zookeeper-jute/src/main/resources/zookeeper.jute Parsed Successfully
[INFO] 
[INFO] --- exec-maven-plugin:1.6.0:exec (generate-C-Jute) @ zookeeper-jute ---
/build/libzookeeper/src/apache-zookeeper-3.6.2/zookeeper-jute/src/main/resources/zookeeper.jute Parsed Successfully
[INFO] 
[INFO] --- build-helper-maven-plugin:3.0.0:add-source (jute-as-dependency) @ zookeeper-jute ---
[INFO] Source directory: /build/libzookeeper/src/apache-zookeeper-3.6.2/zookeeper-jute/target/generated-sources/java added.
[INFO] 
[INFO] <<< maven-source-plugin:3.0.1:jar (attach-sources) < generate-sources @ zookeeper-jute <<<
[INFO] 
[INFO] 
[INFO] --- maven-source-plugin:3.0.1:jar (attach-sources) @ zookeeper-jute ---
[INFO] Building jar: /build/libzookeeper/src/apache-zookeeper-3.6.2/zookeeper-jute/target/zookeeper-jute-3.6.2-sources.jar
[INFO] 
[INFO] --- maven-javadoc-plugin:3.0.1:jar (attach-javadocs) @ zookeeper-jute ---
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Summary for Apache ZooKeeper 3.6.2:
[INFO] 
[INFO] Apache ZooKeeper ................................... SUCCESS [ 31.962 s]
[INFO] Apache ZooKeeper - Documentation ................... SUCCESS [  5.559 s]
[INFO] Apache ZooKeeper - Jute ............................ FAILURE [  8.116 s]
[INFO] Apache ZooKeeper - Server .......................... SKIPPED
[INFO] Apache ZooKeeper - Metrics Providers ............... SKIPPED
[INFO] Apache ZooKeeper - Prometheus.io Metrics Provider .. SKIPPED
[INFO] Apache ZooKeeper - Client .......................... SKIPPED
[INFO] Apache ZooKeeper - Client - C ...................... SKIPPED
[INFO] Apache ZooKeeper - Recipes ......................... SKIPPED
[INFO] Apache ZooKeeper - Recipes - Election .............. SKIPPED
[INFO] Apache ZooKeeper - Recipes - Lock .................. SKIPPED
[INFO] Apache ZooKeeper - Recipes - Queue ................. SKIPPED
[INFO] Apache ZooKeeper - Assembly ........................ SKIPPED
[INFO] Apache ZooKeeper - Compatibility Tests ............. SKIPPED
[INFO] Apache ZooKeeper - Compatibility Tests - Curator ... SKIPPED
[INFO] Apache ZooKeeper - Tests ........................... SKIPPED
[INFO] Apache ZooKeeper - Contrib ......................... SKIPPED
[INFO] Apache ZooKeeper - Contrib - Fatjar ................ SKIPPED
[INFO] Apache ZooKeeper - Contrib - Loggraph .............. SKIPPED
[INFO] Apache ZooKeeper - Contrib - Rest .................. SKIPPED
[INFO] Apache ZooKeeper - Contrib - ZooInspector .......... SKIPPED
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time:  46.448 s
[INFO] Finished at: 2020-09-22T20:37:46
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-javadoc-plugin:3.0.1:jar (attach-javadocs) on project zookeeper-jute: MavenReportException: Error while generating Javadoc: Unable to find javadoc command: The environment variable JAVA_HOME is not correctly set. -> [Help 1]
[ERROR] 
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR] 
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException
[ERROR] 
[ERROR] After correcting the problems, you can resume the build with the command
[ERROR]   mvn <args> -rf :zookeeper-jute

Edit:

pkgname=libzookeeper
_pkgname=apache-zookeeper
pkgver=3.6.2
pkgrel=1
pkgdesc="libzookeeper"
arch=('i686' 'x86_64')
url="https://github.com/apache/zookeeper"
license=('Apache')
depends=('jre-openjdk')
makedepends=('cppunit' 'java-environment=8' 'inetutils' 'maven')
source=(https://artfiles.org/apache.org/$pkgname/$pkgname-$pkgver/$_pkgname-$pkgver.tar.gz)
md5sums=('676007ad00a8a3e318ce6570c81b2452')

build() {
  export PATH="/usr/lib/jvm/java-8-openjdk/jre/bin/:$PATH"
  cd $_pkgname-$pkgver
  mvn package \
    -Dmaven.repo.local="${srcdir}/repo" \
    -Pfull-build -DskipTests
}

package() {
  cd $_pkgname-$pkgver
  mvn install \
    -Dmaven.repo.local="${srcdir}/repo" \
    -Pfull-build -DskipTests

}

prepare() {
  cd $_pkgname-$pkgver
#  mvn --batch-mode validate -Pfull-build -DskipTests
}

Builds but installs to the lcoal repo.

Last edited by loqs (2020-09-22 21:26:25)

Offline

#8 2020-09-23 04:37:37

adrianmay
Member
Registered: 2017-12-19
Posts: 64

Re: Zookeeper libs

I got a bit further. Back in the github repo, I build with:

JAVA_HOME=/usr/lib/jvm/default mvn install -Pfull-build -DskipTests -Dc-client-openssl=no -Dc-client-sasl=no

which fixes the undefined externals and tells it where javadoc is.

I also found that the tarball it builds at zookeeper-assembly/target/apache-zookeeper-3.7.0-SNAPSHOT-lib.tar.gz (mentioned in the last line of README_packaging.md) has paths starting with apache-zookeeper-3.7.0-SNAPSHOT-lib/usr, which seems pretty useless. So I installed like this instead:

tar c -C zookeeper-client/zookeeper-client-c/target/c lib include | sudo tar x -C /usr

So I can now build our product.

Of course it would be nice if the aur package worked, but I'm not sure how to encode the above in PKGBUILD.

It was also a cop out that I disabled ssl and sasl, but I think the deal is that the hzk build isn't linking to those libs cos zookeeper didn't use them when hzk was last maintained. I don't fancy digging into that problem. If people fix this package but leave those libs enabled, it'll break haskell. That would at least put you in good company: haskell breaks haskell all the time ;-)

Offline

Board footer

Powered by FluxBB