All of lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH 1/2] python-watchdog: add support for uClibc
@ 2018-02-16 13:32 yegorslists at googlemail.com
  2018-02-16 13:32 ` [Buildroot] [PATCH 2/2] python-watchdog: add missing runtime dependency yegorslists at googlemail.com
                   ` (2 more replies)
  0 siblings, 3 replies; 8+ messages in thread
From: yegorslists at googlemail.com @ 2018-02-16 13:32 UTC (permalink / raw)
  To: buildroot

From: Yegor Yefremov <yegorslists@googlemail.com>

This patch fixes uClibc detection.

Signed-off-by: Yegor Yefremov <yegorslists@googlemail.com>
---
 ...dd-a-workaround-to-support-uClibc-library.patch | 43 ++++++++++++++++++++++
 1 file changed, 43 insertions(+)
 create mode 100644 package/python-watchdog/0001-Add-a-workaround-to-support-uClibc-library.patch

diff --git a/package/python-watchdog/0001-Add-a-workaround-to-support-uClibc-library.patch b/package/python-watchdog/0001-Add-a-workaround-to-support-uClibc-library.patch
new file mode 100644
index 0000000..c21e6cd
--- /dev/null
+++ b/package/python-watchdog/0001-Add-a-workaround-to-support-uClibc-library.patch
@@ -0,0 +1,43 @@
+From c3b3c4581b25d7e62f5c2ce1484133229d5e657a Mon Sep 17 00:00:00 2001
+From: Yegor Yefremov <yegorslists@googlemail.com>
+Date: Fri, 16 Feb 2018 13:26:23 +0100
+Subject: [PATCH] Add a workaround to support uClibc library
+
+uClibc based systems provide only libc.so.0 and libc.so.1
+symlinks.
+
+So try to find libc.so.0 if neither libc.so nor libc.so.6
+could be found.
+
+Signed-off-by: Yegor Yefremov <yegorslists@googlemail.com>
+---
+ src/watchdog/observers/inotify_c.py | 12 ++++++++++++
+ 1 file changed, 12 insertions(+)
+
+diff --git a/src/watchdog/observers/inotify_c.py b/src/watchdog/observers/inotify_c.py
+index 5f208b6..0dc7b50 100644
+--- a/src/watchdog/observers/inotify_c.py
++++ b/src/watchdog/observers/inotify_c.py
+@@ -45,7 +45,19 @@ def _load_libc():
+     try:
+         return ctypes.CDLL('libc.so')
+     except (OSError, IOError):
++        pass
++
++    try:
+         return ctypes.CDLL('libc.so.6')
++    except (OSError, IOError):
++        pass
++
++    # uClibc
++    try:
++        return ctypes.CDLL('libc.so.0')
++    except (OSError, IOError) as err:
++        raise err
++
+ 
+ libc = _load_libc()
+ 
+-- 
+2.1.4
+
-- 
2.1.4

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

* [Buildroot] [PATCH 2/2] python-watchdog: add missing runtime dependency
  2018-02-16 13:32 [Buildroot] [PATCH 1/2] python-watchdog: add support for uClibc yegorslists at googlemail.com
@ 2018-02-16 13:32 ` yegorslists at googlemail.com
  2018-04-28 21:37   ` Thomas Petazzoni
  2018-05-01  7:32   ` Peter Korsgaard
  2018-04-28 21:35 ` [Buildroot] [PATCH 1/2] python-watchdog: add support for uClibc Thomas Petazzoni
  2018-05-01  7:32 ` Peter Korsgaard
  2 siblings, 2 replies; 8+ messages in thread
From: yegorslists at googlemail.com @ 2018-02-16 13:32 UTC (permalink / raw)
  To: buildroot

From: Yegor Yefremov <yegorslists@googlemail.com>

Script watchmedo requires python-setuptools.

Signed-off-by: Yegor Yefremov <yegorslists@googlemail.com>
---
 package/python-watchdog/Config.in | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/package/python-watchdog/Config.in b/package/python-watchdog/Config.in
index e529089..18f569e 100644
--- a/package/python-watchdog/Config.in
+++ b/package/python-watchdog/Config.in
@@ -1,8 +1,9 @@
 config BR2_PACKAGE_PYTHON_WATCHDOG
 	bool "python-watchdog"
-	select BR2_PACKAGE_PYTHON_PYYAML
-	select BR2_PACKAGE_PYTHON_ARGH
-	select BR2_PACKAGE_PYTHON_PATHTOOLS
+	select BR2_PACKAGE_PYTHON_ARGH # runtime
+	select BR2_PACKAGE_PYTHON_PATHTOOLS # runtime
+	select BR2_PACKAGE_PYTHON_PYYAML # runtime
+	select BR2_PACKAGE_PYTHON_SETUPTOOLS # runtime
 	help
 	  Python API and shell utilities to monitor file system events.
 
-- 
2.1.4

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

* [Buildroot] [PATCH 1/2] python-watchdog: add support for uClibc
  2018-02-16 13:32 [Buildroot] [PATCH 1/2] python-watchdog: add support for uClibc yegorslists at googlemail.com
  2018-02-16 13:32 ` [Buildroot] [PATCH 2/2] python-watchdog: add missing runtime dependency yegorslists at googlemail.com
@ 2018-04-28 21:35 ` Thomas Petazzoni
  2018-04-29  8:52   ` Yegor Yefremov
  2018-05-01  7:32 ` Peter Korsgaard
  2 siblings, 1 reply; 8+ messages in thread
From: Thomas Petazzoni @ 2018-04-28 21:35 UTC (permalink / raw)
  To: buildroot

Hello,

On Fri, 16 Feb 2018 14:32:00 +0100, yegorslists at googlemail.com wrote:
> From: Yegor Yefremov <yegorslists@googlemail.com>
> 
> This patch fixes uClibc detection.
> 
> Signed-off-by: Yegor Yefremov <yegorslists@googlemail.com>
> ---
>  ...dd-a-workaround-to-support-uClibc-library.patch | 43 ++++++++++++++++++++++
>  1 file changed, 43 insertions(+)
>  create mode 100644 package/python-watchdog/0001-Add-a-workaround-to-support-uClibc-library.patch

Applied to master, thanks. Did you submit this patch upstream ?

Thomas
-- 
Thomas Petazzoni, CTO, Bootlin (formerly Free Electrons)
Embedded Linux and Kernel engineering
https://bootlin.com

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

* [Buildroot] [PATCH 2/2] python-watchdog: add missing runtime dependency
  2018-02-16 13:32 ` [Buildroot] [PATCH 2/2] python-watchdog: add missing runtime dependency yegorslists at googlemail.com
@ 2018-04-28 21:37   ` Thomas Petazzoni
  2018-04-29  9:00     ` Yegor Yefremov
  2018-05-01  7:32   ` Peter Korsgaard
  1 sibling, 1 reply; 8+ messages in thread
From: Thomas Petazzoni @ 2018-04-28 21:37 UTC (permalink / raw)
  To: buildroot

Hello,

On Fri, 16 Feb 2018 14:32:01 +0100, yegorslists at googlemail.com wrote:
> From: Yegor Yefremov <yegorslists@googlemail.com>
> 
> Script watchmedo requires python-setuptools.
> 
> Signed-off-by: Yegor Yefremov <yegorslists@googlemail.com>
> ---
>  package/python-watchdog/Config.in | 7 ++++---
>  1 file changed, 4 insertions(+), 3 deletions(-)
> 
> diff --git a/package/python-watchdog/Config.in b/package/python-watchdog/Config.in
> index e529089..18f569e 100644
> --- a/package/python-watchdog/Config.in
> +++ b/package/python-watchdog/Config.in
> @@ -1,8 +1,9 @@
>  config BR2_PACKAGE_PYTHON_WATCHDOG
>  	bool "python-watchdog"
> -	select BR2_PACKAGE_PYTHON_PYYAML
> -	select BR2_PACKAGE_PYTHON_ARGH
> -	select BR2_PACKAGE_PYTHON_PATHTOOLS
> +	select BR2_PACKAGE_PYTHON_ARGH # runtime
> +	select BR2_PACKAGE_PYTHON_PATHTOOLS # runtime
> +	select BR2_PACKAGE_PYTHON_PYYAML # runtime
> +	select BR2_PACKAGE_PYTHON_SETUPTOOLS # runtime

I applied, but since this dependency is only needed for the
watchmedo.py script, does it make sense to make this a mandatory
dependency ?

Also, skimming through the watchmedo.py script, I couldn't see what was
bringing this dependecny on setuptools. Could you enlighten me (it's
mainly for my own curiosity, I trust you when you said it was needed).

Applied, thanks!

Thomas
-- 
Thomas Petazzoni, CTO, Bootlin (formerly Free Electrons)
Embedded Linux and Kernel engineering
https://bootlin.com

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

* [Buildroot] [PATCH 1/2] python-watchdog: add support for uClibc
  2018-04-28 21:35 ` [Buildroot] [PATCH 1/2] python-watchdog: add support for uClibc Thomas Petazzoni
@ 2018-04-29  8:52   ` Yegor Yefremov
  0 siblings, 0 replies; 8+ messages in thread
From: Yegor Yefremov @ 2018-04-29  8:52 UTC (permalink / raw)
  To: buildroot

On Sat, Apr 28, 2018 at 11:35 PM, Thomas Petazzoni
<thomas.petazzoni@bootlin.com> wrote:
> Hello,
>
> On Fri, 16 Feb 2018 14:32:00 +0100, yegorslists at googlemail.com wrote:
>> From: Yegor Yefremov <yegorslists@googlemail.com>
>>
>> This patch fixes uClibc detection.
>>
>> Signed-off-by: Yegor Yefremov <yegorslists@googlemail.com>
>> ---
>>  ...dd-a-workaround-to-support-uClibc-library.patch | 43 ++++++++++++++++++++++
>>  1 file changed, 43 insertions(+)
>>  create mode 100644 package/python-watchdog/0001-Add-a-workaround-to-support-uClibc-library.patch
>
> Applied to master, thanks. Did you submit this patch upstream ?

I'll do this, but the project seems to be abandoned :-(

Yegor

> Thomas
> --
> Thomas Petazzoni, CTO, Bootlin (formerly Free Electrons)
> Embedded Linux and Kernel engineering
> https://bootlin.com

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

* [Buildroot] [PATCH 2/2] python-watchdog: add missing runtime dependency
  2018-04-28 21:37   ` Thomas Petazzoni
@ 2018-04-29  9:00     ` Yegor Yefremov
  0 siblings, 0 replies; 8+ messages in thread
From: Yegor Yefremov @ 2018-04-29  9:00 UTC (permalink / raw)
  To: buildroot

On Sat, Apr 28, 2018 at 11:37 PM, Thomas Petazzoni
<thomas.petazzoni@bootlin.com> wrote:
> Hello,
>
> On Fri, 16 Feb 2018 14:32:01 +0100, yegorslists at googlemail.com wrote:
>> From: Yegor Yefremov <yegorslists@googlemail.com>
>>
>> Script watchmedo requires python-setuptools.
>>
>> Signed-off-by: Yegor Yefremov <yegorslists@googlemail.com>
>> ---
>>  package/python-watchdog/Config.in | 7 ++++---
>>  1 file changed, 4 insertions(+), 3 deletions(-)
>>
>> diff --git a/package/python-watchdog/Config.in b/package/python-watchdog/Config.in
>> index e529089..18f569e 100644
>> --- a/package/python-watchdog/Config.in
>> +++ b/package/python-watchdog/Config.in
>> @@ -1,8 +1,9 @@
>>  config BR2_PACKAGE_PYTHON_WATCHDOG
>>       bool "python-watchdog"
>> -     select BR2_PACKAGE_PYTHON_PYYAML
>> -     select BR2_PACKAGE_PYTHON_ARGH
>> -     select BR2_PACKAGE_PYTHON_PATHTOOLS
>> +     select BR2_PACKAGE_PYTHON_ARGH # runtime
>> +     select BR2_PACKAGE_PYTHON_PATHTOOLS # runtime
>> +     select BR2_PACKAGE_PYTHON_PYYAML # runtime
>> +     select BR2_PACKAGE_PYTHON_SETUPTOOLS # runtime
>
> I applied, but since this dependency is only needed for the
> watchmedo.py script, does it make sense to make this a mandatory
> dependency ?

We make it already for some other packages like crossbar for example.

> Also, skimming through the watchmedo.py script, I couldn't see what was
> bringing this dependecny on setuptools. Could you enlighten me (it's
> mainly for my own curiosity, I trust you when you said it was needed).

The whole entry_points mechanism is described here:
https://stackoverflow.com/a/9615473/1113139
That's why setuptools package is needed on target.

Yegor

> Applied, thanks!
>
> Thomas
> --
> Thomas Petazzoni, CTO, Bootlin (formerly Free Electrons)
> Embedded Linux and Kernel engineering
> https://bootlin.com

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

* [Buildroot] [PATCH 1/2] python-watchdog: add support for uClibc
  2018-02-16 13:32 [Buildroot] [PATCH 1/2] python-watchdog: add support for uClibc yegorslists at googlemail.com
  2018-02-16 13:32 ` [Buildroot] [PATCH 2/2] python-watchdog: add missing runtime dependency yegorslists at googlemail.com
  2018-04-28 21:35 ` [Buildroot] [PATCH 1/2] python-watchdog: add support for uClibc Thomas Petazzoni
@ 2018-05-01  7:32 ` Peter Korsgaard
  2 siblings, 0 replies; 8+ messages in thread
From: Peter Korsgaard @ 2018-05-01  7:32 UTC (permalink / raw)
  To: buildroot

>>>>> "yegorslists" == yegorslists  <yegorslists@googlemail.com> writes:

 > From: Yegor Yefremov <yegorslists@googlemail.com>
 > This patch fixes uClibc detection.

 > Signed-off-by: Yegor Yefremov <yegorslists@googlemail.com>

Committed to 2018.02.x, thanks.

-- 
Bye, Peter Korsgaard

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

* [Buildroot] [PATCH 2/2] python-watchdog: add missing runtime dependency
  2018-02-16 13:32 ` [Buildroot] [PATCH 2/2] python-watchdog: add missing runtime dependency yegorslists at googlemail.com
  2018-04-28 21:37   ` Thomas Petazzoni
@ 2018-05-01  7:32   ` Peter Korsgaard
  1 sibling, 0 replies; 8+ messages in thread
From: Peter Korsgaard @ 2018-05-01  7:32 UTC (permalink / raw)
  To: buildroot

>>>>> "yegorslists" == yegorslists  <yegorslists@googlemail.com> writes:

 > From: Yegor Yefremov <yegorslists@googlemail.com>
 > Script watchmedo requires python-setuptools.

 > Signed-off-by: Yegor Yefremov <yegorslists@googlemail.com>

Committed to 2018.02.x, thanks.

-- 
Bye, Peter Korsgaard

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

end of thread, other threads:[~2018-05-01  7:32 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-02-16 13:32 [Buildroot] [PATCH 1/2] python-watchdog: add support for uClibc yegorslists at googlemail.com
2018-02-16 13:32 ` [Buildroot] [PATCH 2/2] python-watchdog: add missing runtime dependency yegorslists at googlemail.com
2018-04-28 21:37   ` Thomas Petazzoni
2018-04-29  9:00     ` Yegor Yefremov
2018-05-01  7:32   ` Peter Korsgaard
2018-04-28 21:35 ` [Buildroot] [PATCH 1/2] python-watchdog: add support for uClibc Thomas Petazzoni
2018-04-29  8:52   ` Yegor Yefremov
2018-05-01  7:32 ` Peter Korsgaard

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.