Skip to content

Commit

Permalink
libwdi 1.4.1
Browse files Browse the repository at this point in the history
  • Loading branch information
pbatard committed Nov 1, 2021
1 parent d506f19 commit dc63334
Show file tree
Hide file tree
Showing 9 changed files with 63 additions and 49 deletions.
13 changes: 13 additions & 0 deletions ChangeLog
Original file line number Diff line number Diff line change
@@ -1,6 +1,19 @@
For the latest changes, please visit:
https://github.com/pbatard/libwdi/commits/master

o v1.4.1 (2021.11.01)
New features:
- add a new 'external_inf' boolean option to wdi_options_prepare_driver
to allow the use of an external .inf instead of the embedded ones
Bugfixes:
- prevent an infinite loop when a certificate cannot be deleted
- fix the use of -w option in wdi-simple
- fix error when trying to install libusb0.sys as a filter-driver
Improvements:
- improve Windows version reporting for Windows 11
- stop on .cat signing error if test signing is not enabled
- add an explicit error for code 0x109 (for Windows 11 Insider builds)

o v1.4.0 (2021.09.04)
Bugfixes:
- fix breakage when providing a user driver
Expand Down
6 changes: 2 additions & 4 deletions _chlver.sh
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,6 @@ _EOF
# First run sed to substitute our variable in the sed command file
sed -i -e "s/@@MAJOR@@/$MAJOR/g" -e "s/@@MINOR@@/$MINOR/g" -e "s/@@MICRO@@/$MICRO/g" cmd.sed
# Run sed to update the .rc version
sed -i -f cmd.sed libwdi/libwdi.rc
sed -i 's/$/\r/' libwdi/libwdi.rc
sed -i -f cmd.sed examples/wdi-simple.rc
sed -i 's/$/\r/' examples/wdi-simple.rc
sed -b -i -f cmd.sed libwdi/libwdi.rc
sed -b -i -f cmd.sed examples/wdi-simple.rc
rm cmd.sed
6 changes: 2 additions & 4 deletions _chzver.sh
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,8 @@ s/^\(.*\)"Zadig .*\..*\.\(.*\)"\(.*\)/\1"Zadig @@MAJOR@@.@@MINOR@@.\2"\3/
_EOF

sed -i -e "s/@@MAJOR@@/$MAJOR/g" -e "s/@@MINOR@@/$MINOR/g" cmd.sed
sed -i -f cmd.sed examples/zadig.rc
sed -i 's/$/\r/' examples/zadig.rc
sed -i -f cmd.sed examples/zadig.h
sed -i 's/$/\r/' examples/zadig.h
sed -b -i -f cmd.sed examples/zadig.rc
sed -b -i -f cmd.sed examples/zadig.h

rm cmd.sed

Expand Down
44 changes: 24 additions & 20 deletions _pre-commit.sh
Original file line number Diff line number Diff line change
Expand Up @@ -16,36 +16,40 @@ if [ -x ./_detect-amend.sh ]; then
. ./_detect-amend.sh
fi

VER=`git log --oneline | wc -l`
BUILD=`git rev-list HEAD --count`
# adjust so that we match the github commit count
TAGVER=`expr $VER + 1`
((BUILD++))
# there may be a better way to prevent improper nano on amend. For now the detection
# of a .amend file in the current directory will do
if [ -f ./.amend ]; then
TAGVER=`expr $TAGVER - 1`
((BUILD--))
rm ./.amend;
fi
echo "setting nano to $TAGVER"
echo "setting nano to $BUILD"

cat > cmd.sed <<\_EOF
s/^[ \t]*FILEVERSION[ \t]*\(.*\),\(.*\),.*,0/ FILEVERSION \1,\2,@@TAGVER@@,0/
s/^[ \t]*PRODUCTVERSION[ \t]*\(.*\),\(.*\),.*,0/ PRODUCTVERSION \1,\2,@@TAGVER@@,0/
s/^\([ \t]*\)VALUE[ \t]*"FileVersion",[ \t]*"\(.*\)\..*"/\1VALUE "FileVersion", "\2.@@TAGVER@@"/
s/^\([ \t]*\)VALUE[ \t]*"ProductVersion",[ \t]*"\(.*\)\..*"/\1VALUE "ProductVersion", "\2.@@TAGVER@@"/
s/^\(.*\)"Zadig \(.*\)\..*"\(.*\)/\1"Zadig \2.@@TAGVER@@"\3/
cat > _library.sed <<\_EOF
s/^[ \t]*FILEVERSION[ \t]*\(.*\),\(.*\),\(.*\),.*/ FILEVERSION \1,\2,\3,@@BUILD@@/
s/^[ \t]*PRODUCTVERSION[ \t]*\(.*\),\(.*\),\(.*\),.*/ PRODUCTVERSION \1,\2,\3,@@BUILD@@/
s/^\([ \t]*\)VALUE[ \t]*"FileVersion",[ \t]*"\(.*\)\..*"/\1VALUE "FileVersion", "\2.@@BUILD@@"/
s/^\([ \t]*\)VALUE[ \t]*"ProductVersion",[ \t]*"\(.*\)\..*"/\1VALUE "ProductVersion", "\2.@@BUILD@@"/
_EOF

cat > _zadig.sed <<\_EOF
s/^[ \t]*FILEVERSION[ \t]*\(.*\),\(.*\),.*,0/ FILEVERSION \1,\2,@@BUILD@@,0/
s/^[ \t]*PRODUCTVERSION[ \t]*\(.*\),\(.*\),.*,0/ PRODUCTVERSION \1,\2,@@BUILD@@,0/
s/^\([ \t]*\)VALUE[ \t]*"FileVersion",[ \t]*"\(.*\)\..*"/\1VALUE "FileVersion", "\2.@@BUILD@@"/
s/^\([ \t]*\)VALUE[ \t]*"ProductVersion",[ \t]*"\(.*\)\..*"/\1VALUE "ProductVersion", "\2.@@BUILD@@"/
s/^\(.*\)"Zadig \(.*\)\..*"\(.*\)/\1"Zadig \2.@@BUILD@@"\3/
_EOF

# First run sed to substitute our variable in the sed command file
sed -i -e "s/@@TAGVER@@/$TAGVER/g" cmd.sed
sed -i -e "s/@@BUILD@@/$BUILD/g" _library.sed
sed -i -e "s/@@BUILD@@/$BUILD/g" _zadig.sed

# Run sed to update the nano version, and add the modified files
sed -i -f cmd.sed libwdi/libwdi.rc
sed -i 's/$/\r/' libwdi/libwdi.rc
sed -i -f cmd.sed examples/zadig.rc
sed -i 's/$/\r/' examples/zadig.rc
sed -i -f cmd.sed examples/zadig.h
sed -i 's/$/\r/' examples/zadig.h
sed -i -f cmd.sed examples/wdi-simple.rc
sed -i 's/$/\r/' examples/wdi-simple.rc
sed -b -i -f _library.sed libwdi/libwdi.rc
sed -b -i -f _library.sed examples/wdi-simple.rc
sed -b -i -f _zadig.sed examples/zadig.rc
sed -b -i -f _zadig.sed examples/zadig.h
rm _library.sed _zadig.sed
git add libwdi/libwdi.rc examples/zadig.rc examples/zadig.h examples/wdi-simple.rc
rm cmd.sed
12 changes: 6 additions & 6 deletions examples/wdi-simple.rc
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@
#endif

VS_VERSION_INFO VERSIONINFO
FILEVERSION 1,4,764,0
PRODUCTVERSION 1,4,764,0
FILEVERSION 1,4,1,765
PRODUCTVERSION 1,4,1,765
FILEFLAGSMASK 0x17L
#ifdef _DEBUG
FILEFLAGS 0x1L
Expand All @@ -25,13 +25,13 @@ BEGIN
BEGIN
VALUE "CompanyName", "akeo.ie"
VALUE "FileDescription", "WDI-Simple"
VALUE "FileVersion", "1.3.764"
VALUE "FileVersion", "1.4.1.765"
VALUE "InternalName", "WDI-Simple"
VALUE "LegalCopyright", "� 2010-2018 Pete Batard (LGPL v3)"
VALUE "LegalTrademarks", "http://www.gnu.org/copyleft/lesser.html"
VALUE "LegalCopyright", "� 2010-2021 Pete Batard (LGPL v3)"
VALUE "LegalTrademarks", "https://www.gnu.org/copyleft/lesser.html"
VALUE "OriginalFilename", "wdi-simple.exe"
VALUE "ProductName", "WDI-Simple"
VALUE "ProductVersion", "1.3.764"
VALUE "ProductVersion", "1.4.1.765"
VALUE "Comments", "http://libwdi.akeo.ie"
END
END
Expand Down
4 changes: 2 additions & 2 deletions examples/zadig.h
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*
* Zadig: Automated Driver Installer for USB devices (GUI version)
* Copyright (c) 2010-2018 Pete Batard <pete@akeo.ie>
* Copyright (c) 2010-2021 Pete Batard <pete@akeo.ie>
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
Expand Down Expand Up @@ -59,7 +59,7 @@
#define FIELD_ORANGE RGB(255,240,200)
#define ARROW_GREEN RGB(92,228,65)
#define ARROW_ORANGE RGB(253,143,56)
#define APP_VERSION "Zadig 2.6.764"
#define APP_VERSION "Zadig 2.7.765"

// These are used to flag end users about the driver they are going to replace
enum driver_type {
Expand Down
12 changes: 6 additions & 6 deletions examples/zadig.rc
Original file line number Diff line number Diff line change
Expand Up @@ -246,8 +246,8 @@ END
//

VS_VERSION_INFO VERSIONINFO
FILEVERSION 2,6,764,0
PRODUCTVERSION 2,6,764,0
FILEVERSION 2,7,765,0
PRODUCTVERSION 2,7,765,0
FILEFLAGSMASK 0x17L
#ifdef _DEBUG
FILEFLAGS 0x1L
Expand All @@ -264,13 +264,13 @@ BEGIN
BEGIN
VALUE "CompanyName", "akeo.ie"
VALUE "FileDescription", "Zadig"
VALUE "FileVersion", "2.6.764"
VALUE "FileVersion", "2.7.765"
VALUE "InternalName", "Zadig"
VALUE "LegalCopyright", "� 2010-2018 Pete Batard (GPL v3)"
VALUE "LegalTrademarks", "http://www.gnu.org/copyleft/gpl.html"
VALUE "LegalCopyright", "� 2010-2021 Pete Batard (GPL v3)"
VALUE "LegalTrademarks", "https://www.gnu.org/copyleft/gpl.html"
VALUE "OriginalFilename", "zadig.exe"
VALUE "ProductName", "Zadig"
VALUE "ProductVersion", "2.6.764"
VALUE "ProductVersion", "2.7.765"
VALUE "Comments", "http://libwdi.akeo.ie"
END
END
Expand Down
12 changes: 6 additions & 6 deletions libwdi/libwdi.rc
Original file line number Diff line number Diff line change
Expand Up @@ -50,8 +50,8 @@ END
//

VS_VERSION_INFO VERSIONINFO
FILEVERSION 1,4,764,0
PRODUCTVERSION 1,4,764,0
FILEVERSION 1,4,1,765
PRODUCTVERSION 1,4,1,765
FILEFLAGSMASK 0x17L
#ifdef _DEBUG
FILEFLAGS 0x1L
Expand All @@ -68,13 +68,13 @@ BEGIN
BEGIN
VALUE "CompanyName", "akeo.ie"
VALUE "FileDescription", "libwdi: Windows Driver Installer Library"
VALUE "FileVersion", "1.3.764"
VALUE "FileVersion", "1.4.1.765"
VALUE "InternalName", "libwdi"
VALUE "LegalCopyright", "� 2010-2017 Pete Batard (LGPL v3)"
VALUE "LegalTrademarks", "http://www.gnu.org/copyleft/lesser.html"
VALUE "LegalCopyright", "� 2010-2021 Pete Batard (LGPL v3)"
VALUE "LegalTrademarks", "https://www.gnu.org/copyleft/lesser.html"
VALUE "OriginalFilename", "libwdi"
VALUE "ProductName", "libwdi"
VALUE "ProductVersion", "1.3.764"
VALUE "ProductVersion", "1.4.1.765"
VALUE "Comments", "http://libwdi.akeo.ie"
END
END
Expand Down
3 changes: 2 additions & 1 deletion libwdi/vid_data.c
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ struct vendor_name {

/*
* http://www.linux-usb.org/usb.ids
* Version: 2021.07.19
* Version: 2021.10.24
*/
static struct vendor_name usb_vendor[] = {
{ 0x0001, "Fry's Electronics" },
Expand Down Expand Up @@ -3103,6 +3103,7 @@ static struct vendor_name usb_vendor[] = {
{ 0x25c6, "Vitus Audio (AVA Group A/S)" },
{ 0x25c8, "Visual Planet Ltd" },
{ 0x25da, "Netatmo" },
{ 0x25dd, "Bit4id Srl" },
{ 0x25e3, "Lumigon" },
{ 0x25f0, "ShanWan" },
{ 0x25fb, "Pentax Ricoh Imaging Co., Ltd" },
Expand Down

0 comments on commit dc63334

Please sign in to comment.