Fixed Makefile and warnings in cygwin/mingw

git-svn-id: https://svn.pjsip.org/repos/pjproject/trunk@142 74dad513-b988-da41-8d7b-12977e46ad98
diff --git a/pjlib-util/build/Makefile b/pjlib-util/build/Makefile
index c9bdc24..b163a0a 100644
--- a/pjlib-util/build/Makefile
+++ b/pjlib-util/build/Makefile
@@ -22,7 +22,7 @@
 #
 export PJLIB_UTIL_SRCDIR = ../src/pjlib-util
 export PJLIB_UTIL_OBJS += $(OS_OBJS) $(M_OBJS) $(CC_OBJS) $(HOST_OBJS) \
-		md5.o scanner.o stun.o stun_client.o xml.o
+		md5.o scanner.o stun.o string.o stun.o stun_client.o xml.o
 export PJLIB_UTIL_CFLAGS += $(_CFLAGS)
 
 ###############################################################################
diff --git a/pjlib-util/include/pjlib-util/scanner_cis_bitwise.h b/pjlib-util/include/pjlib-util/scanner_cis_bitwise.h
index 3f46694..9d0b2ad 100644
--- a/pjlib-util/include/pjlib-util/scanner_cis_bitwise.h
+++ b/pjlib-util/include/pjlib-util/scanner_cis_bitwise.h
@@ -69,7 +69,7 @@
  * @param cis       Pointer to character input specification.
  * @param c         The character.
  */
-#define PJ_CIS_SET(cis,c)   ((cis)->cis_buf[(c)] |= (1 << (cis)->cis_id))
+#define PJ_CIS_SET(cis,c)   ((cis)->cis_buf[(int)(c)] |= (1 << (cis)->cis_id))
 
 /**
  * Remove the membership of the specified character.
@@ -78,7 +78,7 @@
  * @param cis       Pointer to character input specification.
  * @param c         The character to be removed from the membership.
  */
-#define PJ_CIS_CLR(cis,c)   ((cis)->cis_buf[c] &= ~(1 << (cis)->cis_id))
+#define PJ_CIS_CLR(cis,c)   ((cis)->cis_buf[(int)c] &= ~(1 << (cis)->cis_id))
 
 /**
  * Check the membership of the specified character.
@@ -87,7 +87,7 @@
  * @param cis       Pointer to character input specification.
  * @param c         The character.
  */
-#define PJ_CIS_ISSET(cis,c) ((cis)->cis_buf[c] & (1 << (cis)->cis_id))
+#define PJ_CIS_ISSET(cis,c) ((cis)->cis_buf[(int)c] & (1 << (cis)->cis_id))
 
 
 
diff --git a/pjlib-util/include/pjlib-util/scanner_cis_uint.h b/pjlib-util/include/pjlib-util/scanner_cis_uint.h
index eb779f6..ea01011 100644
--- a/pjlib-util/include/pjlib-util/scanner_cis_uint.h
+++ b/pjlib-util/include/pjlib-util/scanner_cis_uint.h
@@ -56,7 +56,7 @@
  * @param cis       Pointer to character input specification.
  * @param c         The character.
  */
-#define PJ_CIS_SET(cis,c)   ((cis)->cis_buf[(c)] = 1)
+#define PJ_CIS_SET(cis,c)   ((cis)->cis_buf[(int)(c)] = 1)
 
 /**
  * Remove the membership of the specified character.
@@ -65,7 +65,7 @@
  * @param cis       Pointer to character input specification.
  * @param c         The character to be removed from the membership.
  */
-#define PJ_CIS_CLR(cis,c)   ((cis)->cis_buf[c] = 0)
+#define PJ_CIS_CLR(cis,c)   ((cis)->cis_buf[(int)c] = 0)
 
 /**
  * Check the membership of the specified character.
@@ -74,7 +74,7 @@
  * @param cis       Pointer to character input specification.
  * @param c         The character.
  */
-#define PJ_CIS_ISSET(cis,c) ((cis)->cis_buf[c])
+#define PJ_CIS_ISSET(cis,c) ((cis)->cis_buf[(int)c])
 
 
 
diff --git a/pjlib-util/src/pjlib-util/scanner.c b/pjlib-util/src/pjlib-util/scanner.c
index 0c6899b..0447377 100644
--- a/pjlib-util/src/pjlib-util/scanner.c
+++ b/pjlib-util/src/pjlib-util/scanner.c
@@ -483,8 +483,6 @@
 PJ_DEF(void) pj_scan_advance_n( pj_scanner *scanner,
 				 unsigned N, pj_bool_t skip_ws)
 {
-    char *start = scanner->curptr;
-
     if (scanner->curptr + N > scanner->end) {
 	pj_scan_syntax_err(scanner);
 	return;