Mirror of the lttng-dev mailing list
 help / color / mirror / Atom feed
From: mathieu.desnoyers@efficios.com (Mathieu Desnoyers)
Subject: [lttng-dev] [PATCH liburcu 2/5] Dont link pthread on Android
Date: Wed, 27 Nov 2013 16:10:37 +0000 (UTC)	[thread overview]
Message-ID: <164876968.76709.1385568637093.JavaMail.zimbra@efficios.com> (raw)
In-Reply-To: <1385567313-8138-2-git-send-email-charlesbriere.flatzo@gmail.com>

----- Original Message -----
> From: "Charles Briere" <charlesbriere.flatzo@gmail.com>
> To: "mathieu desnoyers" <mathieu.desnoyers at efficios.com>
> Cc: lttng-dev at lists.lttng.org, "Charles Briere" <charlesbriere.flatzo at gmail.com>
> Sent: Wednesday, November 27, 2013 10:48:30 AM
> Subject: [PATCH liburcu 2/5] Dont link pthread on Android
> 
> On Android, pthread is already part of libc
> called Bionic and doesn't have an external
> library to link with.
> 
> Signed-off-by: Charles Briere <charlesbriere.flatzo at gmail.com>
> ---
>  Makefile.am                  | 5 ++++-
>  tests/benchmark/Makefile.am  | 4 +++-
>  tests/regression/Makefile.am | 4 +++-
>  tests/unit/Makefile.am       | 4 +++-
>  4 files changed, 13 insertions(+), 4 deletions(-)
> 
> diff --git a/Makefile.am b/Makefile.am
> index e09778f..baac8b9 100644
> --- a/Makefile.am
> +++ b/Makefile.am
> @@ -4,7 +4,10 @@ INCLUDES = -I$(top_builddir)/urcu
>  
>  #Add the -version-info directly here since we are only building
>  # library that use the version-info
> -AM_LDFLAGS=-lpthread -version-info $(URCU_LIBRARY_VERSION)
> +AM_LDFLAGS=-version-info $(URCU_LIBRARY_VERSION)
> +if !TARGET_IS_ANDROID
> +AM_LDFLAGS += -lpthread
> +endif
>  AM_CFLAGS=-Wall
>  
>  SUBDIRS = . doc tests
> diff --git a/tests/benchmark/Makefile.am b/tests/benchmark/Makefile.am
> index e071034..91ba1da 100644
> --- a/tests/benchmark/Makefile.am
> +++ b/tests/benchmark/Makefile.am
> @@ -1,4 +1,6 @@
> -AM_LDFLAGS=-lpthread
> +if !TARGET_IS_ANDROID
> +AM_LDFLAGS += -lpthread

change = for += is triggering those warnings

./bootstrap 
+ [ ! -e config ]
+ autoreconf -i
tests/benchmark/Makefile.am:2: AM_LDFLAGS must be set with `=' before using `+='
tests/regression/Makefile.am:2: AM_LDFLAGS must be set with `=' before using `+='
tests/unit/Makefile.am:2: AM_LDFLAGS must be set with `=' before using `+='
autoreconf: automake failed with exit status: 1

Will fix in the patch myself.

Thanks,

Mathieu

> +endif
>  AM_CFLAGS=-I$(top_srcdir) -I$(top_builddir) -I$(top_srcdir)/tests/common -g
>  
>  noinst_PROGRAMS = test_urcu test_urcu_dynamic_link test_urcu_timing \
> diff --git a/tests/regression/Makefile.am b/tests/regression/Makefile.am
> index 2c0542f..2cefa33 100644
> --- a/tests/regression/Makefile.am
> +++ b/tests/regression/Makefile.am
> @@ -1,4 +1,6 @@
> -AM_LDFLAGS=-lpthread
> +if !TARGET_IS_ANDROID
> +AM_LDFLAGS += -lpthread
> +endif
>  AM_CFLAGS=-I$(top_srcdir) -I$(top_builddir) -I$(top_srcdir)/tests/common -g
>  
>  noinst_PROGRAMS = test_urcu_fork \
> diff --git a/tests/unit/Makefile.am b/tests/unit/Makefile.am
> index 1fa8b71..85860e2 100644
> --- a/tests/unit/Makefile.am
> +++ b/tests/unit/Makefile.am
> @@ -1,4 +1,6 @@
> -AM_LDFLAGS=-lpthread
> +if !TARGET_IS_ANDROID
> +AM_LDFLAGS += -lpthread
> +endif
>  AM_CFLAGS=-I$(top_srcdir) -I$(top_builddir) -I$(top_srcdir)/tests/common -g
>  
>  noinst_PROGRAMS = test_uatomic \
> --
> 1.8.4.2
> 
> 

-- 
Mathieu Desnoyers
EfficiOS Inc.
http://www.efficios.com



  reply	other threads:[~2013-11-27 16:10 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-11-27 15:48 [lttng-dev] [PATCH liburcu 1/5] configure.ac Android check Charles Briere
2013-11-27 15:48 ` [lttng-dev] [PATCH liburcu 2/5] Dont link pthread on Android Charles Briere
2013-11-27 16:10   ` Mathieu Desnoyers [this message]
2013-11-28  9:30   ` Thomas Petazzoni
2013-11-29  0:10     ` Charles Brière
2013-11-29  6:01       ` Mathieu Desnoyers
2013-11-27 15:48 ` [lttng-dev] [PATCH liburcu 3/5] Added a compat layer for 'syscall.h' Charles Briere
2013-11-27 16:29   ` Mathieu Desnoyers
2013-11-27 17:20     ` Charles Brière
2013-11-27 17:38       ` Mathieu Desnoyers
2013-11-27 15:48 ` [lttng-dev] [PATCH liburcu 4/5] Fix: Do not redefine gettid on Android Charles Briere
2013-11-27 16:09   ` Mathieu Desnoyers
2013-11-27 15:48 ` [lttng-dev] [PATCH liburcu 5/5] Added implementation for rand_r() Charles Briere
  -- strict thread matches above, loose matches on Subject: below --
2013-11-27  5:08 [lttng-dev] [PATCH liburcu 1/5] configure.ac Android check Charles Briere
2013-11-27  5:08 ` [lttng-dev] [PATCH liburcu 2/5] Dont link pthread on Android Charles Briere

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=164876968.76709.1385568637093.JavaMail.zimbra@efficios.com \
    --to=mathieu.desnoyers@efficios.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox