Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH] openal: New package
@ 2015-10-03 17:21 André Hentschel
  2015-10-04  8:12 ` Bernd Kuhls
  0 siblings, 1 reply; 6+ messages in thread
From: André Hentschel @ 2015-10-03 17:21 UTC (permalink / raw)
  To: buildroot

Signed-off-by: Andr?? Hentschel <nerv@dawncrow.de>
---
 package/Config.in          |  1 +
 package/openal/Config.in   | 16 ++++++++++++++++
 package/openal/openal.hash |  2 ++
 package/openal/openal.mk   | 26 ++++++++++++++++++++++++++
 4 files changed, 45 insertions(+)
 create mode 100644 package/openal/Config.in
 create mode 100644 package/openal/openal.hash
 create mode 100644 package/openal/openal.mk

diff --git a/package/Config.in b/package/Config.in
index 79cbbe6..6d15dd1 100644
--- a/package/Config.in
+++ b/package/Config.in
@@ -722,6 +722,7 @@ menu "Audio/Sound"
 	source "package/opencore-amr/Config.in"
 	source "package/opus/Config.in"
 	source "package/opusfile/Config.in"
+	source "package/openal/Config.in"
 	source "package/portaudio/Config.in"
 	source "package/speex/Config.in"
 	source "package/taglib/Config.in"
diff --git a/package/openal/Config.in b/package/openal/Config.in
new file mode 100644
index 0000000..8eb177b
--- /dev/null
+++ b/package/openal/Config.in
@@ -0,0 +1,16 @@
+config BR2_PACKAGE_OPENAL
+	bool "openal"
+	# OpenAL needs a backend
+	depends on BR2_PACKAGE_ALSA_LIB || \
+	           BR2_PACKAGE_PORTAUDIO || \
+	           BR2_PACKAGE_PULSEAUDIO
+	help
+	  OpenAL provides capabilities for playing audio in a virtual
+	  3D environment. Distance attenuation, doppler shift, and
+	  directional sound emitters are among the features handled by
+	  the API.
+
+comment "openal needs a backend"
+	depends on !BR2_PACKAGE_ALSA_LIB && \
+	           !BR2_PACKAGE_PORTAUDIO && \
+	           !BR2_PACKAGE_PULSEAUDIO
diff --git a/package/openal/openal.hash b/package/openal/openal.hash
new file mode 100644
index 0000000..b28b2e2
--- /dev/null
+++ b/package/openal/openal.hash
@@ -0,0 +1,2 @@
+# Locally calculated
+sha256	2f3dcd313fe26391284fbf8596863723f99c65d6c6846dccb48e79cadaf40d5f  openal-soft-1.16.0.tar.bz2
diff --git a/package/openal/openal.mk b/package/openal/openal.mk
new file mode 100644
index 0000000..a67d675
--- /dev/null
+++ b/package/openal/openal.mk
@@ -0,0 +1,26 @@
+################################################################################
+#
+# openal
+#
+################################################################################
+
+OPENAL_VERSION = 1.16.0
+OPENAL_SOURCE = openal-soft-$(OPENAL_VERSION).tar.bz2
+OPENAL_SITE = http://kcat.strangesoft.net/openal-releases/
+OPENAL_LICENSE = LGPL
+OPENAL_LICENSE_FILES = COPYING
+OPENAL_INSTALL_STAGING = YES
+
+ifeq ($(BR2_PACKAGE_ALSA_LIB),y)
+OPENAL_DEPENDENCIES += alsa-lib
+endif
+
+ifeq ($(BR2_PACKAGE_PORTAUDIO),y)
+OPENAL_DEPENDENCIES += portaudio
+endif
+
+ifeq ($(BR2_PACKAGE_PULSEAUDIO),y)
+OPENAL_DEPENDENCIES += pulseaudio
+endif
+
+$(eval $(cmake-package))
-- 
1.9.1

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

* [Buildroot] [PATCH] openal: New package
  2015-10-03 17:21 [Buildroot] [PATCH] openal: New package André Hentschel
@ 2015-10-04  8:12 ` Bernd Kuhls
  2015-10-04 17:04   ` André Hentschel
  0 siblings, 1 reply; 6+ messages in thread
From: Bernd Kuhls @ 2015-10-04  8:12 UTC (permalink / raw)
  To: buildroot

Hi Andr?,

several months ago I started hacking an openal package myself but
never finished it. Here I will compare my package to your version.

Am Sat, 03 Oct 2015 19:21:53 +0200 schrieb Andr? Hentschel:

> diff --git a/package/openal/Config.in b/package/openal/Config.in
> new file mode 100644
> index 0000000..8eb177b
> --- /dev/null
> +++ b/package/openal/Config.in
> @@ -0,0 +1,16 @@
> +config BR2_PACKAGE_OPENAL
> +	bool "openal"
> +	# OpenAL needs a backend
> +	depends on BR2_PACKAGE_ALSA_LIB || \
> +	           BR2_PACKAGE_PORTAUDIO || \
> +	           BR2_PACKAGE_PULSEAUDIO
> +	help
> +	  OpenAL provides capabilities for playing audio in a virtual
> +	  3D environment. Distance attenuation, doppler shift, and
> +	  directional sound emitters are among the features handled by
> +	  the API.
> +
> +comment "openal needs a backend"
> +	depends on !BR2_PACKAGE_ALSA_LIB && \
> +	           !BR2_PACKAGE_PORTAUDIO && \
> +	           !BR2_PACKAGE_PULSEAUDIO

What about having a choice option defaulting to, for example, alsa?

Please add

	http://kcat.strangesoft.net/openal.html

to Config.in. Openal also needs this

	depends on BR2_TOOLCHAIN_HAS_THREADS

	comment "openal needs a toolchain w/ threads"
		depends on !BR2_TOOLCHAIN_HAS_THREADS

Did you test a static build? I have this in openal.mk:

ifeq ($(BR2_STATIC_LIBS),y)
OPENAL_CONF_OPTS += -DLIBTYPE=STATIC
endif

Regards, Bernd

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

* [Buildroot] [PATCH] openal: New package
  2015-10-04  8:12 ` Bernd Kuhls
@ 2015-10-04 17:04   ` André Hentschel
  0 siblings, 0 replies; 6+ messages in thread
From: André Hentschel @ 2015-10-04 17:04 UTC (permalink / raw)
  To: buildroot

Am 04.10.2015 um 10:12 schrieb Bernd Kuhls:
> Hi Andr?,
> 
> several months ago I started hacking an openal package myself but
> never finished it. Here I will compare my package to your version.
> 
> Am Sat, 03 Oct 2015 19:21:53 +0200 schrieb Andr? Hentschel:
> 
>> diff --git a/package/openal/Config.in b/package/openal/Config.in
>> new file mode 100644
>> index 0000000..8eb177b
>> --- /dev/null
>> +++ b/package/openal/Config.in
>> @@ -0,0 +1,16 @@
>> +config BR2_PACKAGE_OPENAL
>> +	bool "openal"
>> +	# OpenAL needs a backend
>> +	depends on BR2_PACKAGE_ALSA_LIB || \
>> +	           BR2_PACKAGE_PORTAUDIO || \
>> +	           BR2_PACKAGE_PULSEAUDIO
>> +	help
>> +	  OpenAL provides capabilities for playing audio in a virtual
>> +	  3D environment. Distance attenuation, doppler shift, and
>> +	  directional sound emitters are among the features handled by
>> +	  the API.
>> +
>> +comment "openal needs a backend"
>> +	depends on !BR2_PACKAGE_ALSA_LIB && \
>> +	           !BR2_PACKAGE_PORTAUDIO && \
>> +	           !BR2_PACKAGE_PULSEAUDIO
> 
> What about having a choice option defaulting to, for example, alsa?

I'll think about it

> Please add
> 
> 	http://kcat.strangesoft.net/openal.html

Done locally

> to Config.in. Openal also needs this
> 
> 	depends on BR2_TOOLCHAIN_HAS_THREADS
> 
> 	comment "openal needs a toolchain w/ threads"
> 		depends on !BR2_TOOLCHAIN_HAS_THREADS
> 
> Did you test a static build? I have this in openal.mk:
> 
> ifeq ($(BR2_STATIC_LIBS),y)
> OPENAL_CONF_OPTS += -DLIBTYPE=STATIC
> endif

Done that locally, thanks.
I'll reiterate in a week hopefully.
Thank you very much for the comments!

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

* [Buildroot] [PATCH] openal: New package
@ 2015-10-12 19:32 André Hentschel
  2015-10-12 19:47 ` Thomas Petazzoni
  2015-10-13 17:07 ` Vicente Olivert Riera
  0 siblings, 2 replies; 6+ messages in thread
From: André Hentschel @ 2015-10-12 19:32 UTC (permalink / raw)
  To: buildroot

Signed-off-by: Andr?? Hentschel <nerv@dawncrow.de>
---

Tested on various archs and toolchains (uclibc, glibc, musl, extern, intern)

 package/Config.in          |  1 +
 package/openal/Config.in   | 18 ++++++++++++++++++
 package/openal/openal.hash |  2 ++
 package/openal/openal.mk   | 30 ++++++++++++++++++++++++++++++
 4 files changed, 51 insertions(+)
 create mode 100644 package/openal/Config.in
 create mode 100644 package/openal/openal.hash
 create mode 100644 package/openal/openal.mk

diff --git a/package/Config.in b/package/Config.in
index 37d9cd0..767cb29 100644
--- a/package/Config.in
+++ b/package/Config.in
@@ -722,6 +722,7 @@ menu "Audio/Sound"
 	source "package/opencore-amr/Config.in"
 	source "package/opus/Config.in"
 	source "package/opusfile/Config.in"
+	source "package/openal/Config.in"
 	source "package/portaudio/Config.in"
 	source "package/speex/Config.in"
 	source "package/taglib/Config.in"
diff --git a/package/openal/Config.in b/package/openal/Config.in
new file mode 100644
index 0000000..0bbbb37
--- /dev/null
+++ b/package/openal/Config.in
@@ -0,0 +1,18 @@
+config BR2_PACKAGE_OPENAL
+	bool "openal"
+	# OpenAL needs a backend
+	depends on BR2_PACKAGE_ALSA_LIB || \
+	           BR2_PACKAGE_PORTAUDIO || \
+	           BR2_PACKAGE_PULSEAUDIO
+	help
+	  OpenAL provides capabilities for playing audio in a virtual
+	  3D environment. Distance attenuation, doppler shift, and
+	  directional sound emitters are among the features handled by
+	  the API.
+
+	  http://kcat.strangesoft.net/openal.html
+
+comment "openal needs a backend"
+	depends on !BR2_PACKAGE_ALSA_LIB && \
+	           !BR2_PACKAGE_PORTAUDIO && \
+	           !BR2_PACKAGE_PULSEAUDIO
diff --git a/package/openal/openal.hash b/package/openal/openal.hash
new file mode 100644
index 0000000..b28b2e2
--- /dev/null
+++ b/package/openal/openal.hash
@@ -0,0 +1,2 @@
+# Locally calculated
+sha256	2f3dcd313fe26391284fbf8596863723f99c65d6c6846dccb48e79cadaf40d5f  openal-soft-1.16.0.tar.bz2
diff --git a/package/openal/openal.mk b/package/openal/openal.mk
new file mode 100644
index 0000000..0c6a7cb
--- /dev/null
+++ b/package/openal/openal.mk
@@ -0,0 +1,30 @@
+################################################################################
+#
+# openal
+#
+################################################################################
+
+OPENAL_VERSION = 1.16.0
+OPENAL_SOURCE = openal-soft-$(OPENAL_VERSION).tar.bz2
+OPENAL_SITE = http://kcat.strangesoft.net/openal-releases
+OPENAL_LICENSE = LGPL
+OPENAL_LICENSE_FILES = COPYING
+OPENAL_INSTALL_STAGING = YES
+
+ifeq ($(BR2_PACKAGE_ALSA_LIB),y)
+OPENAL_DEPENDENCIES += alsa-lib
+endif
+
+ifeq ($(BR2_PACKAGE_PORTAUDIO),y)
+OPENAL_DEPENDENCIES += portaudio
+endif
+
+ifeq ($(BR2_PACKAGE_PULSEAUDIO),y)
+OPENAL_DEPENDENCIES += pulseaudio
+endif
+
+ifeq ($(BR2_STATIC_LIBS),y)
+OPENAL_CONF_OPTS += -DLIBTYPE=STATIC
+endif
+
+$(eval $(cmake-package))
-- 
1.9.1

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

* [Buildroot] [PATCH] openal: New package
  2015-10-12 19:32 André Hentschel
@ 2015-10-12 19:47 ` Thomas Petazzoni
  2015-10-13 17:07 ` Vicente Olivert Riera
  1 sibling, 0 replies; 6+ messages in thread
From: Thomas Petazzoni @ 2015-10-12 19:47 UTC (permalink / raw)
  To: buildroot

Dear Andr? Hentschel,

Thanks for this patch! It looks pretty good, but I have some comments
(see below).

On Mon, 12 Oct 2015 21:32:32 +0200, Andr? Hentschel wrote:
> Signed-off-by: Andr?? Hentschel <nerv@dawncrow.de>

It seems like you have an UTF-8 configuration issue somewhere, since
this ? got messed up into ??.

> diff --git a/package/openal/Config.in b/package/openal/Config.in
> new file mode 100644
> index 0000000..0bbbb37
> --- /dev/null
> +++ b/package/openal/Config.in
> @@ -0,0 +1,18 @@
> +config BR2_PACKAGE_OPENAL
> +	bool "openal"
> +	# OpenAL needs a backend
> +	depends on BR2_PACKAGE_ALSA_LIB || \
> +	           BR2_PACKAGE_PORTAUDIO || \
> +	           BR2_PACKAGE_PULSEAUDIO

I think in this case, we like when at least one backend is
automatically selected. alsa-lib seems to be the simplest one, so:

	select BR2_PACKAGE_ALSA_LIB if !BR2_PACKAGE_PORTAUDIO && !BR2_PACKAGE_PULSEAUDIO
	depends on BR2_TOOLCHAIN_HAS_THREADS # alsa-lib

> +	help
> +	  OpenAL provides capabilities for playing audio in a virtual
> +	  3D environment. Distance attenuation, doppler shift, and
> +	  directional sound emitters are among the features handled by
> +	  the API.
> +
> +	  http://kcat.strangesoft.net/openal.html
> +
> +comment "openal needs a backend"
> +	depends on !BR2_PACKAGE_ALSA_LIB && \
> +	           !BR2_PACKAGE_PORTAUDIO && \
> +	           !BR2_PACKAGE_PULSEAUDIO

Replace this with:

comment "openal needs a toolchain w/ threads"
	depends on !BR2_TOOLCHAIN_HAS_THREADS

> diff --git a/package/openal/openal.hash b/package/openal/openal.hash
> new file mode 100644
> index 0000000..b28b2e2
> --- /dev/null
> +++ b/package/openal/openal.hash
> @@ -0,0 +1,2 @@
> +# Locally calculated
> +sha256	2f3dcd313fe26391284fbf8596863723f99c65d6c6846dccb48e79cadaf40d5f  openal-soft-1.16.0.tar.bz2
> diff --git a/package/openal/openal.mk b/package/openal/openal.mk
> new file mode 100644
> index 0000000..0c6a7cb
> --- /dev/null
> +++ b/package/openal/openal.mk
> @@ -0,0 +1,30 @@
> +################################################################################
> +#
> +# openal
> +#
> +################################################################################
> +
> +OPENAL_VERSION = 1.16.0
> +OPENAL_SOURCE = openal-soft-$(OPENAL_VERSION).tar.bz2
> +OPENAL_SITE = http://kcat.strangesoft.net/openal-releases
> +OPENAL_LICENSE = LGPL

This should be LGPLv2+.

> +OPENAL_LICENSE_FILES = COPYING
> +OPENAL_INSTALL_STAGING = YES
> +
> +ifeq ($(BR2_PACKAGE_ALSA_LIB),y)
> +OPENAL_DEPENDENCIES += alsa-lib

Maybe:

OPENAL_CONF_OPTS += -DALSOFT_REQUIRE_ALSA=ON
else
OPENAL_CONF_OPTS += -DALSOFT_REQUIRE_ALSA=OFF

> +endif
> +
> +ifeq ($(BR2_PACKAGE_PORTAUDIO),y)
> +OPENAL_DEPENDENCIES += portaudio

ditto.

> +endif
> +
> +ifeq ($(BR2_PACKAGE_PULSEAUDIO),y)
> +OPENAL_DEPENDENCIES += pulseaudio

ditto.

This way, if it can't find Alsa even if we enabled it, we'll get an
error.

Could you fix those minor issues and send an updated version of your
patch?

Thanks!

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

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

* [Buildroot] [PATCH] openal: New package
  2015-10-12 19:32 André Hentschel
  2015-10-12 19:47 ` Thomas Petazzoni
@ 2015-10-13 17:07 ` Vicente Olivert Riera
  1 sibling, 0 replies; 6+ messages in thread
From: Vicente Olivert Riera @ 2015-10-13 17:07 UTC (permalink / raw)
  To: buildroot

Dear Andr? Hentschel,

thanks for your contribution. Your patch has one more issue apart from
the ones highlighted by Thomas. Please keep reading.

On 10/12/2015 08:32 PM, Andr? Hentschel wrote:
[snip]
> diff --git a/package/Config.in b/package/Config.in
> index 37d9cd0..767cb29 100644
> --- a/package/Config.in
> +++ b/package/Config.in
> @@ -722,6 +722,7 @@ menu "Audio/Sound"
>  	source "package/opencore-amr/Config.in"
>  	source "package/opus/Config.in"
>  	source "package/opusfile/Config.in"
> +	source "package/openal/Config.in"

This list of packages is alphabetically ordered, therefore openal should
be higher. Please include that fix as well in the next version of your
patch.

Also remember to add the version number to the subject-prefix of your
patch, and provide a changelog between versions. This is explained here:

http://buildroot.org/downloads/manual/manual.html#submitting-patches
"21.5.2. Patch revision changelog"

Regards,

Vincent.

>  	source "package/portaudio/Config.in"
>  	source "package/speex/Config.in"
>  	source "package/taglib/Config.in"
[snip]

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

end of thread, other threads:[~2015-10-13 17:07 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-10-03 17:21 [Buildroot] [PATCH] openal: New package André Hentschel
2015-10-04  8:12 ` Bernd Kuhls
2015-10-04 17:04   ` André Hentschel
  -- strict thread matches above, loose matches on Subject: below --
2015-10-12 19:32 André Hentschel
2015-10-12 19:47 ` Thomas Petazzoni
2015-10-13 17:07 ` Vicente Olivert Riera

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox