From: Michael Gernoth Date: Thu, 17 May 2007 16:50:49 +0000 (+0200) Subject: add something versionlike for the git-tracked usb-driver X-Git-Url: https://git.zerfleddert.de/cgi-bin/gitweb.cgi/usb-driver/commitdiff_plain/81cf365889e2aa7101b89967263762ae56a0df10 add something versionlike for the git-tracked usb-driver --- diff --git a/Makefile b/Makefile index cb025f2..bd63135 100644 --- a/Makefile +++ b/Makefile @@ -1,6 +1,6 @@ #Add -DFORCE_PC3_IDENT to CFLAGS to force the identification of #a Parallel Cable III -CFLAGS=-Wall -fPIC #-DFORCE_PC3_IDENT +CFLAGS=-Wall -fPIC -DUSB_DRIVER_VERSION="\"$(shell stat -c '%y' usb-driver.c |cut -d\. -f1)\"" #-DFORCE_PC3_IDENT FTDI := $(shell libftdi-config --libs 2>/dev/null) ifneq ($(FTDI),) diff --git a/usb-driver.c b/usb-driver.c index b230afa..d909522 100644 --- a/usb-driver.c +++ b/usb-driver.c @@ -245,7 +245,7 @@ int do_wdioctl(int fd, unsigned int request, unsigned char *wdioctl) { switch(request & ~(0xc0000000)) { case VERSION: version = (struct version_struct*)(wdheader->data); - strcpy(version->version, "libusb-driver.so $Revision: 1.69 $"); + strcpy(version->version, "libusb-driver.so version: " USB_DRIVER_VERSION); version->versionul = 802; DPRINTF("VERSION\n"); break;