Skip to contentSkip to conversation

package/casync: new package

PATCH Superseded Yair Ben-Avraham 3 participants 4 messages Jan 7, 2021 – Jan 9, 2021

v2 of 3 Superseded Latest is v3 →

lore
Share & tools
lore
#0 lore raw

PATCH v2 1/1 package/casync: new package

Content-Addressable Data Synchronization Tool

---
 DEVELOPERS                 |  1 +
 package/Config.in          |  1 +
 package/casync/Config.in   | 15 +++++++++++
 package/casync/casync.hash |  3 +++
 package/casync/casync.mk   | 54 ++++++++++++++++++++++++++++++++++++++
 5 files changed, 74 insertions(+)
 create mode 100644 package/casync/Config.in
 create mode 100644 package/casync/casync.hash
 create mode 100644 package/casync/casync.mk
DEVELOPERS +1 -0
index 258a51a14c..1917cd7f48 100644
@@ -2709,6 +2709,7 @@ F:	package/fwup/
 
 N:	Yair Ben Avraham <[email protected]>
 F:	package/gloox/
+F:	package/casync/
 
 N:	Yann CARDAILLAC <[email protected]>
 F:	package/open62541/
package/Config.in +1 -0
index 7264198001..eff1a7f433 100644
@@ -2067,6 +2067,7 @@ menu "Networking applications"
 	source "package/c-icap-modules/Config.in"
 	source "package/can-utils/Config.in"
 	source "package/cannelloni/Config.in"
+	source "package/casync/Config.in"
 	source "package/chrony/Config.in"
 	source "package/civetweb/Config.in"
 	source "package/connman/Config.in"
package/casync/Config.in new file +15 -0
new file mode 100644
index 0000000000..7cace7eacf
@@ -0,0 +1,15 @@
+config BR2_PACKAGE_CASYNC
+	bool "casync"
+	depends on BR2_PACKAGE_HAS_UDEV
+	depends on BR2_TOOLCHAIN_USES_GLIBC # scandirat() is not implemented by musl and uclibc-ng
+	select BR2_PACKAGE_ACL
+	select BR2_PACKAGE_LIBCURL
+	select BR2_PACKAGE_OPENSSL
+	select BR2_PACKAGE_XZ
+	help
+	  Content-Addressable Data Synchronization Tool
+
+	  https://github.com/systemd/casync
+
+comment "casync needs a glibc toolchain"
+	depends on !BR2_TOOLCHAIN_USES_GLIBC
package/casync/casync.hash new file +3 -0
new file mode 100644
index 0000000000..dbb85520de
@@ -0,0 +1,3 @@
+# sha256 locally computed
+sha256  d07f43e70e3c466152033da4c55c065f815d3025234a046c2bce1cfe4ac7d273  casync-4ad9bcb94bc83ff36cfc65515107ea06a88c2dfc.tar.gz
+sha256  dc626520dcd53a22f727af3ee42c770e56c97a64fe3adb063799d8ab032fe551  LICENSE.LGPL2.1
package/casync/casync.mk new file +54 -0

54 lines not on this page · raw message

--
2.20.1

#1 lore raw

PATCH v2 1/1 package/casync: new package

Hello,

Thanks for the new iteration!

package/casync/Config.in line 3

Quoted 1 line · On Thu, 07 Jan 2021 07:12:57 +0000 Yair Ben-Avraham via buildroot…
package/casync/Config.in new file +1 -0
+	depends on BR2_PACKAGE_HAS_UDEV

udev is not a mandatory dependency.

package/casync/casync.mk line 12

Quoted 6 lines
package/casync/casync.mk new file +6 -0
+CASYNC_VERSION = 4ad9bcb94bc83ff36cfc65515107ea06a88c2dfc
+CASYNC_SITE = $(call github,systemd,casync,$(CASYNC_VERSION))
+CASYNC_LICENSE = LGPL-2.1+
+CASYNC_LICENSE_FILES = LICENSE.LGPL2.1
+# xz is mandatory because of ./src/castore.c:5:10: #include <lzma.h>
+CASYNC_DEPENDENCIES = acl libcurl openssl xz

This seems odd, I *think* I got it to build without xz. Did you pass the right -D option ?

Other than those two questions, looks good to me!

Thomas

Signature · 3 lines
Thomas Petazzoni, CTO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
#2 lore raw

PATCH v2 1/1 package/casync: new package

Hi,

I tried without xz, build failed, details below:

./casync.config:
BR2_PACKAGE_ACL=y
BR2_PACKAGE_LIBCURL=y
BR2_PACKAGE_OPENSSL=y

./package/casync/casync.mk:
CASYNC_DEPENDENCIES = acl libcurl openssl
...
ifeq ($(BR2_PACKAGE_XZ),y)
CASYNC_DEPENDENCIES += xz
CASYNC_CONF_OPTS += -Dliblzma=enabled
else
CASYNC_CONF_OPTS += -Dliblzma=disabled
endif
...

br-arm-cortex-a9-glibc/logfile:
../src/castore.c:5:10: fatal error: lzma.h: No such file or directory

    5 | #include <lzma.h>
      |          ^~~~~~~~

compilation terminated.

In addition, in file ./src/castore.c , include <lzma.h> is not under if HAVE_LIBLZMA block, see counterexample inside ./src/compressor.h

So it's either adding xz to the dependencies or include <lzma.h> under if condition and try to build. What is better?

Yair
--
Yair Ben-Avraham
yairba at protonmail.com
+31.6.1316.5535

??????? Original Message ???????

Quoted 30 lines · Thomas Petazzoni

Hello,

Thanks for the new iteration!

Quoted 1 line · On Thu, 07 Jan 2021 07:12:57 +0000 Yair Ben-Avraham via buildroot buildroot at…

- depends on BR2_PACKAGE_HAS_UDEV

udev is not a mandatory dependency.

package/casync/casync.mk line 12

Quoted 6 lines
package/casync/casync.mk new file +6 -0
+CASYNC_VERSION = 4ad9bcb94bc83ff36cfc65515107ea06a88c2dfc
+CASYNC_SITE = $(call github,systemd,casync,$(CASYNC_VERSION))
+CASYNC_LICENSE = LGPL-2.1+
+CASYNC_LICENSE_FILES = LICENSE.LGPL2.1
+# xz is mandatory because of ./src/castore.c:5:10: #include <lzma.h>
+CASYNC_DEPENDENCIES = acl libcurl openssl xz

This seems odd, Ithink I got it to build without xz. Did you pass the right -D option ?

Other than those two questions, looks good to me!

Thomas

-----------------------------------------------------------------------------------------------------------------------------------------------------

Thomas Petazzoni, CTO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com

#3 lore raw

PATCH v2 1/1 package/casync: new package

Yair, All,

On 2021-01-07 14:23 +0000, Yair Ben-Avraham via buildroot spake thusly:

Quoted 20 lines

I tried without xz, build failed, details below:

./casync.config:
BR2_PACKAGE_ACL=y
BR2_PACKAGE_LIBCURL=y
BR2_PACKAGE_OPENSSL=y

./package/casync/casync.mk:
CASYNC_DEPENDENCIES = acl libcurl openssl
...
ifeq ($(BR2_PACKAGE_XZ),y)
CASYNC_DEPENDENCIES += xz
CASYNC_CONF_OPTS += -Dliblzma=enabled
else
CASYNC_CONF_OPTS += -Dliblzma=disabled
endif
...

br-arm-cortex-a9-glibc/logfile:
../src/castore.c:5:10: fatal error: lzma.h: No such file or directory

Quoted 7 lines
    5 | #include <lzma.h>
      |          ^~~~~~~~

compilation terminated.

In addition, in file ./src/castore.c , include <lzma.h> is not under if HAVE_LIBLZMA block, see counterexample inside ./src/compressor.h

So it's either adding xz to the dependencies or include <lzma.h> under if condition and try to build. What is better?

The proper solution, IMHO, would be to fix ./src/castore.c. AFAICS, lzma.h is not needed from src/castore.c.

If that is indeed true, then patch it out, and send the patch upstream.

Afterall, upstream has an option to enable/disable use of liblzma, so they do expect the build to succeed without it, I would wager.

Regards,
Yann E. MORIN.

Quoted 45 lines

Yair
--
Yair Ben-Avraham
yairba at protonmail.com
+31.6.1316.5535

??????? Original Message ???????

Quoted 23 lines · Thomas Petazzoni

Hello,

Thanks for the new iteration!

Quoted 1 line · On Thu, 07 Jan 2021 07:12:57 +0000 Yair Ben-Avraham via buildroot buildroot at…

- depends on BR2_PACKAGE_HAS_UDEV

udev is not a mandatory dependency.

package/casync/casync.mk line 12

Quoted 6 lines
package/casync/casync.mk new file +6 -0
+CASYNC_VERSION = 4ad9bcb94bc83ff36cfc65515107ea06a88c2dfc
+CASYNC_SITE = $(call github,systemd,casync,$(CASYNC_VERSION))
+CASYNC_LICENSE = LGPL-2.1+
+CASYNC_LICENSE_FILES = LICENSE.LGPL2.1
+# xz is mandatory because of ./src/castore.c:5:10: #include <lzma.h>
+CASYNC_DEPENDENCIES = acl libcurl openssl xz

This seems odd, Ithink I got it to build without xz. Did you pass the right -D option ?

Other than those two questions, looks good to me!

Quoted 7 lines

Thomas

-----------------------------------------------------------------------------------------------------------------------------------------------------

Thomas Petazzoni, CTO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com

_______________________________________________
buildroot mailing list
buildroot at busybox.net
http://lists.busybox.net/mailman/listinfo/buildroot

Signature · 6 lines
.-----------------.--------------------.------------------.--------------------.
|  Yann E. MORIN  | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software  Designer | \ / CAMPAIGN     |  ___               |
| +33 561 099 427 `------------.-------:  X  AGAINST      |  \e/  There is no  |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL    |   v   conspiracy.  |
'------------------------------^-------^------------------^--------------------'