From 7e4ee2b361f6f0e1c0965d220020b347ff56029c Mon Sep 17 00:00:00 2001 From: NIIBE Yutaka Date: Wed, 4 Oct 2017 18:54:16 +0900 Subject: [PATCH] Serial string for GNU/Linux emulation. --- ChangeLog | 3 +++ src/configure | 9 +++++++-- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/ChangeLog b/ChangeLog index 3289621..cef46ae 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,8 @@ 2017-10-04 NIIBE Yutaka + * src/configure (output_vendor_product_serial_strings): Support + GNU/Linux emulation. + * polarssl/library/bignum.c (mpi_div_mpi): Fix for 64-bit machine. * src/main.c (gnuk_malloc, gnuk_free): Fix for 64-bit machine. diff --git a/src/configure b/src/configure index feddae7..90682b1 100755 --- a/src/configure +++ b/src/configure @@ -332,8 +332,13 @@ output_vendor_product_serial_strings () { echo " STRING_DESCRIPTOR, /* bDescriptorType */" echo " /* Serial number: \"$SERIALNO\" */" echo "$SERIALNO" | sed -e "s/\(........\)/\1\\${nl}/g" | sed -n -e "s/\(.\)/'\1', 0, /g" -e "s/^/ /" -e "/^ ./s/ $//p" - echo " 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff," - echo " 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff," + if test "$emulation" = "yes"; then + echo " 'E', 0, 'M', 0, 'U', 0, 'L', 0," + echo " 'A', 0, 'T', 0, 'E', 0, 'D', 0," + else + echo " 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff," + echo " 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff," + fi echo '};' echo echo '#ifdef USB_STRINGS_FOR_GNUK'