usbip: new package
PATCH 1/1 usbip: new package
Hi
The following patch adds new package: usbip (tools for sharing USB devices over network).
I have tested it under various ARM builds.
Please consider adding it to Buildroot.
--
package/Config.in | 1 + package/usbip/Config.in | 13 +++++++++++++ package/usbip/usbip.mk | 15 +++++++++++++++ 3 files changed, 29 insertions(+), 0 deletions(-)
package/Config.in +1 -0
@@ -684,6 +684,7 @@ source "package/transmission/Config.in" source "package/ttcp/Config.in" source "package/udpcast/Config.in" source "package/ulogd/Config.in" +source "package/usbip/Config.in" source "package/ushare/Config.in" source "package/vde2/Config.in" source "package/vpnc/Config.in"
package/usbip/Config.in new file +13 -0
@@ -0,0 +1,13 @@ +config BR2_PACKAGE_USBIP + bool "usbip" + select BR2_PACKAGE_LIBGLIB2 + select BR2_PACKAGE_LIBSYSFS + help + Userspace tools for sharing USB devices over TCP/IP network. + + http://usbip.sourceforge.net/ + + This package adds both: client and server support. + Note: For exporting or connecting to exported USB devices + additional kernel drivers are needed (available since 2.6.28 + under Stagging).
package/usbip/usbip.mk new file +15 -0
@@ -0,0 +1,15 @@ +############################################################# +# +# usbip +# +############################################################# + +USBIP_VERSION = 0.1.7 +USBIP_SITE = http://downloads.sourceforge.net/project/usbip/usbip/$(USBIP_VERSION) +USBIP_LICENSE = GPLv2+ +USBIP_LICENSE_FILES = COPYING +USBIP_CONF_OPT = --without-tcpwrappers +USBIP_SUBDIR = src +USBIP_AUTORECONF = YES + +$(eval $(autotools-package))
PATCH 1/1 usbip: new package
Hi Marcin,
Quoted 5 lines · Marcin Bis
The following patch adds new package: usbip (tools for sharing USB devices over network).
I have tested it under various ARM builds.Please consider adding it to Buildroot.
This sentence is not part of the commit log. You can put it below...
Quoted 3 lines
Signed-off-by Marcin Bis <[email protected]>--
here.
Quoted 23 lines
package/Config.in | 1 + package/usbip/Config.in | 13 +++++++++++++ package/usbip/usbip.mk | 15 +++++++++++++++ 3 files changed, 29 insertions(+), 0 deletions(-)package/Config.in +1
-0@@ -684,6 +684,7 @@ source "package/transmission/Config.in" source "package/ttcp/Config.in" source "package/udpcast/Config.in" source "package/ulogd/Config.in" +source "package/usbip/Config.in" source "package/ushare/Config.in" source "package/vde2/Config.in" source "package/vpnc/Config.in"package/usbip/Config.in new file +0
-0
package/usbip/Config.in line 4
Quoted 4 lines
package/usbip/Config.in new file +4
-0@@ -0,0 +1,13 @@ +config BR2_PACKAGE_USBIP + bool "usbip" + select BR2_PACKAGE_LIBGLIB2 + select BR2_PACKAGE_LIBSYSFS
Please add a 'depends' for each dependency of these packages. glib2 depends on BR2_USE_WCHAR.
package/usbip/Config.in line 10
Quoted 6 lines
package/usbip/Config.in new file +6
-0+ help + Userspace tools for sharing USB devices over TCP/IP network. + + http://usbip.sourceforge.net/ + + This package adds both: client and server support.
Letting the user select the client and server support independently from each other would be nice, but this can be done later.
Quoted 12 lines
package/usbip/Config.in new file +3
-0+ Note: For exporting or connecting to exported USB devices + additional kernel drivers are needed (available since 2.6.28 + under Stagging).package/usbip/usbip.mk new file +3
-0@@ -0,0 +1,15 @@ +############################################################# +# +# usbip
package/usbip/usbip.mk line 13
Quoted 10 lines
package/usbip/usbip.mk new file +10
-0+# +############################################################# + +USBIP_VERSION = 0.1.7 +USBIP_SITE = http://downloads.sourceforge.net/project/usbip/usbip/$(USBIP_VERSION) +USBIP_LICENSE = GPLv2+ +USBIP_LICENSE_FILES = COPYING +USBIP_CONF_OPT = --without-tcpwrappers +USBIP_SUBDIR = src +USBIP_AUTORECONF = YES
Why is this needed? Please add an explanation comment.
You also need to add a USBIP_DEPENDENCIES listing the packages that you select in Config.in, to ensure correct build order.
package/usbip/usbip.mk line 15
Quoted 2 lines
package/usbip/usbip.mk new file +2
-0+ +$(eval $(autotools-package))
baruch
Signature · 3 lines
http://baruch.siach.name/blog/ ~. .~ Tk Open Systems
=}------------------------------------------------ooO--U--Ooo------------{=
- baruch at tkos.co.il - tel: +972.2.679.5364, http://www.tkos.co.il -PATCH v2 1/1 usbip: new package
--
package/Config.in | 1 + package/usbip/Config.in | 33 +++++++++++++++++++++++++++++++++ package/usbip/usbip.mk | 32 ++++++++++++++++++++++++++++++++ 3 files changed, 66 insertions(+), 0 deletions(-)
package/Config.in +1 -0
@@ -684,6 +684,7 @@ source "package/transmission/Config.in" source "package/ttcp/Config.in" source "package/udpcast/Config.in" source "package/ulogd/Config.in" +source "package/usbip/Config.in" source "package/ushare/Config.in" source "package/vde2/Config.in" source "package/vpnc/Config.in"
package/usbip/Config.in new file +33 -0
@@ -0,0 +1,33 @@ +config BR2_PACKAGE_USBIP + bool "usbip" + depends on BR2_USE_WCHAR # glib2 + select BR2_PACKAGE_LIBGLIB2 + select BR2_PACKAGE_LIBSYSFS + help + Userspace tools for sharing USB devices over TCP/IP network. + + http://usbip.sourceforge.net/ + + Depends on glib. + + Note: For exporting or connecting to exported USB devices + additional kernel drivers are needed (available since 2.6.28 + under Stagging). + +comment "usbip requires a toolchain with WCHAR support" + depends on !BR2_USE_WCHAR + +if BR2_PACKAGE_USBIP + +config BR2_USBIP_CLIENT + bool "usbip client" + default y + help + the client part of usbip + +config BR2_USBIP_SERVER + bool "usbip server" + help + the server part of usbip + +endif
package/usbip/usbip.mk new file +32 -0
@@ -0,0 +1,32 @@ +############################################################# +# +# usbip +# +############################################################# + +USBIP_VERSION = 0.1.7 +USBIP_SITE = http://downloads.sourceforge.net/project/usbip/usbip/$(USBIP_VERSION) +USBIP_LICENSE = GPLv2+ +USBIP_LICENSE_FILES = COPYING +USBIP_CONF_OPT = --without-tcpwrappers +USBIP_DEPENDENCIES = libglib2 libsysfs + +#The userspace applications are in the src/ subdirectory. +USBIP_SUBDIR = src +#Running autogen.sh is needed to create configure script. +USBIP_AUTORECONF = YES + +ifneq ($(BR2_USBIP_CLIENT),y) + USBIP_TOREMOVE += usbip +endif +ifneq ($(BR2_USBIP_SERVER),y) + USBIP_TOREMOVE += usbipd bind_driver +endif + +define USBIP_CLEANUP_AFTER_INSTALL + rm -f $(addprefix $(TARGET_DIR)/usr/bin/, $(USBIP_TOREMOVE)) +endef + +USBIP_POST_INSTALL_TARGET_HOOKS += USBIP_CLEANUP_AFTER_INSTALL + +$(eval $(autotools-package))
PATCH 1/1 usbip: new package
In reply to Baruch SiachQuoted 13 lines · Baruch Siach
Hi Marcin,
Quoted 5 lines · Marcin Bis
The following patch adds new package: usbip (tools for sharing USB devices over network).
I have tested it under various ARM builds.Please consider adding it to Buildroot.
This sentence is not part of the commit log. You can put it below...
Quoted 2 lines
Signed-off-by Marcin Bis <[email protected]>
Please use a real e-mail here, i.e marcin at bis.org.pl
Quoted 3 lines
Quoted 1 line
--
here.
And the separator should be --- and not --, if I'm correct.
Best regards,
Thomas
Signature · 4 lines
Thomas Petazzoni, Free Electrons Kernel, drivers, real-time and embedded Linux development, consulting, training and support. http://free-electrons.com
PATCH v3 1/1 usbip: new package
--- package/Config.in | 1 + package/usbip/Config.in | 33 +++++++++++++++++++++++++++++++++ package/usbip/usbip.mk | 32 ++++++++++++++++++++++++++++++++ 3 files changed, 66 insertions(+), 0 deletions(-)
package/Config.in +1 -0
@@ -684,6 +684,7 @@ source "package/transmission/Config.in" source "package/ttcp/Config.in" source "package/udpcast/Config.in" source "package/ulogd/Config.in" +source "package/usbip/Config.in" source "package/ushare/Config.in" source "package/vde2/Config.in" source "package/vpnc/Config.in"
package/usbip/Config.in new file +33 -0
@@ -0,0 +1,33 @@ +config BR2_PACKAGE_USBIP + bool "usbip" + depends on BR2_USE_WCHAR # glib2 + select BR2_PACKAGE_LIBGLIB2 + select BR2_PACKAGE_LIBSYSFS + help + Userspace tools for sharing USB devices over TCP/IP network. + + http://usbip.sourceforge.net/ + + Depends on glib. + + Note: For exporting or connecting to exported USB devices + additional kernel drivers are needed (available since 2.6.28 + under Stagging). + +comment "usbip requires a toolchain with WCHAR support" + depends on !BR2_USE_WCHAR + +if BR2_PACKAGE_USBIP + +config BR2_USBIP_CLIENT + bool "usbip client" + default y + help + the client part of usbip + +config BR2_USBIP_SERVER + bool "usbip server" + help + the server part of usbip + +endif
package/usbip/usbip.mk new file +32 -0
@@ -0,0 +1,32 @@ +############################################################# +# +# usbip +# +############################################################# + +USBIP_VERSION = 0.1.7 +USBIP_SITE = http://downloads.sourceforge.net/project/usbip/usbip/$(USBIP_VERSION) +USBIP_LICENSE = GPLv2+ +USBIP_LICENSE_FILES = COPYING +USBIP_CONF_OPT = --without-tcpwrappers +USBIP_DEPENDENCIES = libglib2 libsysfs + +#The userspace applications are in the src/ subdirectory. +USBIP_SUBDIR = src +#Running autogen.sh is needed to create configure script. +USBIP_AUTORECONF = YES + +ifneq ($(BR2_USBIP_CLIENT),y) + USBIP_TOREMOVE += usbip +endif +ifneq ($(BR2_USBIP_SERVER),y) + USBIP_TOREMOVE += usbipd bind_driver +endif + +define USBIP_CLEANUP_AFTER_INSTALL + rm -f $(addprefix $(TARGET_DIR)/usr/bin/, $(USBIP_TOREMOVE)) +endef + +USBIP_POST_INSTALL_TARGET_HOOKS += USBIP_CLEANUP_AFTER_INSTALL + +$(eval $(autotools-package))
PATCH v3 1/1 usbip: new package
Hi Marcin,
On Wed, Dec 26, 2012 at 09:55:47AM +0100, Marcin Bis wrote:
[...]
Quoted 1 line
+USBIP_VERSION = 0.1.7
This package is very old. Newer version is distributed with the kernel sources under drivers/staging/usbip/userspace/. I'm not sure how to extract these files during build. Maybe the experts here have an Idea?
baruch
package/usbip/usbip.mk line 12
Quoted 5 lines
package/usbip/usbip.mk new file +5
-0+USBIP_SITE = http://downloads.sourceforge.net/project/usbip/usbip/$(USBIP_VERSION) +USBIP_LICENSE = GPLv2+ +USBIP_LICENSE_FILES = COPYING +USBIP_CONF_OPT = --without-tcpwrappers +USBIP_DEPENDENCIES = libglib2 libsysfs
baruch
Signature · 3 lines
http://baruch.siach.name/blog/ ~. .~ Tk Open Systems
=}------------------------------------------------ooO--U--Ooo------------{=
- baruch at tkos.co.il - tel: +972.2.679.5364, http://www.tkos.co.il -PATCH v3 1/1 usbip: new package
Quoted 7 lines
This package is very old. Newer version is distributed with the kernel sources
underdrivers/staging/usbip/userspace/. I'm not sure how to extract these
files during build. Maybe the experts here have an Idea?
I would be interested too, more and more tools are distributed with the kernel that we might want to build... I'm thinking of the perf tools in particular
is there an example somewhere on how to handle these ?
PATCH v3 1/1 usbip: new package
Dear Jeremy Rosen,
Quoted 5 lines · Jeremy Rosen
I would be interested too, more and more tools are distributed with the kernel that we might want to build... I'm thinking of the perf tools in particular
is there an example somewhere on how to handle these ?
Unfortunately, there isn't a really good and nice way of handling these in Buildroot for now.
I see two options:
* Add sub-options to the "Linux kernel" package, to allow the installation of perf, usbip or other userspace packages whose source code is bundled with the kernel source code. This is the easiest solution, since the kernel version, sources and al. is already defined. But it also has major drawbacks: 1/ it makes those tools available only if you build your kernel with Buildroot and 2/ it puts the configuration options to install those tools inside the "Linux kernel" menu, which is not very intuitive.
* Add separate packages for each of those tools in package/, with those packages depending on the "linux" package. The extract step of those packages could copy the source code of these tools from the Linux kernel source tree into their build directory, or simply build then directly from within the Linux kernel source tree. It solves drawback (2) described above, but not drawback (1).
* Add separate packages for each of those tools in package/, and make them independent from the Linux package. They would for example download the latest stable version of the Linux kernel source code, and use that as a source. The extract step could be customized to only extract the part of the kernel sources that are actually relevant for this package. This would solve both drawbacks (1) and (2), but adds different drawbacks: it's another place where we have to bump the kernel version regularly, and people may want to configure the version of the kernel sources used to build those
tools: the primary reason why those tools are bundled with the kernel sources is because the userspace-to-kernel ABI specific to those tools gets changed from time to time, and therefore there may be compatibility issues in running those tools from kernel version X under a system running kernel version Y.
Best regards,
Thomas
Signature · 4 lines
Thomas Petazzoni, Free Electrons Kernel, drivers, real-time and embedded Linux development, consulting, training and support. http://free-electrons.com
PATCH v3 1/1 usbip: new package
In reply to Marcin BisDear Marcin Bis,
Quoted 6 lines · Marcin Bis
Signed-off-by Marcin Bis <[email protected]>--- package/Config.in | 1 + package/usbip/Config.in | 33 +++++++++++++++++++++++++++++++++ package/usbip/usbip.mk | 32 ++++++++++++++++++++++++++++++++ 3 files changed, 66 insertions(+), 0 deletions(-)
Are you still interested in getting usbip packaged in Buildroot? If so, could you rework your patch to use instead the code bundled with the kernel in drivers/staging/usbip/userspace, as suggested by Baruch?
The package/perf package provides an example on how to create a package for a tool whose source code is shipped directly within the kernel sources.
Since those comments have been made in December 2012, without further postings from you, I'm marking the patch as "Changes requested" in patchwork. This means that unless you post an updated version at some point in the future, we'll no longer have 'usbip' in the list of patches to integrate.
Thanks for your contribution!
Thomas
Signature · 4 lines
Thomas Petazzoni, Free Electrons Kernel, drivers, real-time and embedded Linux development, consulting, training and support. http://free-electrons.com