[Lldb-commits] [lldb] r203781 - Hide some declarations from mingw.
Saleem Abdulrasool
compnerd at compnerd.org
Fri Mar 14 19:53:43 PDT 2014
On Thu, Mar 13, 2014 at 3:42 AM, Hafiz Abid Qadeer <hafiz_abid at mentor.com>wrote:
> Author: abidh
> Date: Thu Mar 13 05:42:28 2014
> New Revision: 203781
>
> URL: http://llvm.org/viewvc/llvm-project?rev=203781&view=rev
> Log:
> Hide some declarations from mingw.
>
Given this description, I don't think that this change is the proper way to
handle this. Can you change the #ifdef _MSC_VER to if
!defined(__MINGW32__) please? _MSC_VER indicates that you are using either
the Microsoft compiler or clang with Microsoft compatibility.
> Modified:
> lldb/trunk/tools/driver/Platform.cpp
> lldb/trunk/tools/driver/Platform.h
>
> Modified: lldb/trunk/tools/driver/Platform.cpp
> URL:
> http://llvm.org/viewvc/llvm-project/lldb/trunk/tools/driver/Platform.cpp?rev=203781&r1=203780&r2=203781&view=diff
>
> ==============================================================================
> --- lldb/trunk/tools/driver/Platform.cpp (original)
> +++ lldb/trunk/tools/driver/Platform.cpp Thu Mar 13 05:42:28 2014
> @@ -84,6 +84,7 @@ tcgetattr (int fildes, struct termios *t
> return -1;
> }
>
> +#ifdef _MSC_VER
> sighandler_t
> signal (int sig, sighandler_t sigFunc)
> {
> @@ -106,5 +107,6 @@ signal (int sig, sighandler_t sigFunc)
> }
> return 0;
> }
> +#endif
>
> #endif
>
> Modified: lldb/trunk/tools/driver/Platform.h
> URL:
> http://llvm.org/viewvc/llvm-project/lldb/trunk/tools/driver/Platform.h?rev=203781&r1=203780&r2=203781&view=diff
>
> ==============================================================================
> --- lldb/trunk/tools/driver/Platform.h (original)
> +++ lldb/trunk/tools/driver/Platform.h Thu Mar 13 05:42:28 2014
> @@ -16,18 +16,13 @@
>
> // this will stop signal.h being included
> #define _INC_SIGNAL
> -
> #include <io.h>
> +#if defined( _MSC_VER )
> #include <eh.h>
> +#endif
> #include <inttypes.h>
> #include "lldb/Host/windows/windows.h"
>
> - struct timeval
> - {
> - long tv_sec;
> - long tv_usec;
> - };
> -
> struct winsize
> {
> long ws_col;
> @@ -65,13 +60,8 @@
> speed_t c_ospeed; // output speed
> };
>
> - typedef long pid_t;
> -
> #define STDIN_FILENO 0
>
> - #define PATH_MAX MAX_PATH
> - #define snprintf _snprintf
> -
> extern int ioctl( int d, int request, ... );
> extern int kill ( pid_t pid, int sig );
> extern int tcsetattr( int fd, int optional_actions, const struct
> termios *termios_p );
> @@ -86,7 +76,18 @@
> #define SIG_DFL ( (sighandler_t) -1 )
> // ignored
> #define SIG_IGN ( (sighandler_t) -2 )
> +
> +#ifdef _MSC_VER
> + struct timeval
> + {
> + long tv_sec;
> + long tv_usec;
> + };
> + typedef long pid_t;
> + #define snprintf _snprintf
> extern sighandler_t signal( int sig, sighandler_t );
> + #define PATH_MAX MAX_PATH
> +#endif
>
> #else
>
>
>
> _______________________________________________
> lldb-commits mailing list
> lldb-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/lldb-commits
>
--
Saleem Abdulrasool
compnerd (at) compnerd (dot) org
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/lldb-commits/attachments/20140314/e7d03f1b/attachment.html>
More information about the lldb-commits
mailing list