-
Notifications
You must be signed in to change notification settings - Fork 117
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
usb-modeswitch: Update to version 2.6.1
Version 2.5.2 of usb-modeswitch contained a local 0.72 jimtcl copy which was used when the static version of the dispatcher was being compiled. Version 2.6.1 removed this copy of jimtcl from the source package so we add it back ourselves because it's easier to have libjim.a compiled here rather than add a whole new Yocto recipe just for it. Change-type: minor Changelog-entry: Update usb-modeswitch to version 2.6.1 Signed-off-by: Florin Sarbu <[email protected]>
- Loading branch information
Showing
3 changed files
with
49 additions
and
4 deletions.
There are no files selected for viewing
37 changes: 37 additions & 0 deletions
37
...-balena-common/recipes-support/usb-modeswitch/files/use_local_libjim_static_library.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
Index: usb-modeswitch-2.6.1/Makefile | ||
=================================================================== | ||
--- usb-modeswitch-2.6.1.orig/Makefile | ||
+++ usb-modeswitch-2.6.1/Makefile | ||
@@ -13,6 +13,9 @@ UDEVDIR = $(DESTDIR)/lib/udev | ||
SBINDIR = $(PREFIX)/sbin | ||
MANDIR = $(PREFIX)/share/man/man1 | ||
|
||
+JIM_CONFIGURE_OPTS = --disable-lineedit \ | ||
+ --with-out-jim-ext="stdlib posix load signal syslog" --prefix=/usr | ||
+ | ||
.PHONY: clean install install-common uninstall \ | ||
dispatcher-script dispatcher-dynlink dispatcher-statlink \ | ||
install-script install-dynlink install-statlink | ||
@@ -28,6 +31,10 @@ all-with-statlink-dispatcher: $(PROG) di | ||
$(PROG): $(OBJS) usb_modeswitch.h | ||
$(CC) -o $(PROG) $(OBJS) $(CFLAGS) $(LIBS) $(LDFLAGS) | ||
|
||
+jim/libjim.a: | ||
+ cd jim && CFLAGS="$(CFLAGS)" CC="$(CC)" ./configure $(JIM_CONFIGURE_OPTS) | ||
+ $(MAKE) -C jim | ||
+ | ||
dispatcher-script: usb_modeswitch_dispatcher.tcl | ||
DISPATCH=dispatcher-script | ||
cp -f usb_modeswitch_dispatcher.tcl usb_modeswitch_dispatcher | ||
@@ -36,9 +43,9 @@ dispatcher-dynlink: dispatcher.c dispatc | ||
DISPATCH=dispatcher-dynlink | ||
$(CC) dispatcher.c $(LDFLAGS) -Ljim -ljim -Ijim -o usb_modeswitch_dispatcher $(CFLAGS) | ||
|
||
-dispatcher-statlink: dispatcher.c dispatcher.h | ||
+dispatcher-statlink: jim/libjim.a dispatcher.c dispatcher.h | ||
DISPATCH=dispatcher-statlink | ||
- $(CC) dispatcher.c $(LDFLAGS) -l:libjim.a -ldl -Ijim -o usb_modeswitch_dispatcher $(CFLAGS) | ||
+ $(CC) dispatcher.c $(LDFLAGS) jim/libjim.a -Ijim -o usb_modeswitch_dispatcher $(CFLAGS) | ||
|
||
dispatcher.h: usb_modeswitch_dispatcher.tcl | ||
./make_string.sh usb_modeswitch_dispatcher.tcl > $@ |
9 changes: 9 additions & 0 deletions
9
meta-balena-common/recipes-support/usb-modeswitch/usb-modeswitch_%.bbappend
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
FILESEXTRAPATHS:prepend := "${THISDIR}/files:" | ||
|
||
# locally add jimtcl version 0.72 which is needed for building the statically linked version of the dispatcher | ||
SRC_URI:append = " \ | ||
git://repo.or.cz/r/jimtcl.git;protocol=http;destsuffix=${S}/jim;name=jimtcl;branch=master \ | ||
file://use_local_libjim_static_library.patch \ | ||
" | ||
|
||
SRCREV = "dfbde800afdabc83efc9ebe087b1aed6a90136d8" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters