Problem 414 - problem in binmake.gmk
Summary: problem in binmake.gmk
Status: RESOLVED WORKSFORME
Alias: None
Product: Geant4
Classification: Unclassified
Component: config (show other problems)
Version: 4.1
Hardware: PC Linux
: P2 normal
Assignee: Gabriele Cosmo
URL:
Depends on:
Blocks:
 
Reported: 2002-09-27 04:14 CEST by harald.vogt
Modified: 2002-10-09 08:58 CEST (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this problem.
Description harald.vogt 2002-09-27 04:14:14 CEST
Geant4.4.1.p01 installation with gcc 3.2 under SuSE 7.2 on an Intel PC

I observed a problem when installing Geant4 with global shared libs.
The novice examples do not link beacause for global libs the library
libG3toG4.so is included in the link procedure and this will produce
undefined references. Deleting line 194 in binmake.gmk I can link and
run the examples.

Please include in the Linux-g++.gmk file the additional compiler warning
option -Wno-long-long to avoid a lot of useless warnings at least for
gcc 3.x compilers. For those compilers also CLHEP/config/CLHEP.h needs
a modification if used with Geant4. One has to replace the includes
stdlib.h, limits.h, math.h, by cstdlib, limits, cmath which come with
the compilers c++ includes. This avoides warnings like:
#include_next is a GCC extension
changing search order for system directory "/usr/include"
as it has already been specified as a non-system directory
(see also http://gcc.gnu.org/ml/gcc-bugs/2001-02/msg00124.html)

Harald Vogt
Comment 1 Gabriele Cosmo 2002-10-08 10:50:59 CEST
> I observed a problem when installing Geant4 with global shared libs.
> The novice examples do not link beacause for global libs the library
> libG3toG4.so is included in the link procedure and this will produce
> undefined references. Deleting line 194 in binmake.gmk I can link and
> run the examples.

In the next release of Geant4, we plan to make optional the installation
of the g3tog4 module, so that such problem won't occur anymore.

> Please include in the Linux-g++.gmk file the additional compiler warning
> option -Wno-long-long to avoid a lot of useless warnings at least for
> gcc 3.x compilers. For those compilers also CLHEP/config/CLHEP.h needs
> a modification if used with Geant4. One has to replace the includes
> stdlib.h, limits.h, math.h, by cstdlib, limits, cmath which come with
> the compilers c++ includes. This avoides warnings like:
> #include_next is a GCC extension
> changing search order for system directory "/usr/include"
> as it has already been specified as a non-system directory
> (see also http://gcc.gnu.org/ml/gcc-bugs/2001-02/msg00124.html)

Although gcc-3.2 is not yet a supported compiler, we verified that
both CLHEP and Geant4 install and compile correctly (with very limited
number of known warnings) in the 3.X series and no particular modification
is necessary.
The user may want to check the installation of the compiler in the system,
verifying all necessary components are installed in the default system
area /usr (and not /usr/local), similarly for the CLHEP library.
Thanks.
Comment 2 Gabriele Cosmo 2002-10-09 08:22:59 CEST
Harald Vogt writes:
>
> + The user may want to check the installation of the compiler in the system,
> + verifying all necessary components are installed in the default system
> + area /usr (and not /usr/local), similarly for the CLHEP library.

This requirement may be a strong restriction using a new gcc compiler in
unix environments. A lot of installations in our institution are put in
a /products tree. The gcc installation enables such special directory tree
and it is useful in an afs based environment (@sys selection of OS'ses).
For SuSE 7.2 we had the problem I mentioned already some time ago with
std:cout for the "gcc version 2.95.3 20010315 (SuSE)" which comes with
the distribution in /usr .
With CLHEP only there are no installation problems for both compiler
versions.
Comment 3 Gabriele Cosmo 2002-10-09 08:58:59 CEST
Hi Harald,

> This requirement may be a strong restriction using a new gcc compiler in
> unix environments. A lot of installations in our institution are put in
> a /products tree. The gcc installation enables such special directory tree
> and it is useful in an afs based environment (@sys selection of OS'ses).
> For SuSE 7.2 we had the problem I mentioned already some time ago with
> std:cout for the "gcc version 2.95.3 20010315 (SuSE)" which comes with
> the distribution in /usr .
> With CLHEP only there are no installation problems for both compiler
> versions.

 the problem you're reporting is actually to be considered a system/compiler
 configuration issue, more than a problem related to the Geant4 setup.
 As for CLHEP, this has to be solved within the context of CLHEP support
 and I'll forward your request to them (please, do so next time!).

 As for the other problems you reported (-Wno-long-long ...), we could
 not reproduce them with gcc-3.2 (and previous 3.X versions) on a RH-7.2
 system, few known warnings are generated (Geant4 4.1, patch-01). Which
 warnings are you referring to ?

 Cheers.