You are not logged in.
Pages: 1
Hello everyone, I ask for help from the experts
while compiling pcsc I get stuck with this message
libredirect.c:182: undefined reference to `pthread_once'
what does it mean?
I have searched the net but I don't understand it, if someone would be so kind to give me a tip I would be grateful.
-------------------------------------------------------------------------
Salve a tutti, chiedo aiuto agli esperti
durante la compilazione di pcsc mi si blocca con questo messaggio
libredirect.c:182: undefined reference to `pthread_once'
cosa significa?
Ho cercato in rete ma non ci ho capito nulla, se qualcuno fosse così gentile da darmi una dritta gliene sarei grato.
Offline
Hi Gibor,
I try with libpthread-stubs-dev without success, i search pthread on receipts, found for few packages we adjust LDFLAGS with -lpthread, i do it for pcsc-lite, build finish successfully
# Rules to configure and make the package.
compile_rules()
{
export LDFLAGS="$LDFLAGS -lpthread"
meson _build \
--buildtype=release \
--prefix=/usr \
-Dlibudev=true \
-Dipcdir=/run/pcscd \
-Dlibsystemd=false \
-Dpolkit=false \
-Dusbdropdir=/usr/lib/pcsc/drivers &&
ninja -C _build &&
ninja -C _build install
}
[...]
[50/57] Linking target libpcscspy.so.0
[51/57] Compiling C object libpcsclite.a.p/src_simclist.c.o
[52/57] Compiling C object libpcsclite.a.p/src_winscard_clnt.c.o
[53/57] Linking static target libpcsclite.a
[54/57] Linking target pcsc_demo_static
[55/57] Generating symbol file libpcsclite.so.1.p/libpcsclite.so.1.symbols
[56/57] Linking target testpcsc
[57/57] Linking target pcsc_demo
ninja: Entering directory `_build'
[0/1] Installing files.
Installing pcscd to /home/slitaz/wok/pcsc-lite/install/usr/sbin
Installing libpcsclite_real.so.1 to /home/slitaz/wok/pcsc-lite/install/usr/lib
Installing libpcsclite.so.1 to /home/slitaz/wok/pcsc-lite/install/usr/lib
Installing libpcsclite.a to /home/slitaz/wok/pcsc-lite/install/usr/lib
Installing libpcscspy.so.0 to /home/slitaz/wok/pcsc-lite/install/usr/lib
[...]
Build dependencies to remove: 16
Removing: advancecomp autoconf automake libltdl libtool meson ninja pciids
python3-setuptools udev udev-dev usbids util-linux-blkid util-linux-mount
util-linux-smartcols xz
Pack: pcsc-lite 2.3.3-x86_64
=====================================================================================================
Executing: genpkg_rules
Copying "receipt"... Done
Executing strip on all files... Done
Time: 0.50s. Size: 275799 B -> 227143 B. Save: 48 KB.
Creating the list of files... Done
Creating md5sum of files... Done
Compressing the FS... Done
Updating receipt sizes... Done
Creating full cpio archive... Done
Restoring original package tree... Done
QA: checking for empty package... Done
=====================================================================================================
Package "pcsc-lite-2.3.3-x86_64.tazpkg" created
Summary for: pcsc-lite 2.3.3
=====================================================================================================
Source dir : 3.0M
Src file : pcsc-lite-2.3.3.tar.xz
Src size : 208.0K
Produced : 456.0K
Packed : 244.0K
Compressed : 64.8K
Files : 9
Cook time : 11s
Cook date : 2025-04-07 10:19
Host arch : x86_64
=====================================================================================================
Leaving aufs chroot...
Offline
Shann you're great! the trick worked for me too, even though I used meson for compiling
export LDFLAGS="$LDFLAGS -lpthread"
meson setup builddir -Dpolkit=false -Dlibsystemd=false -Dprefix=/usr
cd builddir
meson compile
Thanks a lot!
Offline
You're welcome 
For meson, i see new version need meson, and use same setup we have meson/ninja, but maybe we can only use meson for all compilation.
Offline
Pages: 1
[ Generated in 0.016 seconds, 7 queries executed - Memory usage: 1.54 MiB (Peak: 1.77 MiB) ]