diff --git a/ChangeLog b/ChangeLog index d1f76ae..47a4035 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,9 @@ 2012-06-01 Niibe Yutaka + * src/configure (usb-strings.c.inc): ifdef-out + gnuk_revision_detail and gnuk_config_options (for reGNUal). + * src/usb_desc.c (USB_STRINGS_FOR_GNUK): Define. + USB bug fixes. * src/usb_ctrl.c (gnuk_usb_event): Bug fix for handling USB_EVENT_CONFIG. Do nothing when current_conf == value. diff --git a/src/configure b/src/configure index 908b602..80796c7 100755 --- a/src/configure +++ b/src/configure @@ -214,6 +214,7 @@ if !(IFS=" " echo $PRODUCT | sed -n -e "s/\(........\)/\1\n/gp" | sed -n -e "s/\(.\)/'\1', 0, /g" -e "s/^/ /" -e "s/ $//p" echo '};' echo + echo '#ifdef USB_STRINGS_FOR_GNUK' echo 'static const uint8_t gnuk_revision_detail[] = {' echo " ${#REVISION}*2+2, /* bLength */" echo " USB_STRING_DESCRIPTOR_TYPE, /* bDescriptorType */" @@ -227,6 +228,7 @@ if !(IFS=" " echo " /* configure options: \"$CONFIG\" */" echo $CONFIG | sed -n -e "s/\(........\)/\1\n/gp" | sed -n -e "s/\(.\)/'\1', 0, /g" -e "s/^/ /" -e "s/ $//p" echo '};' + echo '#endif' ) >usb-strings.c.inc exit 0 fi diff --git a/src/usb_desc.c b/src/usb_desc.c index 681d41f..a7c1af6 100644 --- a/src/usb_desc.c +++ b/src/usb_desc.c @@ -254,6 +254,7 @@ static const uint8_t gnukStringLangID[] = { 0x09, 0x04 /* LangID = 0x0409: US-English */ }; +#define USB_STRINGS_FOR_GNUK 1 #include "usb-strings.c.inc" const uint8_t gnukStringSerial[] = {