Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Julien Boibessot <julien.boibessot@free.fr>
To: buildroot@busybox.net
Subject: [Buildroot] [PATCH 1/1] openzwave: new package
Date: Thu, 21 Apr 2016 16:12:50 +0200	[thread overview]
Message-ID: <5718DFE2.6030401@free.fr> (raw)
In-Reply-To: <1461159491-14317-1-git-send-email-joris.lijssens@gmail.com>

Hello Joris,

is your work more or less derived from Fabrice's patch (04/03/2016) ?

I have run tested it, so my comments below...

On 20/04/2016 15:38, Joris Lijssens wrote:
> Signed-off-by: Joris Lijssens <joris.lijssens@gmail.com>
> ---
>  package/Config.in                |  1 +
>  package/openzwave/Config.in      | 15 +++++++++++++++
>  package/openzwave/openzwave.hash |  2 ++
>  package/openzwave/openzwave.mk   | 26 ++++++++++++++++++++++++++
>  4 files changed, 44 insertions(+)
>  create mode 100644 package/openzwave/Config.in
>  create mode 100644 package/openzwave/openzwave.hash
>  create mode 100644 package/openzwave/openzwave.mk
>
> diff --git a/package/Config.in b/package/Config.in
> index ecaf164..25fa0d9 100644
> --- a/package/Config.in
> +++ b/package/Config.in
> @@ -1171,6 +1171,7 @@ menu "Networking"
>  	source "package/omniorb/Config.in"
>  	source "package/openldap/Config.in"
>  	source "package/openpgm/Config.in"
> +	source "package/openzwave/Config.in"
>  	source "package/ortp/Config.in"
>  	source "package/qdecoder/Config.in"
>  	source "package/qpid-proton/Config.in"
> diff --git a/package/openzwave/Config.in b/package/openzwave/Config.in
> new file mode 100644
> index 0000000..3ae0959
> --- /dev/null
> +++ b/package/openzwave/Config.in
> @@ -0,0 +1,15 @@
> +config BR2_PACKAGE_OPENZWAVE
> +	bool "openzwave"
> +	depends on BR2_INSTALL_LIBSTDCPP
> +	depends on BR2_PACKAGE_HAS_UDEV # libudev
> +	depends on BR2_TOOLCHAIN_HAS_THREADS
> +	depends on BR2_USE_WCHAR # use wchar_t

in my build config, I also require a patch for openzwave to add:
    #define _GNU_SOURCE
in cpp/hidapi/linux/hid.c (like already done in cpp/hidapi/libusb/hid.c).
Otherwise build fails on wcsdup() implicit declaration.

> +	help
> +	   OpenZwave is a free software library that interfaces with selected Z-Wave
> +	   PC controllers, allowing anyone to create applications that manipulate
> +	   and respond to devices on a Z-Wave network, without requiring in-depth
> +	   knowledge of the Z-Wave protocol.
> +
> +comment "openzwave needs udev /dev management and a toolchain w/ C++, threads, wchar"
> +	depends on !BR2_PACKAGE_HAS_UDEV || !BR2_INSTALL_LIBSTDCPP \
> +		|| !BR2_TOOLCHAIN_HAS_THREADS || !BR2_USE_WCHAR
> diff --git a/package/openzwave/openzwave.hash b/package/openzwave/openzwave.hash
> new file mode 100644
> index 0000000..4291e76
> --- /dev/null
> +++ b/package/openzwave/openzwave.hash
> @@ -0,0 +1,2 @@
> +# Locally calculated
> +sha256 ca122365f6237dc245be0129eb460e78126976b9c7bd06487795d3acfc9f2a5f openzwave-v1.4.tar.gz 
> diff --git a/package/openzwave/openzwave.mk b/package/openzwave/openzwave.mk
> new file mode 100644
> index 0000000..aa96b0c
> --- /dev/null
> +++ b/package/openzwave/openzwave.mk
> @@ -0,0 +1,26 @@
> +################################################################################
> +#
> +# openzwave
> +#
> +################################################################################
> +
> +OPENZWAVE_VERSION = v1.4
> +OPENZWAVE_SITE = $(call github,OpenZWave,open-zwave,$(OPENZWAVE_VERSION))
> +OPENZWAVE_LICENSE = LGPLv3+ (library), GPLv3+ (test programs), Apache-2.0
> +OPENZWAVE_LICENSE_FILES = license/license.txt license/lgpl.txt license/gpl.txt \
> +			  license/Apache-License-2.0.txt

does it take into account licenses of cpp/hidapi/* ?

> +OPENZWAVE_DEPENDENCIES = udev
> +
> +define OPENZWAVE_BUILD_CMDS
> +	$(MAKE) CROSS_COMPILE="$(TARGET_CROSS)" -C $(@D)
> +endef
> +
> +define OPENZWAVE_INSTALL_STAGING_CMDS
> +	$(MAKE) $(TARGET_CONFIGURE_OPTS) -C $(@D) DESTDIR=$(STAGING_DIR) PREFIX=/usr install
> +endef

shouldn't you also have a OPENZWAVE_INSTALL_STAGING = YES ?

> +
> +define OPENZWAVE_INSTALL_TARGET_CMDS
> +	$(MAKE) $(TARGET_CONFIGURE_OPTS) -C $(@D) DESTDIR=$(TARGET_DIR) PREFIX=/usr install
> +endef

Your installation method end up by installing config files in
/usr/etc/openzwave/ instead of /etc/openzwave and libraries in
/usr/lib64 instead of /usr/lib.
Fabrice patch seems to adress that (to be confirmed soon).

Moreover you also install ozw_config script in rootfs, whereas this
build script is only needed in staging dir.

Otherwise, all run well on my ARM platforms with AEON-LABS Zstick S2. :-)

> +
> +$(eval $(generic-package))

Best regards,
Julien

  reply	other threads:[~2016-04-21 14:12 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-04-20 13:38 [Buildroot] [PATCH 1/1] openzwave: new package Joris Lijssens
2016-04-21 14:12 ` Julien Boibessot [this message]
2016-04-22  9:56   ` Joris Lijssens
  -- strict thread matches above, loose matches on Subject: below --
2016-04-22 14:20 fabrice.fontaine at orange.com
2016-04-22 22:39 ` Thomas Petazzoni
     [not found]   ` <4485_1461568414_571DC39E_4485_77_1_EEB3FED4859B6C488DDDEC4B2D3DE92B0FC5BBD4@OPEXCLILM23.corporate.adroot.infra.ftgroup>
2016-04-25  7:25     ` Thomas Petazzoni
2016-04-25 12:44       ` Peter Korsgaard
2016-04-25 14:31   ` fabrice.fontaine at orange.com
2016-04-22 13:37 fabrice.fontaine at orange.com
2016-03-04 15:15 fabrice.fontaine at orange.com

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=5718DFE2.6030401@free.fr \
    --to=julien.boibessot@free.fr \
    --cc=buildroot@busybox.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox