* [Buildroot] [PATCH v8] bcache-tools: Adding package.
@ 2014-09-07 20:27 Jean-Christophe DUBOIS
2014-09-07 20:39 ` Yann E. MORIN
2014-09-21 20:44 ` Thomas Petazzoni
0 siblings, 2 replies; 3+ messages in thread
From: Jean-Christophe DUBOIS @ 2014-09-07 20:27 UTC (permalink / raw)
To: buildroot
This is the bcache tools, required to setup the linux bcache
feature of the Linux kernel.
Signed-off-by: Jean-Christophe DUBOIS <jcd@tribudubois.net>
---
Changes v1 to v2
* Remove 'support' word from comment statement in Config.in.
* Use github helper to get the project site instead of hardcoded URL.
Changes v2 to v3
* Added bcache-tools description in Config help.
* Added bcache-tools URL in Config help.
* Added BR2_LARGEFILE BR2_USE_WCHAR and BR2_USE_MMU dependencies in Config.
* Added BR2_PACKAGE_UTIL_LINUX selection in Config.
* Added new requirements in Config comment.
* Use POST_EXTRACT_HOOKS to modify Makefile.
* Pass $(TARGET_CONFIGURE_OPTS) in env variables to $(MAKE).
* Create man8 dir as part of PRE_INSTALL_TARGET_HOOKS.
Changes v3 to v4
* Move from .zip file to .tar.gz as download file in .mk file.
* Use complete git tag as version in .mk file.
* Remove explicit extract rule from .mk file (use implicite rule).
Changes v4 to v5
* Remove explicit package name in .mk (rely on default behavior).
Changes v5 to v6
* Switch spaces to tabs in Config.in
* Don't patch Makefile for pkg-config in .mk file.
Changes v6 to v7
* change eudev dependency to udev dependency in Makefile.
Changes v7 to v8
* remove makefile dependency on udev
* install /lib/udev/rules.d directory in PRE_INSTALL_TARGET_HOOKS
---
package/Config.in | 1 +
package/bcache-tools/Config.in | 22 +++++++++++++++++++++
package/bcache-tools/bcache-tools.mk | 37 ++++++++++++++++++++++++++++++++++++
3 files changed, 60 insertions(+)
create mode 100644 package/bcache-tools/Config.in
create mode 100644 package/bcache-tools/bcache-tools.mk
diff --git a/package/Config.in b/package/Config.in
index 883dd66..ef0a22a 100644
--- a/package/Config.in
+++ b/package/Config.in
@@ -280,6 +280,7 @@ endmenu
source "package/a10disp/Config.in"
source "package/acpid/Config.in"
source "package/avrdude/Config.in"
+ source "package/bcache-tools/Config.in"
source "package/cdrkit/Config.in"
source "package/cryptsetup/Config.in"
source "package/cwiid/Config.in"
diff --git a/package/bcache-tools/Config.in b/package/bcache-tools/Config.in
new file mode 100644
index 0000000..a3f7897
--- /dev/null
+++ b/package/bcache-tools/Config.in
@@ -0,0 +1,22 @@
+config BR2_PACKAGE_BCACHE_TOOLS
+ bool "bcache tools"
+ depends on BR2_PACKAGE_HAS_UDEV
+ depends on BR2_LARGEFILE # util-linux
+ depends on BR2_USE_WCHAR # util-linux
+ depends on BR2_USE_MMU # util-linux (libblkid)
+ select BR2_PACKAGE_UTIL_LINUX
+ select BR2_PACKAGE_UTIL_LINUX_LIBUUID
+ select BR2_PACKAGE_UTIL_LINUX_LIBBLKID
+ help
+ Bcache is a Linux kernel block layer cache. It allows one or
+ more fast disk drives such as flash-based solid state drives (SSDs)
+ to act as a cache for one or more slower hard disk drives.
+
+ http://bcache.evilpiepirate.org/
+
+ This is the user space bcache tools, required to setup the linux
+ bcache feature of the Linux kernel.
+
+comment "bcache-tools needs udev /dev management and a toolchain w/ largefile, wchar"
+ depends on BR2_USE_MMU
+ depends on !BR2_PACKAGE_HAS_UDEV || !BR2_LARGEFILE || !BR2_USE_WCHAR
diff --git a/package/bcache-tools/bcache-tools.mk b/package/bcache-tools/bcache-tools.mk
new file mode 100644
index 0000000..e537471
--- /dev/null
+++ b/package/bcache-tools/bcache-tools.mk
@@ -0,0 +1,37 @@
+################################################################################
+#
+# bcache-tools
+#
+################################################################################
+
+BCACHE_TOOLS_VERSION = v1.0.7
+BCACHE_TOOLS_SITE = $(call github,g2p,bcache-tools,$(BCACHE_TOOLS_VERSION))
+BCACHE_TOOLS_LICENSE = GPLv2
+BCACHE_TOOLS_LICENSE_FILES = COPYING
+BCACHE_TOOLS_DEPENDENCIES = host-pkgconf util-linux
+
+# We pass $(TARGET_CONFIGURE_OPTS) as environment variable to allow
+# the bcache-tools Makefile to alter CFLAGS
+define BCACHE_TOOLS_BUILD_CMDS
+ $(TARGET_MAKE_ENV) $(TARGET_CONFIGURE_OPTS) $(MAKE) -C $(@D)
+endef
+
+# The bcache-tools Makefile expects the man8 directory to exist.
+define BCACHE_TOOLS_INSTALL_MAN8
+ $(INSTALL) -m 0755 -d $(TARGET_DIR)/usr/share/man/man8
+endef
+
+# The bcache-tools Makefile expects the /lib/udev/rules.d directory to exist.
+define BCACHE_TOOLS_INSTALL_UDEV
+ $(INSTALL) -m 0755 -d $(TARGET_DIR)/lib/udev/rules.d
+endef
+
+BCACHE_TOOLS_PRE_INSTALL_TARGET_HOOKS += BCACHE_TOOLS_INSTALL_MAN8
+BCACHE_TOOLS_PRE_INSTALL_TARGET_HOOKS += BCACHE_TOOLS_INSTALL_UDEV
+
+define BCACHE_TOOLS_INSTALL_TARGET_CMDS
+ $(TARGET_MAKE_ENV) $(TARGET_CONFIGURE_OPTS) $(MAKE) -C $(@D) \
+ DESTDIR=$(TARGET_DIR) install
+endef
+
+$(eval $(generic-package))
--
1.9.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [Buildroot] [PATCH v8] bcache-tools: Adding package.
2014-09-07 20:27 [Buildroot] [PATCH v8] bcache-tools: Adding package Jean-Christophe DUBOIS
@ 2014-09-07 20:39 ` Yann E. MORIN
2014-09-21 20:44 ` Thomas Petazzoni
1 sibling, 0 replies; 3+ messages in thread
From: Yann E. MORIN @ 2014-09-07 20:39 UTC (permalink / raw)
To: buildroot
Jean-Christophe, All,
On 2014-09-07 22:27 +0200, Jean-Christophe DUBOIS spake thusly:
> This is the bcache tools, required to setup the linux bcache
> feature of the Linux kernel.
>
> Signed-off-by: Jean-Christophe DUBOIS <jcd@tribudubois.net>
Reviewed-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Yet, a small comment below...
[--SNIP--]
> diff --git a/package/bcache-tools/bcache-tools.mk b/package/bcache-tools/bcache-tools.mk
> new file mode 100644
> index 0000000..e537471
> --- /dev/null
> +++ b/package/bcache-tools/bcache-tools.mk
> @@ -0,0 +1,37 @@
> +################################################################################
> +#
> +# bcache-tools
> +#
> +################################################################################
> +
> +BCACHE_TOOLS_VERSION = v1.0.7
> +BCACHE_TOOLS_SITE = $(call github,g2p,bcache-tools,$(BCACHE_TOOLS_VERSION))
> +BCACHE_TOOLS_LICENSE = GPLv2
> +BCACHE_TOOLS_LICENSE_FILES = COPYING
> +BCACHE_TOOLS_DEPENDENCIES = host-pkgconf util-linux
> +
> +# We pass $(TARGET_CONFIGURE_OPTS) as environment variable to allow
> +# the bcache-tools Makefile to alter CFLAGS
> +define BCACHE_TOOLS_BUILD_CMDS
> + $(TARGET_MAKE_ENV) $(TARGET_CONFIGURE_OPTS) $(MAKE) -C $(@D)
> +endef
> +
> +# The bcache-tools Makefile expects the man8 directory to exist.
> +define BCACHE_TOOLS_INSTALL_MAN8
> + $(INSTALL) -m 0755 -d $(TARGET_DIR)/usr/share/man/man8
> +endef
> +
> +# The bcache-tools Makefile expects the /lib/udev/rules.d directory to exist.
> +define BCACHE_TOOLS_INSTALL_UDEV
> + $(INSTALL) -m 0755 -d $(TARGET_DIR)/lib/udev/rules.d
> +endef
> +
> +BCACHE_TOOLS_PRE_INSTALL_TARGET_HOOKS += BCACHE_TOOLS_INSTALL_MAN8
> +BCACHE_TOOLS_PRE_INSTALL_TARGET_HOOKS += BCACHE_TOOLS_INSTALL_UDEV
Sorry, I was not clear enough in my previous mails (although I did send a
corrective email to fix this): there is not need to have two hooks, you
should create the two directories in the same hook.
No need to resend, the comitter can do the change, hopefully! ;-)
Thank you! :-)
Regards,
Yann E. MORIN.
> +define BCACHE_TOOLS_INSTALL_TARGET_CMDS
> + $(TARGET_MAKE_ENV) $(TARGET_CONFIGURE_OPTS) $(MAKE) -C $(@D) \
> + DESTDIR=$(TARGET_DIR) install
> +endef
> +
> +$(eval $(generic-package))
> --
> 1.9.1
>
> _______________________________________________
> buildroot mailing list
> buildroot at busybox.net
> http://lists.busybox.net/mailman/listinfo/buildroot
--
.-----------------.--------------------.------------------.--------------------.
| Yann E. MORIN | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software Designer | \ / CAMPAIGN | ___ |
| +33 223 225 172 `------------.-------: X AGAINST | \e/ There is no |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL | v conspiracy. |
'------------------------------^-------^------------------^--------------------'
^ permalink raw reply [flat|nested] 3+ messages in thread
* [Buildroot] [PATCH v8] bcache-tools: Adding package.
2014-09-07 20:27 [Buildroot] [PATCH v8] bcache-tools: Adding package Jean-Christophe DUBOIS
2014-09-07 20:39 ` Yann E. MORIN
@ 2014-09-21 20:44 ` Thomas Petazzoni
1 sibling, 0 replies; 3+ messages in thread
From: Thomas Petazzoni @ 2014-09-21 20:44 UTC (permalink / raw)
To: buildroot
Dear Jean-Christophe DUBOIS,
On Sun, 7 Sep 2014 22:27:42 +0200, Jean-Christophe DUBOIS wrote:
> This is the bcache tools, required to setup the linux bcache
> feature of the Linux kernel.
>
> Signed-off-by: Jean-Christophe DUBOIS <jcd@tribudubois.net>
Thanks, patch applied, after doing the change suggested by Yann (use
only one hook to create the missing directories).
Thomas
--
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2014-09-21 20:44 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-09-07 20:27 [Buildroot] [PATCH v8] bcache-tools: Adding package Jean-Christophe DUBOIS
2014-09-07 20:39 ` Yann E. MORIN
2014-09-21 20:44 ` Thomas Petazzoni
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox