Skip to contentSkip to conversation

faifa: new package

PATCH Superseded Maxime Hadjinlian 3 participants 5 messages May 28, 2014 – Jun 8, 2014

lore
Share & tools
lore
#0 lore raw

PATCH v3 1/1 faifa: new package

faifa is a library and a cli used to manage PLC hardware that use Intellon chipset.
Almost everybody use theses chips nowadays.

---
Changes v2 -> v3:
- Do not use AUTORECONF, uses autogen.sh instead
Changes v1 -> v2:
- Changes version from master to a sha1

---
 package/Config.in       |  1 +
 package/faifa/Config.in | 11 +++++++++++
 package/faifa/faifa.mk  | 35 +++++++++++++++++++++++++++++++++++
 3 files changed, 47 insertions(+)
 create mode 100644 package/faifa/Config.in
 create mode 100644 package/faifa/faifa.mk
package/Config.in +1 -0
index 3bc8d24..68406e8 100644
@@ -913,6 +913,7 @@ source "package/dnsmasq/Config.in"
 source "package/dropbear/Config.in"
 source "package/ebtables/Config.in"
 source "package/ethtool/Config.in"
+source "package/faifa/Config.in"
 source "package/foomatic-filters/Config.in"
 source "package/fping/Config.in"
 source "package/gesftpserver/Config.in"
package/faifa/Config.in new file +11 -0
new file mode 100644
index 0000000..99abaab
@@ -0,0 +1,11 @@
+config BR2_PACKAGE_FAIFA
+	bool "faifa"
+	select BR2_PACKAGE_LIBPCAP
+	help
+	  Faifa can configure any Intellon-based Power Line Communication device
+	  using Intellon INT5000 and INT6000 series chips (6000 and 6300 chips). It
+	  supports all Intellon-specific management and control frames as well as
+	  standard management frames.
+
+	  https://dev.open-plc.org
+
package/faifa/faifa.mk new file +35 -0
new file mode 100644
index 0000000..4435802
@@ -0,0 +1,35 @@
+################################################################################
+#
+# faifa
+#
+################################################################################
+
+FAIFA_VERSION = aa0b5f90b89a9fd1533137b68ebf85f5437aba53
+FAIFA_SITE = $(call github,ffainelli,faifa,$(FAIFA_VERSION))
+FAIFA_INSTALL_STAGING = YES
+FAIFA_DEPENDENCIES = libpcap
+FAIFA_LICENSE = GPLv2
+FAIFA_LICENSE_FILES = COPYING
+
+define FAIFA_RUN_AUTOGEN
+	cd $(@D) && PATH=$(BR_PATH) ./autogen.sh
+endef
+FAIFA_PRE_CONFIGURE_HOOKS += FAIFA_RUN_AUTOGEN
+
+define FAIFA_INSTALL_TARGET_CMDS
+    $(TARGET_CONFIGURE_OPTS) $(MAKE) -C $(@D) \
+        PREFIX=/usr \
+        STRIP=/bin/true \
+        DESTDIR=$(TARGET_DIR) \
+        install
+endef
+
+define FAIFA_INSTALL_STAGING_CMDS
+    $(TARGET_CONFIGURE_OPTS) $(MAKE) -C $(@D) \
+        PREFIX=/usr \
+        STRIP=/bin/true \
+        DESTDIR=$(STAGING_DIR) \
+        install
+endef
+
+$(eval $(autotools-package))
Signature · 1 line
2.0.0.rc0
#1 lore raw

PATCH v3 1/1 faifa: new package

Dear Maxime Hadjinlian,

Quoted 6 lines · Maxime Hadjinlian
package/faifa/Config.in new file +0 -0
new file mode 100644
index 0000000..99abaab

package/faifa/Config.in line 8

Quoted 8 lines
package/faifa/Config.in new file +8 -0
@@ -0,0 +1,11 @@
+config BR2_PACKAGE_FAIFA
+	bool "faifa"
+	select BR2_PACKAGE_LIBPCAP
+	help
+	  Faifa can configure any Intellon-based Power Line Communication device
+	  using Intellon INT5000 and INT6000 series chips (6000 and 6300 chips). It
+	  supports all Intellon-specific management and control frames as well as
+	  standard management frames.

These lines are too long and had to be wrapped to a shorter length.

I had to add a !BR2_PREFER_STATIC_LIB dependency, because this package always builds a shared library.

package/faifa/Config.in

Quoted 5 lines
package/faifa/Config.in new file +5 -0
+FAIFA_VERSION = aa0b5f90b89a9fd1533137b68ebf85f5437aba53
+FAIFA_SITE = $(call github,ffainelli,faifa,$(FAIFA_VERSION))
+FAIFA_INSTALL_STAGING = YES
+FAIFA_DEPENDENCIES = libpcap
+FAIFA_LICENSE = GPLv2

GPLv2+.

package/faifa/Config.in

Quoted 6 lines
package/faifa/Config.in new file +6 -0
+FAIFA_LICENSE_FILES = COPYING
+
+define FAIFA_RUN_AUTOGEN
+	cd $(@D) && PATH=$(BR_PATH) ./autogen.sh
+endef
+FAIFA_PRE_CONFIGURE_HOOKS += FAIFA_RUN_AUTOGEN

I've added a comment above this to explain what's going on, and added the missing host-autoconf dependency.

Quoted 6 lines
package/faifa/Config.in new file +6 -0
+
+define FAIFA_INSTALL_TARGET_CMDS
+    $(TARGET_CONFIGURE_OPTS) $(MAKE) -C $(@D) \
+        PREFIX=/usr \
+        STRIP=/bin/true \
+        DESTDIR=$(TARGET_DIR) \

package/faifa/Config.in

Quoted 10 lines
package/faifa/Config.in new file +10 -0
+        install
+endef
+
+define FAIFA_INSTALL_STAGING_CMDS
+    $(TARGET_CONFIGURE_OPTS) $(MAKE) -C $(@D) \
+        PREFIX=/usr \
+        STRIP=/bin/true \
+        DESTDIR=$(STAGING_DIR) \
+        install
+endef

The indentation was wrong, it should use tabs.

Committed with those issues fixed.

Thanks!

Thomas

Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com
#2 lore raw

PATCH v3 1/1 faifa: new package

Maxime, Thomas, all,

Quoted 43 lines · Thomas Petazzoni

Dear Maxime Hadjinlian,

Quoted 6 lines · Maxime Hadjinlian
package/faifa/Config.in new file +0 -0
new file mode 100644
index 0000000..99abaab

package/faifa/Config.in line 8

Quoted 8 lines
package/faifa/Config.in new file +8 -0
@@ -0,0 +1,11 @@
+config BR2_PACKAGE_FAIFA
+     bool "faifa"
+     select BR2_PACKAGE_LIBPCAP
+     help
+       Faifa can configure any Intellon-based Power Line Communication device
+       using Intellon INT5000 and INT6000 series chips (6000 and 6300 chips). It
+       supports all Intellon-specific management and control frames as well as
+       standard management frames.

These lines are too long and had to be wrapped to a shorter length.

I had to add a !BR2_PREFER_STATIC_LIB dependency, because this package always builds a shared library.

package/faifa/Config.in

Quoted 5 lines
package/faifa/Config.in new file +5 -0
+FAIFA_VERSION = aa0b5f90b89a9fd1533137b68ebf85f5437aba53
+FAIFA_SITE = $(call github,ffainelli,faifa,$(FAIFA_VERSION))
+FAIFA_INSTALL_STAGING = YES
+FAIFA_DEPENDENCIES = libpcap
+FAIFA_LICENSE = GPLv2

GPLv2+.

package/faifa/Config.in

Quoted 6 lines
package/faifa/Config.in new file +6 -0
+FAIFA_LICENSE_FILES = COPYING
+
+define FAIFA_RUN_AUTOGEN
+     cd $(@D) && PATH=$(BR_PATH) ./autogen.sh
+endef
+FAIFA_PRE_CONFIGURE_HOOKS += FAIFA_RUN_AUTOGEN

I've added a comment above this to explain what's going on, and added the missing host-autoconf dependency.

Quoted 16 lines
Quoted 6 lines
package/faifa/Config.in new file +6 -0
+
+define FAIFA_INSTALL_TARGET_CMDS
+    $(TARGET_CONFIGURE_OPTS) $(MAKE) -C $(@D) \
+        PREFIX=/usr \
+        STRIP=/bin/true \
+        DESTDIR=$(TARGET_DIR) \

package/faifa/Config.in

Quoted 10 lines
package/faifa/Config.in new file +10 -0
+        install
+endef
+
+define FAIFA_INSTALL_STAGING_CMDS
+    $(TARGET_CONFIGURE_OPTS) $(MAKE) -C $(@D) \
+        PREFIX=/usr \
+        STRIP=/bin/true \
+        DESTDIR=$(STAGING_DIR) \
+        install
+endef

Just nit and late, but why do you need override the whole commands? All of this could have been set in the FAIFA_INSTALL_TARGET_OPT variable (respectively in FAIFA_INSTALL_STAGING_OPT):

FAIFA_INSTALL_TARGET_OPT = \
    PREFIX=/usr \
    STRIP=/bin/true \
    DESTDIR=$(TARGET_DIR) \
    install

Just nitpicking ;-)

Regards,

Signature · 1 line
Samuel
#3 lore raw

PATCH v3 1/1 faifa: new package

Dear Samuel Martin,

Quoted 11 lines · Samuel Martin

Just nit and late, but why do you need override the whole commands? All of this could have been set in the FAIFA_INSTALL_TARGET_OPT variable (respectively in FAIFA_INSTALL_STAGING_OPT):

FAIFA_INSTALL_TARGET_OPT = \
    PREFIX=/usr \
    STRIP=/bin/true \
    DESTDIR=$(TARGET_DIR) \
    install

Just nitpicking ;-)

True. I believe it doesn't make a lot of difference in terms of code factorization, so to me, both solutions are almost equivalent.

Thomas

Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com
#4 lore raw

PATCH v3 1/1 faifa: new package

Hi Thomas, Samuel,

Thanks a lot for your fixes.

Quoted 24 lines · Thomas Petazzoni

Dear Samuel Martin,

Quoted 11 lines · Samuel Martin

Just nit and late, but why do you need override the whole commands? All of this could have been set in the FAIFA_INSTALL_TARGET_OPT variable (respectively in FAIFA_INSTALL_STAGING_OPT):

FAIFA_INSTALL_TARGET_OPT = \
    PREFIX=/usr \
    STRIP=/bin/true \
    DESTDIR=$(TARGET_DIR) \
    install

Just nitpicking ;-)

True. I believe it doesn't make a lot of difference in terms of code factorization, so to me, both solutions are almost equivalent.

Thomas
--
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com