there is some option in mk.conf to change PTHREAD from native to pkgsrc- I am not sure but maybe this may help.
Piotr.
On Wed, Jul 21, 2010 at 9:22 AM, George Georgalis
<george%galis.org@localhost> wrote:
I'm looking into generating rpm packages for site installs from
pkgsrc builds. My first build of /usr/pkgsrc/pkgtools/genrpm went
without a hitch, until I realized NetBSD rpm packages would be
useless on a Linux system. So, I bootstrapped pkgsrc-2010Q2 on Linux
built a couple tools then went for genrpm. The error is below, I'm
guessing there is not an easy fix. This is a CentOS 5.5 system.
Is there a better way to make RPMs from pkgsrc for install on
Linux systems?
--George
gcc -I/usr/pkgsrc/misc/rpm/work/rpm-2.5.4 -I/usr/pkgsrc/misc/rpm/work/rpm-2.5.4 -Wno-error -Wno-format -fno-builtin -I/usr/include -I/usr/pkg/include -I/usr/pkg/include/db4 -DHAVE_CONFIG_H -I/usr/pkgsrc/misc/rpm/work/rpm-2.5.4/lib -I/usr/pkgsrc/misc/rpm/work/rpm-2.5.4/misc -I/usr/include -I/usr/pkg/include -I/usr/pkg/include/db4 -c -o build.o build.c
gcc -o rpm -static rpm.o query.o install.o verify.o checksig.o ftp.o url.o build.o -L/usr/lib64 -Wl,-R/usr/lib64 -Wl,-R/usr/pkg/lib -L/usr/pkgsrc/misc/rpm/work/rpm-2.5.4/lib -L/usr/pkgsrc/misc/rpm/work/rpm-2.5.4/build -L/usr/pkgsrc/misc/rpm/work/rpm-2.5.4/misc -lrpmbuild -lpopt -lrpm -ldb4 -lz \
/usr/pkgsrc/misc/rpm/work/rpm-2.5.4/lib/librpm.a(signature.o): In function `verifyPGPSignature':
signature.c:(.text+0x103b): warning: the use of `tempnam' is dangerous, better use `mkstemp'
/usr/pkgsrc/misc/rpm/work/rpm-2.5.4/build/librpmbuild.a(names.o): In function `getGname':
names.c:(.text+0x2ab): warning: Using 'getgrgid' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking
/usr/pkgsrc/misc/rpm/work/rpm-2.5.4/build/librpmbuild.a(names.o): In function `getGnameS':
names.c:(.text+0x3b5): warning: Using 'getgrnam' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking
/usr/pkgsrc/misc/rpm/work/rpm-2.5.4/lib/librpm.a(misc.o): In function `gnameToGid':
misc.c:(.text+0x894): warning: Using 'endgrent' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking
/usr/pkgsrc/misc/rpm/work/rpm-2.5.4/build/librpmbuild.a(names.o): In function `getUnameS':
names.c:(.text+0x18f): warning: Using 'getpwnam' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking
ftp.o: In function `ftpOpen':
ftp.c:(.text+0x8b5): warning: Using 'getpwuid' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking
/usr/pkgsrc/misc/rpm/work/rpm-2.5.4/lib/librpm.a(misc.o): In function `unameToUid':
misc.c:(.text+0x761): warning: Using 'endpwent' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking
/usr/pkgsrc/misc/rpm/work/.buildlink/lib/libdb4.a(os_addrinfo.o): In function `__os_getaddrinfo':
os_addrinfo.c:(.text+0x30): warning: Using 'getaddrinfo' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking
ftp.o: In function `mygethostbyname':
ftp.c:(.text+0x78e): warning: Using 'gethostbyname' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking
/usr/pkgsrc/misc/rpm/work/.buildlink/lib/libdb4.a(os_pid.o): In function `__os_id':
os_pid.c:(.text+0x49): undefined reference to `pthread_self'
/usr/pkgsrc/misc/rpm/work/.buildlink/lib/libdb4.a(os_yield.o): In function `__os_yield':
os_yield.c:(.text+0x6e): undefined reference to `pthread_yield'
/usr/pkgsrc/misc/rpm/work/.buildlink/lib/libdb4.a(repmgr_posix.o): In function `__repmgr_thread_start':
repmgr_posix.c:(.text+0x28): undefined reference to `pthread_attr_init'
repmgr_posix.c:(.text+0x7d): undefined reference to `pthread_attr_setstacksize'
repmgr_posix.c:(.text+0xc1): undefined reference to `pthread_create'
/usr/pkgsrc/misc/rpm/work/.buildlink/lib/libdb4.a(repmgr_posix.o): In function `__repmgr_thread_join':
repmgr_posix.c:(.text+0xe7): undefined reference to `pthread_join'
/usr/pkgsrc/misc/rpm/work/.buildlink/lib/libdb4.a(repmgr_posix.o): In function `__repmgr_wake_waiting_senders':
repmgr_posix.c:(.text+0x177): undefined reference to `pthread_cond_broadcast'
/usr/pkgsrc/misc/rpm/work/.buildlink/lib/libdb4.a(repmgr_posix.o): In function `__repmgr_await_ack':
repmgr_posix.c:(.text+0x203): undefined reference to `pthread_cond_timedwait'
repmgr_posix.c:(.text+0x223): undefined reference to `pthread_cond_wait'
/usr/pkgsrc/misc/rpm/work/.buildlink/lib/libdb4.a(repmgr_posix.o): In function `__repmgr_await_drain':
repmgr_posix.c:(.text+0x397): undefined reference to `pthread_cond_timedwait'
/usr/pkgsrc/misc/rpm/work/.buildlink/lib/libdb4.a(repmgr_posix.o): In function `__repmgr_alloc_cond':
repmgr_posix.c:(.text+0x410): undefined reference to `pthread_cond_init'
/usr/pkgsrc/misc/rpm/work/.buildlink/lib/libdb4.a(repmgr_posix.o): In function `__repmgr_free_cond':
repmgr_posix.c:(.text+0x427): undefined reference to `pthread_cond_destroy'
/usr/pkgsrc/misc/rpm/work/.buildlink/lib/libdb4.a(repmgr_posix.o): In function `__repmgr_create_mutex_pf':
repmgr_posix.c:(.text+0x46f): undefined reference to `pthread_mutex_init'
/usr/pkgsrc/misc/rpm/work/.buildlink/lib/libdb4.a(repmgr_posix.o): In function `__repmgr_destroy_mutex_pf':
repmgr_posix.c:(.text+0x486): undefined reference to `pthread_mutex_destroy'
/usr/pkgsrc/misc/rpm/work/.buildlink/lib/libdb4.a(repmgr_posix.o): In function `__repmgr_init':
repmgr_posix.c:(.text+0x58a): undefined reference to `pthread_cond_init'
repmgr_posix.c:(.text+0x5b3): undefined reference to `pthread_cond_init'
repmgr_posix.c:(.text+0x5d8): undefined reference to `pthread_cond_init'
repmgr_posix.c:(.text+0x64b): undefined reference to `pthread_cond_destroy'
repmgr_posix.c:(.text+0x661): undefined reference to `pthread_cond_destroy'
repmgr_posix.c:(.text+0x677): undefined reference to `pthread_cond_destroy'
/usr/pkgsrc/misc/rpm/work/.buildlink/lib/libdb4.a(repmgr_posix.o): In function `__repmgr_deinit':
repmgr_posix.c:(.text+0x6ef): undefined reference to `pthread_cond_destroy'
repmgr_posix.c:(.text+0x702): undefined reference to `pthread_cond_destroy'
/usr/pkgsrc/misc/rpm/work/.buildlink/lib/libdb4.a(repmgr_posix.o):repmgr_posix.c:(.text+0x727): more undefined references to `pthread_cond_destroy' follow
/usr/pkgsrc/misc/rpm/work/.buildlink/lib/libdb4.a(repmgr_posix.o): In function `__repmgr_lock_mutex':
repmgr_posix.c:(.text+0x7c6): undefined reference to `pthread_mutex_lock'
/usr/pkgsrc/misc/rpm/work/.buildlink/lib/libdb4.a(repmgr_posix.o): In function `__repmgr_unlock_mutex':
repmgr_posix.c:(.text+0x7dd): undefined reference to `pthread_mutex_unlock'
/usr/pkgsrc/misc/rpm/work/.buildlink/lib/libdb4.a(repmgr_posix.o): In function `__repmgr_signal':
repmgr_posix.c:(.text+0x7f4): undefined reference to `pthread_cond_broadcast'
/usr/pkgsrc/misc/rpm/work/.buildlink/lib/libdb4.a(repmgr_queue.o): In function `__repmgr_queue_get':
repmgr_queue.c:(.text+0xeb): undefined reference to `pthread_cond_wait'
/usr/pkgsrc/misc/rpm/work/.buildlink/lib/libdb4.a(repmgr_elect.o): In function `__repmgr_elect_main':
repmgr_elect.c:(.text+0x69e): undefined reference to `pthread_cond_timedwait'
/usr/lib/gcc/x86_64-redhat-linux/4.1.2/libgcc_eh.a(unwind-dw2-fde-glibc.o): In function `__deregister_frame_info_bases':
(.text+0x10bc): undefined reference to `pthread_mutex_lock'
/usr/lib/gcc/x86_64-redhat-linux/4.1.2/libgcc_eh.a(unwind-dw2-fde-glibc.o): In function `__deregister_frame_info_bases':
(.text+0x10cd): undefined reference to `pthread_mutex_unlock'
/usr/lib/gcc/x86_64-redhat-linux/4.1.2/libgcc_eh.a(unwind-dw2-fde-glibc.o): In function `__register_frame_info_table_bases':
(.text+0x117f): undefined reference to `pthread_mutex_lock'
/usr/lib/gcc/x86_64-redhat-linux/4.1.2/libgcc_eh.a(unwind-dw2-fde-glibc.o): In function `__register_frame_info_bases':
(.text+0x1238): undefined reference to `pthread_mutex_lock'
/usr/lib/gcc/x86_64-redhat-linux/4.1.2/libgcc_eh.a(unwind-dw2-fde-glibc.o): In function `_Unwind_Find_FDE':
(.text+0x14b6): undefined reference to `pthread_mutex_unlock'
/usr/lib/gcc/x86_64-redhat-linux/4.1.2/libgcc_eh.a(unwind-dw2-fde-glibc.o): In function `_Unwind_Find_FDE':
(.text+0x14c7): undefined reference to `pthread_mutex_lock'
/usr/lib/gcc/x86_64-redhat-linux/4.1.2/libgcc_eh.a(unwind-dw2-fde-glibc.o): In function `__register_frame_info_table_bases':
(.text+0x119e): undefined reference to `pthread_mutex_unlock'
/usr/lib/gcc/x86_64-redhat-linux/4.1.2/libgcc_eh.a(unwind-dw2-fde-glibc.o): In function `__register_frame_info_bases':
(.text+0x1257): undefined reference to `pthread_mutex_unlock'
collect2: ld returned 1 exit status
make: *** [rpm] Error 1
*** Error code 2
Stop.
bmake: stopped in /usr/pkgsrc/misc/rpm
*** Error code 1
Stop.
bmake: stopped in /usr/pkgsrc/misc/rpm
*** Error code 1
Stop.
bmake: stopped in /usr/pkgsrc/pkgtools/genrpm
zsh: 3143 exit 1 bmake install
[root@cos-100720]/usr/pkgsrc/pkgtools/genrpm#