]> git.zerfleddert.de Git - usb-driver/commitdiff
add something versionlike for the git-tracked usb-driver
authorMichael Gernoth <michael@gernoth.net>
Thu, 17 May 2007 16:50:49 +0000 (18:50 +0200)
committerMichael Gernoth <michael@gernoth.net>
Thu, 17 May 2007 18:26:44 +0000 (20:26 +0200)
Makefile
usb-driver.c

index cb025f2b96f9dd7994a873078fe152ef784a9db2..bd63135ce7c5cc842962cbb428fbea1b4c0a43c9 100644 (file)
--- 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),)
index b230afadc917a73ee45741c1faeca029c8975d26..d90952258c070961ca428af69ae90b93b414bbd5 100644 (file)
@@ -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;
Impressum, Datenschutz