public inbox for insight-prs@sourceware.org
help / color / mirror / Atom feed
* insight/89: Cygwin build error
@ 2001-05-15  9:03 bahrahm
  0 siblings, 0 replies; 2+ messages in thread
From: bahrahm @ 2001-05-15  9:03 UTC (permalink / raw)
  To: insight-gnats

>Number:         89
>Category:       insight
>Synopsis:       Cygwin build error
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    unassigned
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Tue May 15 09:03:00 PDT 2001
>Closed-Date:
>Last-Modified:
>Originator:     bahrahm@yahoo.com
>Release:        unknown-1.0
>Organization:
>Environment:
cygwin 1.1.18, gcc 2.95.2-6
>Description:
Yesterday, I checked out Insight source code and 
tried to compile on Cygwin. And I got error messages.
The error message was about undeclared types such as
HKEY which is declared winreg.h in cmSystemTools.cxx file. Since windows.h includes winreg.h, the problem
seems to come from complier proprocess definitions.


==============Error Message======================
$ make
cd /cygdrive/d/insight_src/Cygwin/CMake/Source; make CMakeBuildTargets
make[1]: Entering directory `/cygdrive/d/insight_src/Cygwin/CMake/Source'
c++  -g -O2   -c ../../../Insight/CMake/Source/cmSystemTools.cxx -o cmSystemTool
s.o
../../../Insight/CMake/Source/cmSystemTools.cxx: In function `bool ReadAValue(st
ring &, const char *)':
../../../Insight/CMake/Source/cmSystemTools.cxx:207: `HKEY' undeclared (first us
e this function)
../../../Insight/CMake/Source/cmSystemTools.cxx:207: (Each undeclared identifier
 is reported only once
../../../Insight/CMake/Source/cmSystemTools.cxx:207: for each function it appear
s in.)
../../../Insight/CMake/Source/cmSystemTools.cxx:207: parse error before `;'
../../../Insight/CMake/Source/cmSystemTools.cxx:210: `primaryKey' undeclared (fi
rst use this function)
../../../Insight/CMake/Source/cmSystemTools.cxx:210: `HKEY_CURRENT_USER' undecla
red (first use this function)
../../../Insight/CMake/Source/cmSystemTools.cxx:214: `HKEY_CURRENT_CONFIG' undec
lared (first use this function)
../../../Insight/CMake/Source/cmSystemTools.cxx:218: `HKEY_CLASSES_ROOT' undecla
red (first use this function)
../../../Insight/CMake/Source/cmSystemTools.cxx:222: `HKEY_LOCAL_MACHINE' undecl
ared (first use this function)
../../../Insight/CMake/Source/cmSystemTools.cxx:226: `HKEY_USERS' undeclared (fi
rst use this function)
../../../Insight/CMake/Source/cmSystemTools.cxx:229: parse error before `;'
../../../Insight/CMake/Source/cmSystemTools.cxx:231: `KEY_READ' undeclared (firs
t use this function)
../../../Insight/CMake/Source/cmSystemTools.cxx:231: `hKey' undeclared (first us
e this function)
../../../Insight/CMake/Source/cmSystemTools.cxx:231: implicit declaration of fun
ction `int RegOpenKeyEx(...)'
../../../Insight/CMake/Source/cmSystemTools.cxx:231: `ERROR_SUCCESS' undeclared
(first use this function)
../../../Insight/CMake/Source/cmSystemTools.cxx:237: `DWORD' undeclared (first u
se this function)
../../../Insight/CMake/Source/cmSystemTools.cxx:237: parse error before `,'
../../../Insight/CMake/Source/cmSystemTools.cxx:238: `dwSize' undeclared (first
use this function)
../../../Insight/CMake/Source/cmSystemTools.cxx:240: `LPTSTR' undeclared (first
use this function)
../../../Insight/CMake/Source/cmSystemTools.cxx:240: parse error before `.'
../../../Insight/CMake/Source/cmSystemTools.cxx:248: confused by earlier errors,
 bailing out
make[1]: *** [cmSystemTools.o] Error 1
make[1]: Leaving directory `/cygdrive/d/insight_src/Cygwin/CMake/Source'
make: *** [/cygdrive/d/insight_src/Cygwin/CMake/Source/CMakeBuildTargets] Error
2
===================================================

======= Source Code (cmSystemTools.cxx)=============
Line: 48
#if defined(_MSC_VER) || defined(__BORLANDC__)
#include <windows.h>
#include <direct.h>


Line: 179

#ifdef _WIN32

// Get the data of key value.
// Example : 
//      HKEY_LOCAL_MACHINE\SOFTWARE\Python\PythonCore\2.1\InstallPath
//      =>  will return the data of the "default" value of the key
//      HKEY_LOCAL_MACHINE\SOFTWARE\Scriptics\Tcl\8.4;Root
//      =>  will return the data of the "Root" value of the key
bool ReadAValue(std::string &res, const char *key)===================================================

>How-To-Repeat:
"Insight Source Directory"/configure
>Fix:
I added three lines:

#if def _WIN32 
#include <windows.h>
#endif 

at ther top of cmSystemTools.cxx and it seemed to solve
the problem.
>Release-Note:
>Audit-Trail:
>Unformatted:


^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: insight/89: Cygwin build error
@ 2002-01-04 14:09 kseitz
  0 siblings, 0 replies; 2+ messages in thread
From: kseitz @ 2002-01-04 14:09 UTC (permalink / raw)
  To: bahrahm, insight-prs, kseitz, nobody

Synopsis: Cygwin build error

Responsible-Changed-From-To: unassigned->kseitz
Responsible-Changed-By: kseitz
Responsible-Changed-When: Fri Jan  4 14:09:44 2002
Responsible-Changed-Why:
    got it
State-Changed-From-To: open->closed
State-Changed-By: kseitz
State-Changed-When: Fri Jan  4 14:09:44 2002
State-Changed-Why:
    I don't know where you got your Insight source code, but the file you are talking about does not belong to Insight at all. Perhaps you are using some version of Insight bundled by some other group?

http://sources.redhat.com/cgi-bin/gnatsweb.pl?cmd=view&pr=89&database=insight


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2002-01-04 22:09 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2001-05-15  9:03 insight/89: Cygwin build error bahrahm
2002-01-04 14:09 kseitz

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).