From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 21633 invoked by alias); 22 Jul 2009 19:34:30 -0000 Received: (qmail 21607 invoked by uid 22791); 22 Jul 2009 19:34:28 -0000 X-SWARE-Spam-Status: No, hits=-0.3 required=5.0 tests=AWL,BAYES_50,J_CHICKENPOX_21,SPF_PASS,UPPERCASE_50_75 X-Spam-Check-By: sourceware.org Received: from mercav15.na.sas.com (HELO mercav15.na.sas.com) (149.173.6.149) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Wed, 22 Jul 2009 19:34:20 +0000 X-TM-IMSS-Message-ID:<729f804700093411@mercav15.na.sas.com> Received: from tempo.in.teragram.com ([172.25.89.16]) by mercav15.na.sas.com ([10.19.9.223]) with ESMTP (TREND IMSS SMTP Service 7.0; TLS: TLSv1/SSLv3,256bits,AES256-SHA) id 729f804700093411 ; Wed, 22 Jul 2009 15:34:18 -0500 Received: from vmw0314.na.sas.com ([10.16.12.215] helo=vmw0314 ident=dgomez) by tempo.in.teragram.com with esmtp (Exim 4.63) (envelope-from ) id 1MThZx-0004kO-Lr for pthreads-win32@sourceware.org; Wed, 22 Jul 2009 15:34:17 -0400 Reply-To: From: "Daniel Richard G." To: Subject: [PATCH] Preprocessor fixes Date: Wed, 22 Jul 2009 19:34:00 -0000 Message-ID: <000601ca0b03$674f0600$35ed1200$@com> X-IsSubscribed: yes Mailing-List: contact pthreads-win32-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: pthreads-win32-owner@sourceware.org X-SW-Source: 2009/txt/msg00034.txt.bz2 Hello, I am using pthreads-win32 for a project in conjunction with MSVC. It is working well, but there were a few minor preprocessor issues that I'd like to see fixed in the upstream. A patch against CVS is attached, and here is a summary of the changes: * Renamed HAVE_CONFIG_H to PTW32_HAVE_CONFIG_H. The problem is that our project uses HAVE_CONFIG_H/config.h, and the #include in pthread.h leads to a double-inclusion of the config header. (The real issue is that pthread.h shouldn't be #including config.h in the first place---that should be happening at the top of each .c file that needs it---but I'm punting.) * HAVE_SIGNAL_H and/or __GNUC__ might not be #defined, so either use #ifdef or defined() to guard against preprocessor warnings * In sched.h, renamed PTW32_LEVEL to PTW32_SCHED_LEVEL, and PTW32_LEVEL_MAX to PTW32_SCHED_LEVEL_MAX, to avoid any potential conflict with the same symbols #defined in pthread.h I look forward to the forthcoming 2.9.0 release :-) --Daniel -- Daniel Richard G. || danielg@teragram.com || Software Developer Teragram Linguistic Technologies (a division of SAS) http://www.teragram.com/ begin 666 ptw32-tweaks.patch M26YD97@Z($)M86ME9FEL90H]/3T]/3T]/3T]/3T]/3T]/3T]/3T]/3T]/3T] M/3T]/3T]/3T]/3T]/3T]/3T]/3T]/3T]/3T]/3T]/3T]/3T]/3T]"E)#4R!F M:6QE.B O8W9S+W!T:')E861S+7=I;C,R+W!T:')E861S+T)M86ME9FEL92QV M"G)E=')I979I;F<@#H@1TY5;6%K969I;&4*/3T]/3T]/3T] M/3T]/3T]/3T]/3T]/3T]/3T]/3T]/3T]/3T]/3T]/3T]/3T]/3T]/3T]/3T] M/3T]/3T]/3T]/3T]/0I20U,@9FEL93H@+V-V#H@36%K969I;&4*/3T]/3T]/3T]/3T]/3T]/3T]/3T]/3T]/3T] M/3T]/3T]/3T]/3T]/3T]/3T]/3T]/3T]/3T]/3T]/3T]/3T]/3T]/0I20U,@ M9FEL93H@+V-V#H@2!03U-)6" J+PH@(V5N9&EF"B *("-I9B!D969I M;F5D*%]03U-)6%]#7U-/55)#12D@)B8@7U!/4TE87T-?4T]54D-%(#X](#$Y M.3,P.0HM(W5N9&5F(%!45S,R7TQ%5D5,"BTC9&5F:6YE(%!45S,R7TQ%5D5, M(#$**R-U;F1E9B!05%'1E;G-I;VYS("HO"B C96YD:68*( HM M(V1E9FEN92!05%6]U7,O='EP97,N:#X*("\J(%)E<75I