Message: Re: Cmake error on Windows 7 Not Logged In (login)
 Next-in-Thread Next-in-Thread
 Next-in-Forum Next-in-Forum

None Re: Cmake error on Windows 7 

Forum: Installation and Configuration
Re: None Cmake error on Windows 7 (Tom Roberts)
Date: 13 Apr, 2015
From: Ben Morgan <Ben Morgan>

On Tue, 07 Apr 2015 16:47:47 GMT, Tom Roberts wrote:
> I am using scripts that worked in Geant4.9.6 on Windows Xp. Because
> using GUIs is such a burden, I am trying to use my scripts for
> Geant4.10.01. A very similar script works for Geant4.10.01 on Mac OS X.
> 
> This is Windows 7 with Cygwin and VS2013. Note that all paths are in
> Cygwin's mixed mode so tools from both MS and Cygwin will understand
> them. This of course makes all paths quite long.
> 
> The C++ compiler is cl (Visual Studio 2013), but Cygwin's g++ is also
> available as some libraries use it to generate dependencies.
> 
> The script has already built Coin3D and installed it into
> $HOME/G4beamlineBuild; it uses static libraries, as does my Geant4
> build.
> 
> This is an abridged listing of the error (e.g. I omitted all options).
> 
>  $ cygpath -m $HOME
>  C:/cygwin/home/tjrob
> 
>  $ cygpath -m $PWD
>  C:/cygwin/home/tjrob/G4beamlineBuild
> 
>  $ cmake --version
>  cmake version 3.1.2
> 
>  $ cmake -G 'Unix Makefiles' C:/cygwin/home/tjrob/G4beamline-2.17b-source/LibrarySource/geant4.10.01
>  ...
>  CMake Error: File C:/cygwin/home/tjrob/G4beamline-2.17b-source/LibrarySource/geant4.10.01/C:/cygwin/home/tjrob/G4beamline-2.17b-source/LibrarySource/geant4.10.01/cmake/Templates/geant4_validate_sources.cmake.in does not exist.
>  CMake Error at C:/cygwin/home/tjrob/G4beamline-2.17b-source/LibrarySource/geant4.10.01/cmake/Modules/Geant4ValidateSources.cmake:12 (configure_file):
>   configure_file Problem configuring file
>  Call Stack (most recent call first):
>   C:/cygwin/home/tjrob/G4beamline-2.17b-source/LibrarySource/geant4.10.01/CMakeLists.txt:90 (include)
> 
> Somehow it is concatenating two absolute paths, which of course yields
> nonsense. The first is the Geant4 source (C:/.../geant4.10.01), and the
> second is the full path of the file
> "cmake/Templates/geant4_validate_sources.cmake.in" relative to the
> Geant4 source. Obviously this second should be the relative path, not
> the absolute path. But I cannot figure out where that comes from -- the
> file it names looks OK. So possibly ${PROJECT_SOURCE_DIR} got two copies
> of the absolute path.
> 
> Any suggestions? Has anyone else built geant4.10.01 via a script?
> 
> I also noticed that cmake is going to use g++, not cl -- that will cause
> it to fail. In geant4.9.6 it used cl. I have no idea what changed, but
> it was not my script. But I must fix the above error first.
> 

Cygwin isn't a supported/tested platform, so I can only make an initial guess here (until I can get a Cygwin install done). Is the installed cmake Windows native, or Cygwin (built from source or via a package)? It's possible that may make a difference, but if things were working with 9.6 under the same system, it's possible there's an incorrect/badly quoted path or no cygwin adaption in the Geant4 CMake scripts.

Sorry I can't be more immediate help, as noted I'll take a look once I have Cygwin running. In the meantime, it could be worth having a search through the CMake mailing list for similar issues, as this likely has much better infor than I currently do:

 Add Message Add Message
to: "Re: Cmake error on Windows 7"

 Subscribe Subscribe

This site runs SLAC HyperNews version 1.11-slac-98, derived from the original HyperNews


[ Geant 4 Home | Geant 4 HyperNews | Search | Request New Forum | Feedback ]