Modify testEnv to set all enviro vars from printchplenv

[reviewed by Sung]

Some tests, such as test/io/extern/ferguson/externblock, have a
SKIPIF file that use a Chapel configuration environment variable
that is often not set. In that case, the CHPL_LLVM environment
variable is automatically set by chplenv/llvm if it detects
a built LLVM, but start_test/testEnv doesn't know about that. This
patch modifies testEnv to set all values from printchplenv so
that they can be used in .skipif or SKIPIF files.



git-svn-id: http://svn.code.sf.net/p/chapel/code/trunk@21841 3a8e244f-b0f2-452b-bcba-4c88e055c3ca
Fix memory trashing bug when CHPL_MAKE or --make is set

[reviewed by Brad]

The command-line parsing program had type S256 for CHPL_MAKE,
even though it was declared as a const char* pointer. That meant that
it would just overwrite the next several bytes in memory
if the variable was ever set. We added a 256-byte long
static variable, makeArgument, and asked the command-line parsing
to call handleMake, which just sets CHPL_MAKE to point to
makeArgument. 



git-svn-id: http://svn.code.sf.net/p/chapel/code/trunk@21842 3a8e244f-b0f2-452b-bcba-4c88e055c3ca
Simplify definitions of c_sublocid_any/c_sublocid_curr for LLVM backend

[reviewed by Greg]

The LLVM backend can only handle relatively simple #defines.
This patch fixes up c_sublocid_any and c_sublocid_curr to
have a form supported by #define parsing code in clangUtil.cpp:
 -#define c_sublocid_any  ((c_sublocid_t) -1)
 -#define c_sublocid_curr ((c_sublocid_t) -2)
 +#define c_sublocid_any  (-1)
 +#define c_sublocid_curr (-2)

Removing the cast makes these expressions simple enough, and I
believe we can rely on the C integer promotion/demotion rules
to do the right thing if c_sublocid_t ever becomes anything other
than int.



git-svn-id: http://svn.code.sf.net/p/chapel/code/trunk@21843 3a8e244f-b0f2-452b-bcba-4c88e055c3ca
Fix problem with regexp re.sub in multilocale

[trivial and not reviewed]

regexp.sub suffered from some of the same problems
Tom fixed earlier (size field in wide string not
set properly after extern function produces string).

This patch fixes that problem by:
 - changing the C interface for substitution
   (qio_regexp_replace) to return a string length
   (so that zeros could even be in the string
    although I havn't tested that yet).
 - adding a call to string_normalize after
   calls to qio_regexp_replace in Regexp.chpl



git-svn-id: http://svn.code.sf.net/p/chapel/code/trunk@21844 3a8e244f-b0f2-452b-bcba-4c88e055c3ca
Add support for negative constants in #define-parsing for LLVM backend

[trivial and not reviewed]

This patch enables the LLVM backend to use C headers containing e.g.
 #define SOME_NUMBER (-10)

Previously, only positive numbers were supported.
Also adds tests for this and a few other cases.



git-svn-id: http://svn.code.sf.net/p/chapel/code/trunk@21845 3a8e244f-b0f2-452b-bcba-4c88e055c3ca