components/hwdata/Makefile
branchs11-update
changeset 4136 e1ea793cf007
parent 3996 20c0f21bbe1e
--- a/components/hwdata/Makefile	Thu Apr 16 01:14:23 2015 -0700
+++ b/components/hwdata/Makefile	Fri Apr 10 17:16:13 2015 -0700
@@ -25,8 +25,8 @@
 COMPONENT_NAME=         hwdata
 COMPONENT_VERSION=      0.5.11
 
-TPNO_PCI=	7530
-TPNO_USB=	7831
+TPNO_PCI=	21782
+TPNO_USB=	21783
 
 include $(WS_MAKE_RULES)/ips.mk
 
@@ -38,7 +38,9 @@
 # When it's time to update, you can use these rules to download with
 # 'gmake -B pci.ids usb.ids'   After updating the data files, ensure
 # that the header with version/date and license info is still being 
-# correctly extracted and copied into the generated license files.
+# correctly extracted and copied into the generated license files,
+# and run 'gmake test' to verify there are no invalid or control chars
+# in the files.
 
 download::
 	@echo 'No downloads for this component'
@@ -71,6 +73,8 @@
 LICENSES = $(ID_FILES:%=%.license)
 BUILT_LICENSES = $(LICENSES:%=$(BUILD_DIR)/%)
 
+ASLR_MODE = $(ASLR_NOT_APPLICABLE)
+
 # Extract the header up to the first blank line
 $(BUILD_DIR)/%.header: %
 	$(MKDIR) $(@D)
@@ -84,7 +88,19 @@
 
 install build: $(BUILT_LICENSES)
 
-test:	$(NO_TESTS)
+# Ensure there are no control characters/escape sequences or invalid UTF-8
+# characters in the *.ids text files.
+test: $(BUILD_DIR)
+	@ export LC_ALL='en_US.UTF-8' ; \
+	for f in $(ID_FILES) ; do \
+		tr -cd '[:print:][:space:]' < $$f > $(BUILD_DIR)/$$f.clean \
+		&& diff -u $$f $(BUILD_DIR)/$$f.clean ; \
+		if (( $$? == 0 )) ; then \
+			print $$f PASSED ; \
+		else \
+			print $$f FAILED ; \
+		fi \
+	done
 
 clobber clean::
 	$(RM) -r $(BUILD_DIR)