1
program="libpthread_workqueue"
5
abi_version="$abi_major.$abi_minor"
6
cflags="-Wall -Wextra -Werror -D_XOPEN_SOURCE=600 -D__EXTENSIONS__ -D_GNU_SOURCE -std=c99 -I./include -I./src"
7
ldflags="-lpthread -lrt"
8
sources='src/api.c src/$(API)/manager.c src/$(API)/thread_info.c src/witem_cache.c src/$(API)/thread_rt.c'
11
mans="pthread_workqueue.3"
12
headers="include/pthread_workqueue.h"
17
pkg_summary="pthread_workqueue library"
18
pkg_description="pthread_workqueue library"
22
pre_configure_hook() {
23
if [ "$debug" = "yes" ] ; then
24
cflags="$cflags -g3 -O0 -DPTHREAD_WORKQUEUE_DEBUG -rdynamic"
26
cflags="$cflags -g -O2"
31
post_configure_hook() {
36
cflags="$cflags -mthreads"
37
ldflags="$ldflags -mthreads"
40
# TODO: would like to have -fvisibility=hidden but not supported
43
cflags="$cflags -m64 -fpic"
44
ldflags="$ldflags -m64 -fpic -lumem"
47
if [ "`uname -m`" = "x86_64" ] ; then
52
cflags="$cflags $arch_flags -fpic -fvisibility=hidden -pthread"
53
ldflags="$ldflags $arch_flags -fpic -pthread"