From: Jouk Jansen Date: Wed, 16 Jan 2002 15:07:55 +0000 (+0000) Subject: Committing in . X-Git-Url: https://git.saurik.com/wxWidgets.git/commitdiff_plain/a7aef4a92a72f7c8bd251893190ee60702dbddc1 Committing in . update OpenVMS compile support Modified Files: wxWindows/setup.h_vms wxWindows/include/wx/thread.h wxWindows/src/common/descrip.mms wxWindows/src/common/iffdecod.cpp wxWindows/src/unix/threadpsx.cpp ---------------------------------------------------------------------- git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@13604 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- diff --git a/include/wx/thread.h b/include/wx/thread.h index ff86535a78..72c708e51f 100644 --- a/include/wx/thread.h +++ b/include/wx/thread.h @@ -289,8 +289,13 @@ public: // Get the platform specific thread ID and return as a long. This // can be used to uniquely identify threads, even if they are not // wxThreads. This is used by wxPython. - static unsigned long GetCurrentId(); - + // On VMS thread pointers are 64 bits (also needed for other systems??? +#ifdef __VMS + static unsigned long long GetCurrentId(); +#else + static unsigned long GetCurrentId(); +#endif + // sets the concurrency level: this is, roughly, the number of threads // the system tries to schedule to run in parallel. 0 means the // default value (usually acceptable, but may not yield the best diff --git a/setup.h_vms b/setup.h_vms index 17ef3a44ae..259a74575b 100644 --- a/setup.h_vms +++ b/setup.h_vms @@ -838,6 +838,11 @@ */ #define wxUSE_PCX 1 +/* + * IFF image format support + */ +#define wxUSE_IFF 1 + /* * PNM image format support */ @@ -848,6 +853,11 @@ */ #define wxUSE_XPM 1 +/* + * MS Icons and Cursors format support + */ +#define wxUSE_ICO_CUR 0 + /* * Disable this if your compiler can't cope * with omission of prototype parameters. diff --git a/src/common/descrip.mms b/src/common/descrip.mms index 5222a3b78d..6483ecf8fd 100644 --- a/src/common/descrip.mms +++ b/src/common/descrip.mms @@ -85,10 +85,12 @@ OBJECTS1=fs_inet.obj,\ hash.obj,\ helpbase.obj,\ http.obj,\ + iffdecod.obj,\ imagall.obj,\ imagbmp.obj,\ image.obj,\ imaggif.obj,\ + imagiff.obj,\ imagjpeg.obj,\ imagpcx.obj,\ imagpng.obj,\ @@ -199,10 +201,12 @@ SOURCES = \ hash.cpp,\ helpbase.cpp,\ http.cpp,\ + iffdecod.cpp,\ imagall.cpp,\ imagbmp.cpp,\ image.cpp,\ imaggif.cpp,\ + imagiff.cpp,\ imagjpeg.cpp,\ imagpcx.cpp,\ imagpng.cpp,\ @@ -345,10 +349,12 @@ gifdecod.obj : gifdecod.cpp hash.obj : hash.cpp helpbase.obj : helpbase.cpp http.obj : http.cpp +iffdecod.obj : iffdecod.cpp imagall.obj : imagall.cpp imagbmp.obj : imagbmp.cpp image.obj : image.cpp imaggif.obj : imaggif.cpp +imagiff.obj : imagiff.cpp imagjpeg.obj : imagjpeg.cpp imagpcx.obj : imagpcx.cpp imagpng.obj : imagpng.cpp diff --git a/src/common/iffdecod.cpp b/src/common/iffdecod.cpp index 423f182d10..803d302f87 100644 --- a/src/common/iffdecod.cpp +++ b/src/common/iffdecod.cpp @@ -312,8 +312,15 @@ int wxIFFDecoder::ReadIFF() while (dataptr + 8 <= dataend) { // get chunk length and make even size_t chunkLen = (iff_getlong(dataptr + 4) + 1) & 0xfffffffe; - if (chunkLen < 0) { // format error? - break; +#ifdef __VMS + // Silence compiler warning + int chunkLen_; + chunkLen_ = chunkLen; + if (chunkLen_ < 0) { // format error? +#else + if (chunkLen < 0) { // format error? +#endif + break; } bool truncated = (dataptr + 8 + chunkLen > dataend); diff --git a/src/unix/threadpsx.cpp b/src/unix/threadpsx.cpp index 50278f17ae..e10fe97e82 100644 --- a/src/unix/threadpsx.cpp +++ b/src/unix/threadpsx.cpp @@ -928,9 +928,17 @@ int wxThread::GetCPUCount() return -1; } +#ifdef __VMS + // VMS is a 64 bit system and threads have 64 bit pointers. + // ??? also needed for other systems???? +unsigned long long wxThread::GetCurrentId() +{ + return (unsigned long long)pthread_self(); +#else unsigned long wxThread::GetCurrentId() { return (unsigned long)pthread_self(); +#endif } bool wxThread::SetConcurrency(size_t level)