diff mbox series

package/python-xmodem: new package

Message ID 20200430132020.2476465-1-m.niestroj@grinn-global.com
State Superseded
Headers show
Series package/python-xmodem: new package | expand

Commit Message

Marcin Niestrój April 30, 2020, 1:20 p.m. UTC
Signed-off-by: Marcin Niestroj <m.niestroj@grinn-global.com>
---
 DEVELOPERS                               |  1 +
 package/Config.in                        |  1 +
 package/python-xmodem/Config.in          |  6 ++++++
 package/python-xmodem/python-xmodem.hash |  3 +++
 package/python-xmodem/python-xmodem.mk   | 13 +++++++++++++
 5 files changed, 24 insertions(+)
 create mode 100644 package/python-xmodem/Config.in
 create mode 100644 package/python-xmodem/python-xmodem.hash
 create mode 100644 package/python-xmodem/python-xmodem.mk

Comments

Marcin Niestrój April 30, 2020, 1:28 p.m. UTC | #1
Hi All!

The problem with this package is that there is no license file when we
download from pypi. But there is one on github. Question is: what should
we do about it?

Marcin Niestroj <m.niestroj@grinn-global.com> writes:

> Signed-off-by: Marcin Niestroj <m.niestroj@grinn-global.com>
> ---
>  DEVELOPERS                               |  1 +
>  package/Config.in                        |  1 +
>  package/python-xmodem/Config.in          |  6 ++++++
>  package/python-xmodem/python-xmodem.hash |  3 +++
>  package/python-xmodem/python-xmodem.mk   | 13 +++++++++++++
>  5 files changed, 24 insertions(+)
>  create mode 100644 package/python-xmodem/Config.in
>  create mode 100644 package/python-xmodem/python-xmodem.hash
>  create mode 100644 package/python-xmodem/python-xmodem.mk
>
> [snip]
Asaf Kahlon May 2, 2020, 7:54 a.m. UTC | #2
Hello,

On Thu, Apr 30, 2020 at 4:28 PM Marcin Niestrój
<m.niestroj@grinn-global.com> wrote:
>
> Hi All!
>
> The problem with this package is that there is no license file when we
> download from pypi. But there is one on github. Question is: what should
> we do about it?

We already have some python packages which don't include the license
on the tarball, although it exists in the repo.
Most of the times, it's because the maintainer of the package didn't add
the license file in MANIFEST.in (which seems to be your case too).
On those cases, PKG-INFO is mostly used, but it's not the preferred
solution, so I suggest to send a PR for adding the license to
MANIFEST.in
You can see an example from snmpclitools here:
https://github.com/etingof/snmpclitools/commit/d93597050f7e4708ce875cc47274c39a9e63da11

>
> Marcin Niestroj <m.niestroj@grinn-global.com> writes:
>
> > Signed-off-by: Marcin Niestroj <m.niestroj@grinn-global.com>
> > ---
> >  DEVELOPERS                               |  1 +
> >  package/Config.in                        |  1 +
> >  package/python-xmodem/Config.in          |  6 ++++++
> >  package/python-xmodem/python-xmodem.hash |  3 +++
> >  package/python-xmodem/python-xmodem.mk   | 13 +++++++++++++
> >  5 files changed, 24 insertions(+)
> >  create mode 100644 package/python-xmodem/Config.in
> >  create mode 100644 package/python-xmodem/python-xmodem.hash
> >  create mode 100644 package/python-xmodem/python-xmodem.mk
> >
> > [snip]
>
> --
> Marcin Niestrój
> _______________________________________________
> buildroot mailing list
> buildroot@busybox.net
> http://lists.busybox.net/mailman/listinfo/buildroot

Best regards,
Asaf.
Marcin Niestrój May 2, 2020, 10:39 a.m. UTC | #3
Hi Asaf,

Asaf Kahlon <asafka7@gmail.com> writes:

> Hello,
>
> On Thu, Apr 30, 2020 at 4:28 PM Marcin Niestrój
> <m.niestroj@grinn-global.com> wrote:
>>
>> Hi All!
>>
>> The problem with this package is that there is no license file when we
>> download from pypi. But there is one on github. Question is: what should
>> we do about it?
>
> We already have some python packages which don't include the license
> on the tarball, although it exists in the repo.
> Most of the times, it's because the maintainer of the package didn't add
> the license file in MANIFEST.in (which seems to be your case too).
> On those cases, PKG-INFO is mostly used, but it's not the preferred
> solution, so I suggest to send a PR for adding the license to
> MANIFEST.in
> You can see an example from snmpclitools here:
> https://github.com/etingof/snmpclitools/commit/d93597050f7e4708ce875cc47274c39a9e63da11

Thanks for hints! If it takes reasonable time to merge, then I will post
v2 with LICENSE. If not, then I will try PKG-INFO for the time before
next package release.
diff mbox series

Patch

diff --git a/DEVELOPERS b/DEVELOPERS
index cc72b288be..8d4ad02a38 100644
--- a/DEVELOPERS
+++ b/DEVELOPERS
@@ -1598,6 +1598,7 @@  F:	package/lua-stdlib/
 F:	package/luaossl/
 F:	package/murata-cyw-fw/
 F:	package/netdata/
+F:	package/python-xmodem/
 F:	package/rs485conf/
 F:	package/turbolua/
 F:	support/testing/tests/package/test_netdata.py
diff --git a/package/Config.in b/package/Config.in
index 53c8ce0e29..49671993ed 100644
--- a/package/Config.in
+++ b/package/Config.in
@@ -1213,6 +1213,7 @@  menu "External python modules"
 	source "package/python-xlutils/Config.in"
 	source "package/python-xlwt/Config.in"
 	source "package/python-xmltodict/Config.in"
+	source "package/python-xmodem/Config.in"
 	source "package/python-yarl/Config.in"
 	source "package/python-yieldfrom/Config.in"
 	source "package/python-zc-lockfile/Config.in"
diff --git a/package/python-xmodem/Config.in b/package/python-xmodem/Config.in
new file mode 100644
index 0000000000..ef927f1337
--- /dev/null
+++ b/package/python-xmodem/Config.in
@@ -0,0 +1,6 @@ 
+config BR2_PACKAGE_PYTHON_XMODEM
+	bool "python-xmodem"
+	help
+	  XMODEM protocol implementation.
+
+	  https://github.com/tehmaze/xmodem
diff --git a/package/python-xmodem/python-xmodem.hash b/package/python-xmodem/python-xmodem.hash
new file mode 100644
index 0000000000..268fe30bf7
--- /dev/null
+++ b/package/python-xmodem/python-xmodem.hash
@@ -0,0 +1,3 @@ 
+# md5, sha256 from https://pypi.org/pypi/xmodem/json
+md5  f876cb35caf276b61990377710a3b4c4  xmodem-0.4.6.tar.gz
+sha256  089737298f5738eabc43f2519efdc80b402693768f16383f7013b9e6f8f279d7  xmodem-0.4.6.tar.gz
diff --git a/package/python-xmodem/python-xmodem.mk b/package/python-xmodem/python-xmodem.mk
new file mode 100644
index 0000000000..a6ca46f857
--- /dev/null
+++ b/package/python-xmodem/python-xmodem.mk
@@ -0,0 +1,13 @@ 
+################################################################################
+#
+# python-xmodem
+#
+################################################################################
+
+PYTHON_XMODEM_VERSION = 0.4.6
+PYTHON_XMODEM_SOURCE = xmodem-$(PYTHON_XMODEM_VERSION).tar.gz
+PYTHON_XMODEM_SITE = https://files.pythonhosted.org/packages/29/5d/a20d7957f207fc4c4c143881ca7b9617ab7700c153012372ef0a934c7710
+PYTHON_XMODEM_SETUP_TYPE = setuptools
+PYTHON_XMODEM_LICENSE = MIT
+
+$(eval $(python-package))