Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH 1/2] package/janus-gateway: add libcurl optional dependency
@ 2023-01-14 17:01 Fabrice Fontaine
  2023-01-14 17:01 ` [Buildroot] [PATCH 2/2] package/janus-gateway: fix libcurl build Fabrice Fontaine
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Fabrice Fontaine @ 2023-01-14 17:01 UTC (permalink / raw)
  To: buildroot; +Cc: Gregory Dymarek, Fabrice Fontaine

libcurl is an optional dependency which is enabled by default since at
least version 0.0.9 and
https://github.com/meetecho/janus-gateway/commit/ca9c0a86f975f88fbdd791af3cb4f8986883c1c2

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
---
 package/janus-gateway/janus-gateway.mk | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/package/janus-gateway/janus-gateway.mk b/package/janus-gateway/janus-gateway.mk
index 0d906f1b62..dd898563e5 100644
--- a/package/janus-gateway/janus-gateway.mk
+++ b/package/janus-gateway/janus-gateway.mk
@@ -128,6 +128,13 @@ else
 JANUS_GATEWAY_CONF_OPTS += --disable-websockets
 endif
 
+ifeq ($(BR2_PACKAGE_LIBCURL),y)
+JANUS_GATEWAY_DEPENDENCIES += libcurl
+JANUS_GATEWAY_CONF_OPTS += --enable-turn-rest-api
+else
+JANUS_GATEWAY_CONF_OPTS += --disable-turn-rest-api
+endif
+
 ifeq ($(BR2_PACKAGE_SYSTEMD),y)
 JANUS_GATEWAY_DEPENDENCIES += systemd
 JANUS_GATEWAY_CONF_OPTS += --enable-systemd-sockets
-- 
2.39.0

_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

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

* [Buildroot] [PATCH 2/2] package/janus-gateway: fix libcurl build
  2023-01-14 17:01 [Buildroot] [PATCH 1/2] package/janus-gateway: add libcurl optional dependency Fabrice Fontaine
@ 2023-01-14 17:01 ` Fabrice Fontaine
  2023-01-14 20:08 ` [Buildroot] [PATCH 1/2] package/janus-gateway: add libcurl optional dependency Thomas Petazzoni via buildroot
  2023-01-16 14:40 ` Peter Korsgaard
  2 siblings, 0 replies; 4+ messages in thread
From: Fabrice Fontaine @ 2023-01-14 17:01 UTC (permalink / raw)
  To: buildroot; +Cc: Gregory Dymarek, Fabrice Fontaine

Fix the following libcurl build failure raised since bump to version
1.1.1 in commit 01518e5660366be41e6a8e0a0f2b487d7cdf48a2:

In file included from /home/autobuild/autobuild/instance-11/output-1/host/sparc64-buildroot-linux-gnu/sysroot/usr/include/curl/curl.h:3195,
                 from turnrest.c:21:
turnrest.c: In function 'janus_turnrest_request':
turnrest.c:168:2: error: void value not ignored as it ought to be
  168 |  curl_easy_setopt(curl, api_http_get ? CURLOPT_HTTPGET : CURLOPT_POST, 1);
      |  ^

Fixes:
 - http://autobuild.buildroot.org/results/11bb0079f5a7d06d3494a61b411f0af2e8c4d342

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
---
 ...se-parentheses-to-ensure-compilation.patch | 27 +++++++++++++++++++
 1 file changed, 27 insertions(+)
 create mode 100644 package/janus-gateway/0003-Use-parentheses-to-ensure-compilation.patch

diff --git a/package/janus-gateway/0003-Use-parentheses-to-ensure-compilation.patch b/package/janus-gateway/0003-Use-parentheses-to-ensure-compilation.patch
new file mode 100644
index 0000000000..f91c13d1f6
--- /dev/null
+++ b/package/janus-gateway/0003-Use-parentheses-to-ensure-compilation.patch
@@ -0,0 +1,27 @@
+From 51431c36cd5f2997c0f7723909195b9883ae0486 Mon Sep 17 00:00:00 2001
+From: Benson Muite <bkmgit@users.noreply.github.com>
+Date: Wed, 4 Jan 2023 13:33:36 +0300
+Subject: [PATCH] Use parentheses to ensure compilation (#3138)
+
+Compiler fails with latest Curl release. Use parenthesis to ensure compiler evaluates expression correctly.
+
+[Retrieved from:
+https://github.com/meetecho/janus-gateway/commit/51431c36cd5f2997c0f7723909195b9883ae0486]
+Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
+---
+ src/turnrest.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/src/turnrest.c b/src/turnrest.c
+index b8560d22f2..42e6114de8 100644
+--- a/src/turnrest.c
++++ b/src/turnrest.c
+@@ -165,7 +165,7 @@ janus_turnrest_response *janus_turnrest_request(const char *user) {
+ 	JANUS_LOG(LOG_VERB, "Sending request: %s\n", request_uri);
+ 	janus_mutex_unlock(&api_mutex);
+ 	curl_easy_setopt(curl, CURLOPT_URL, request_uri);
+-	curl_easy_setopt(curl, api_http_get ? CURLOPT_HTTPGET : CURLOPT_POST, 1);
++	curl_easy_setopt(curl, (api_http_get ? CURLOPT_HTTPGET : CURLOPT_POST), 1);
+ 	if(!api_http_get) {
+ 		/* FIXME Some servers don't like a POST with no data */
+ 		curl_easy_setopt(curl, CURLOPT_POSTFIELDS, query_string);
-- 
2.39.0

_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

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

* Re: [Buildroot] [PATCH 1/2] package/janus-gateway: add libcurl optional dependency
  2023-01-14 17:01 [Buildroot] [PATCH 1/2] package/janus-gateway: add libcurl optional dependency Fabrice Fontaine
  2023-01-14 17:01 ` [Buildroot] [PATCH 2/2] package/janus-gateway: fix libcurl build Fabrice Fontaine
@ 2023-01-14 20:08 ` Thomas Petazzoni via buildroot
  2023-01-16 14:40 ` Peter Korsgaard
  2 siblings, 0 replies; 4+ messages in thread
From: Thomas Petazzoni via buildroot @ 2023-01-14 20:08 UTC (permalink / raw)
  To: Fabrice Fontaine; +Cc: Gregory Dymarek, buildroot

On Sat, 14 Jan 2023 18:01:25 +0100
Fabrice Fontaine <fontaine.fabrice@gmail.com> wrote:

> libcurl is an optional dependency which is enabled by default since at
> least version 0.0.9 and
> https://github.com/meetecho/janus-gateway/commit/ca9c0a86f975f88fbdd791af3cb4f8986883c1c2
> 
> Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
> ---
>  package/janus-gateway/janus-gateway.mk | 7 +++++++
>  1 file changed, 7 insertions(+)

Both applied, thanks!

Thomas
-- 
Thomas Petazzoni, CTO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

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

* Re: [Buildroot] [PATCH 1/2] package/janus-gateway: add libcurl optional dependency
  2023-01-14 17:01 [Buildroot] [PATCH 1/2] package/janus-gateway: add libcurl optional dependency Fabrice Fontaine
  2023-01-14 17:01 ` [Buildroot] [PATCH 2/2] package/janus-gateway: fix libcurl build Fabrice Fontaine
  2023-01-14 20:08 ` [Buildroot] [PATCH 1/2] package/janus-gateway: add libcurl optional dependency Thomas Petazzoni via buildroot
@ 2023-01-16 14:40 ` Peter Korsgaard
  2 siblings, 0 replies; 4+ messages in thread
From: Peter Korsgaard @ 2023-01-16 14:40 UTC (permalink / raw)
  To: Fabrice Fontaine; +Cc: Gregory Dymarek, buildroot

>>>>> "Fabrice" == Fabrice Fontaine <fontaine.fabrice@gmail.com> writes:

 > libcurl is an optional dependency which is enabled by default since at
 > least version 0.0.9 and
 > https://github.com/meetecho/janus-gateway/commit/ca9c0a86f975f88fbdd791af3cb4f8986883c1c2

 > Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>

Committed to 2022.11.x and 2022.02.x, thanks.

-- 
Bye, Peter Korsgaard
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

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

end of thread, other threads:[~2023-01-16 14:41 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-01-14 17:01 [Buildroot] [PATCH 1/2] package/janus-gateway: add libcurl optional dependency Fabrice Fontaine
2023-01-14 17:01 ` [Buildroot] [PATCH 2/2] package/janus-gateway: fix libcurl build Fabrice Fontaine
2023-01-14 20:08 ` [Buildroot] [PATCH 1/2] package/janus-gateway: add libcurl optional dependency Thomas Petazzoni via buildroot
2023-01-16 14:40 ` Peter Korsgaard

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