All of lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH 1/1] package/squeezelite: fix musl build
@ 2016-01-31 17:44 Bernd Kuhls
  2016-02-02 14:44 ` Arnout Vandecappelle
  2016-02-07 17:43 ` Thomas Petazzoni
  0 siblings, 2 replies; 3+ messages in thread
From: Bernd Kuhls @ 2016-01-31 17:44 UTC (permalink / raw)
  To: buildroot

The build error was not yet found by the autobuilders:

output_alsa.c: In function ?output_init_alsa?:
output_alsa.c:865:10: error: ?M_TRIM_THRESHOLD? undeclared (first use in this function)
  mallopt(M_TRIM_THRESHOLD, -1);
          ^
output_alsa.c:865:10: note: each undeclared identifier is reported only once for each function it appears in
output_alsa.c:866:10: error: ?M_MMAP_MAX? undeclared (first use in this function)
  mallopt(M_MMAP_MAX, 0);
          ^

Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>
---
 ...02-only-run-glibc-specific-hacks-on-glibc.patch | 30 ++++++++++++++++++++++
 1 file changed, 30 insertions(+)
 create mode 100644 package/squeezelite/0002-only-run-glibc-specific-hacks-on-glibc.patch

diff --git a/package/squeezelite/0002-only-run-glibc-specific-hacks-on-glibc.patch b/package/squeezelite/0002-only-run-glibc-specific-hacks-on-glibc.patch
new file mode 100644
index 0000000..12237e4
--- /dev/null
+++ b/package/squeezelite/0002-only-run-glibc-specific-hacks-on-glibc.patch
@@ -0,0 +1,30 @@
+From d898fac929cd093bb39af3f517158777c21c06ef Mon Sep 17 00:00:00 2001
+From: Carlo Landmeter <clandmeter@gmail.com>
+Date: Tue, 31 Mar 2015 10:07:14 +0000
+Subject: [PATCH] only run glibc specific hacks on glibc
+
+---
+Patch downloaded from upstream PR:
+https://github.com/robadenshi/squeezelite/issues/97
+
+Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>
+
+ output_alsa.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/output_alsa.c b/output_alsa.c
+index aa01560..c1b5435 100644
+--- a/output_alsa.c
++++ b/output_alsa.c
+@@ -853,7 +853,7 @@ void output_init_alsa(log_level level, const char *device, unsigned output_buf_s
+ 		set_mixer(output.device, volume_mixer_name, volume_mixer_index ? atoi(volume_mixer_index) : 0, true, 0, 0);
+ 	}
+ 
+-#if LINUX
++#if defined(__GLIBC__)
+ 	// RT linux - aim to avoid pagefaults by locking memory: 
+ 	// https://rt.wiki.kernel.org/index.php/Threaded_RT-application_with_memory_locking_and_stack_handling_example
+ 	if (mlockall(MCL_CURRENT | MCL_FUTURE) == -1) {
+-- 
+2.3.4
+
-- 
2.7.0

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* [Buildroot] [PATCH 1/1] package/squeezelite: fix musl build
  2016-01-31 17:44 [Buildroot] [PATCH 1/1] package/squeezelite: fix musl build Bernd Kuhls
@ 2016-02-02 14:44 ` Arnout Vandecappelle
  2016-02-07 17:43 ` Thomas Petazzoni
  1 sibling, 0 replies; 3+ messages in thread
From: Arnout Vandecappelle @ 2016-02-02 14:44 UTC (permalink / raw)
  To: buildroot

On 31-01-16 18:44, Bernd Kuhls wrote:
> The build error was not yet found by the autobuilders:
> 
> output_alsa.c: In function ?output_init_alsa?:
> output_alsa.c:865:10: error: ?M_TRIM_THRESHOLD? undeclared (first use in this function)
>   mallopt(M_TRIM_THRESHOLD, -1);
>           ^
> output_alsa.c:865:10: note: each undeclared identifier is reported only once for each function it appears in
> output_alsa.c:866:10: error: ?M_MMAP_MAX? undeclared (first use in this function)
>   mallopt(M_MMAP_MAX, 0);
>           ^
> 
> Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>
> ---
>  ...02-only-run-glibc-specific-hacks-on-glibc.patch | 30 ++++++++++++++++++++++
>  1 file changed, 30 insertions(+)
>  create mode 100644 package/squeezelite/0002-only-run-glibc-specific-hacks-on-glibc.patch
> 
> diff --git a/package/squeezelite/0002-only-run-glibc-specific-hacks-on-glibc.patch b/package/squeezelite/0002-only-run-glibc-specific-hacks-on-glibc.patch
> new file mode 100644
> index 0000000..12237e4
> --- /dev/null
> +++ b/package/squeezelite/0002-only-run-glibc-specific-hacks-on-glibc.patch
> @@ -0,0 +1,30 @@
> +From d898fac929cd093bb39af3f517158777c21c06ef Mon Sep 17 00:00:00 2001
> +From: Carlo Landmeter <clandmeter@gmail.com>
> +Date: Tue, 31 Mar 2015 10:07:14 +0000
> +Subject: [PATCH] only run glibc specific hacks on glibc
> +
> +---
> +Patch downloaded from upstream PR:
> +https://github.com/robadenshi/squeezelite/issues/97
> +
> +Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>
> +
> + output_alsa.c | 2 +-
> + 1 file changed, 1 insertion(+), 1 deletion(-)
> +
> +diff --git a/output_alsa.c b/output_alsa.c
> +index aa01560..c1b5435 100644
> +--- a/output_alsa.c
> ++++ b/output_alsa.c
> +@@ -853,7 +853,7 @@ void output_init_alsa(log_level level, const char *device, unsigned output_buf_s
> + 		set_mixer(output.device, volume_mixer_name, volume_mixer_index ? atoi(volume_mixer_index) : 0, true, 0, 0);
> + 	}
> + 
> +-#if LINUX
> ++#if defined(__GLIBC__)
> + 	// RT linux - aim to avoid pagefaults by locking memory: 
> + 	// https://rt.wiki.kernel.org/index.php/Threaded_RT-application_with_memory_locking_and_stack_handling_example
> + 	if (mlockall(MCL_CURRENT | MCL_FUTURE) == -1) {

 This doesn't look right - you still want to do the mlockall even on musl, no?

 Regards,
 Arnout

> +-- 
> +2.3.4
> +
> 


-- 
Arnout Vandecappelle                          arnout at mind be
Senior Embedded Software Architect            +32-16-286500
Essensium/Mind                                http://www.mind.be
G.Geenslaan 9, 3001 Leuven, Belgium           BE 872 984 063 RPR Leuven
LinkedIn profile: http://www.linkedin.com/in/arnoutvandecappelle
GPG fingerprint:  7493 020B C7E3 8618 8DEC 222C 82EB F404 F9AC 0DDF

^ permalink raw reply	[flat|nested] 3+ messages in thread

* [Buildroot] [PATCH 1/1] package/squeezelite: fix musl build
  2016-01-31 17:44 [Buildroot] [PATCH 1/1] package/squeezelite: fix musl build Bernd Kuhls
  2016-02-02 14:44 ` Arnout Vandecappelle
@ 2016-02-07 17:43 ` Thomas Petazzoni
  1 sibling, 0 replies; 3+ messages in thread
From: Thomas Petazzoni @ 2016-02-07 17:43 UTC (permalink / raw)
  To: buildroot

Dear Bernd Kuhls,

On Sun, 31 Jan 2016 18:44:07 +0100, Bernd Kuhls wrote:
> The build error was not yet found by the autobuilders:
> 
> output_alsa.c: In function ?output_init_alsa?:
> output_alsa.c:865:10: error: ?M_TRIM_THRESHOLD? undeclared (first use in this function)
>   mallopt(M_TRIM_THRESHOLD, -1);
>           ^
> output_alsa.c:865:10: note: each undeclared identifier is reported only once for each function it appears in
> output_alsa.c:866:10: error: ?M_MMAP_MAX? undeclared (first use in this function)
>   mallopt(M_MMAP_MAX, 0);
>           ^
> 
> Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>
> ---
>  ...02-only-run-glibc-specific-hacks-on-glibc.patch | 30 ++++++++++++++++++++++
>  1 file changed, 30 insertions(+)
>  create mode 100644 package/squeezelite/0002-only-run-glibc-specific-hacks-on-glibc.patch

Applied with some changes:

    [Thomas: only enclose the mallopt() call in __GLIBC__, use Git to
    format the patch, improve the commit log.]

Thanks!

Thomas
-- 
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2016-02-07 17:43 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-01-31 17:44 [Buildroot] [PATCH 1/1] package/squeezelite: fix musl build Bernd Kuhls
2016-02-02 14:44 ` Arnout Vandecappelle
2016-02-07 17:43 ` Thomas Petazzoni

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.