update-pciids: fix PCI_COMPRESSED_IDS value when zlib is disabled
PATCH 1/1 update-pciids: fix PCI_COMPRESSED_IDS value when zlib is disabled
If you build with zlib disabled, then PCI_COMPRESSED_IDS is not defined, which generates the line in the update script:
PCI_COMPRESSED_IDS=
which in turn causes the update script to warn:
bash: [: : integer expression expected
So default it to 0 to avoid that logic.
--- Makefile | 1 + 1 files changed, 1 insertions(+), 0 deletions(-)
Makefile +1 -0
@@ -77,6 +77,7 @@ ls-map.o: ls-map.c $(LSPCIINC) setpci.o: setpci.c pciutils.h $(PCIINC) common.o: common.c pciutils.h $(PCIINC) +PCI_COMPRESSED_IDS ?= 0 update-pciids: update-pciids.sh sed <$< >$@ "s@^DEST=.*@DEST=$(IDSDIR)/$(PCI_IDS)@;s@^PCI_COMPRESSED_IDS=.*@PCI_COMPRESSED_IDS=$(PCI_COMPRESSED_IDS)@" chmod +x $@
Signature · 1 line
1.7.8.4
Hello!
Quoted 7 lines
If you build with zlib disabled, then
PCI_COMPRESSED_IDSis not defined, which generates the line in the update script:
PCI_COMPRESSED_IDS=
which in turn causes the update script to warn:
bash: [: : integer expression expectedSo default it to 0 to avoid that logic.
I hope that this is already fixed in the current tree, could you please check?
Have a nice fortnight
Signature · 3 lines
Martin `MJ' Mares <[email protected]> http://mj.ucw.cz/ Faculty of Math and Physics, Charles University, Prague, Czech Rep., Earth Outside of a dog, a book is man's best friend. Inside a dog, it's too dark to read.
Quoted 5 lines · On Monday 01 April 2013 15:52:28 Martin Mares wrote:
Quoted 5 lines
If you build with zlib disabled, then
PCI_COMPRESSED_IDSis not defined,which generates the line in the update script:
PCI_COMPRESSED_IDS=
Quoted 7 lines
Quoted 4 lines
which in turn causes the update script to warn:
bash: [: : integer expression expectedSo default it to 0 to avoid that logic.
I hope that this is already fixed in the current tree, could you please check?
yeah, i think this commit addressed this in a different way:
commit 4339115006b225c8e33b7427cf5dba6b3831a625
Author: Ville Skyttä <[email protected]> Date: Mon May 21 00:35:19 2012 +0300
Fix syntax error when PCI_COMPRESSED_IDS is empty.
-mike