[llvm-commits] Win32/Alarm.inc rev. 64231 : MingW32 error

Kenneth Boyd zaimoni at zaimoni.com
Tue Feb 10 14:11:18 PST 2009


This patch gets the build past this point, leaving only one error to 
speak of.

llvm[1]: Compiling Alarm.cpp for Release-Asserts build
In file included from c:/CPP_App.SVN/llvm.svn/lib/System/Alarm.cpp:32:
c:/CPP_App.SVN/llvm.svn/lib/System/Win32/Alarm.inc: In function 'void 
Sleep(unsigned int)':
c:/CPP_App.SVN/llvm.svn/lib/System/Win32/Alarm.inc:39: error: call of 
overloaded 'Sleep(unsigned int)' is ambiguous
c:/CPP_App.SVN/llvm.svn/lib/System/Win32/Alarm.inc:38: note: candidates 
are: void Sleep(unsigned int)
c:/CPP_App.SVN/llvm.svn/include/llvm/System/Alarm.h:44: 
note:                 void llvm::sys::Sleep(unsigned int)
make[1]: *** 
[/CPP_App.SVN/llvm.svn.optimized-noassert/lib/System/Release-Asserts/Alarm.o] 
Error 1
make[1]: Target `all' not remade because of errors.

Please confirm that this patch enables building at least one MSVC build 
or one MingW32 build before committing.

Kenneth

P.S.: The extern "C" qualification is because I need that to link under 
MingW32 in another project.  It also allows llvm-config to exist rather 
than be vainly regenerated each time.
P.P.S.: the remaining error in a tools-only build,

make[2]: Entering directory 
`C:/CPP_App.SVN/llvm.svn.optimized-noassert/utils/unittest'
if [ ! -f googletest/Makefile ]; then \
      /CPP_App.SVN/llvm.svn/autoconf/mkinstalldirs googletest; \
      /bin/cp /CPP_App.SVN/llvm.svn/utils/unittest/googletest/Makefile 
googletest/Makefile; \
    fi; \
    c:/dev.tools/bin/make -C googletest all
make[3]: Entering directory 
`C:/CPP_App.SVN/llvm.svn.optimized-noassert/utils/unittest/googletest'
llvm[3]: Compiling gtest-filepath.cc for Release-Asserts build
if g++ -I/CPP_App.SVN/llvm.svn/utils/unittest/googletest/include/ 
-Wno-missing-field-initializers -Wno-variadic-macros 
-I/CPP_App.SVN/llvm.svn.optimized-noassert/include 
-I/CPP_App.SVN/llvm.svn.optimized-noassert/utils/unittest/googletest 
-I/CPP_App.SVN/llvm.svn/include 
-I/CPP_App.SVN/llvm.svn/utils/unittest/googletest  -DNDEBUG  
-D_GNU_SOURCE -D__STDC_LIMIT_MACROS -D__STDC_CONSTANT_MACROS -O2 
-fomit-frame-pointer -fno-exceptions  -Woverloaded-virtual -pedantic 
-Wall -W -Wwrite-strings -Wno-long-long -Wunused -Wno-unused-parameter  
-c -MMD -MP -MF 
"/CPP_App.SVN/llvm.svn.optimized-noassert/utils/unittest/googletest/Release-Asserts/gtest-filepath.d.tmp" 
-MT 
"/CPP_App.SVN/llvm.svn.optimized-noassert/utils/unittest/googletest/Release-Asserts/gtest-filepath.lo" 
-MT 
"/CPP_App.SVN/llvm.svn.optimized-noassert/utils/unittest/googletest/Release-Asserts/gtest-filepath.o" 
-MT 
"/CPP_App.SVN/llvm.svn.optimized-noassert/utils/unittest/googletest/Release-Asserts/gtest-filepath.d" 
/CPP_App.SVN/llvm.svn/utils/unittest/googletest/gtest-filepath.cc -o 
/CPP_App.SVN/llvm.svn.optimized-noassert/utils/unittest/googletest/Release-Asserts/gtest-filepath.o 
; \
            then /bin/mv -f 
"/CPP_App.SVN/llvm.svn.optimized-noassert/utils/unittest/googletest/Release-Asserts/gtest-filepath.d.tmp" 
"/CPP_App.SVN/llvm.svn.optimized-noassert/utils/unittest/googletest/Release-Asserts/gtest-filepath.d"; 
else /bin/rm 
"/CPP_App.SVN/llvm.svn.optimized-noassert/utils/unittest/googletest/Release-Asserts/gtest-filepath.d.tmp"; 
exit 1; fi
c:\mingw32\bin\../lib/gcc/mingw32/4.2.1-dw2/../../../../include/io.h: In 
member function 'bool testing::internal::FilePath::CreateFolder() const':
c:\mingw32\bin\../lib/gcc/mingw32/4.2.1-dw2/../../../../include/io.h:176: 
error: too many arguments to function 'int mkdir(const char*)'
c:/CPP_App.SVN/llvm.svn/utils/unittest/googletest/gtest-filepath.cc:277: 
error: at this point in file
make[3]: *** 
[/CPP_App.SVN/llvm.svn.optimized-noassert/utils/unittest/googletest/Release-Asserts/gtest-filepath.o] 
Error 1

appears to be because GTEST_OS_WINDOWS is not defined.  Fixing appears 
to be difficult (there is a todo note in gtest/internals/gtest-port.h 
that GTEST_OS_WINDOWS should be split into more macros, as it currently 
means both "OS is Windows" and "compiler is MSVC".)
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: Alarm.inc.patch
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20090210/d4d29fc1/attachment.ksh>


More information about the llvm-commits mailing list