Re: Inconsist in Makefile for Geant4 and ROOT functionality.

From: Ivana Hrivnacova <Ivana.Hrivnacova_at_cern.ch>
Date: Mon, 28 Jul 2008 15:03:57 +0200

]Dear Rafal,

I think that the only consistent solution is what you proposed as solution2:
to get etc directory via root-config.
Fons, is it possible to implement
this option in root-config?

Best regards,

Ivana

Rafal Lalik wrote:
> Dear All,
>
> I am little bit confused about Makefile for Geant4-VMC (and also other
> Geants as i remember). Lets quote something:
>
> --- CUT HERE ---
>
> ifeq ($(ROOTSYS),)
> ROOT_INCDIR = $(shell root-config --incdir)
> ROOT_BINDIR = $(shell root-config --prefix)/bin
> ROOT_ETCDIR = $(shell root-config --prefix)/etc/vmc
> else
> ROOT_INCDIR = $(ROOTSYS)/include
> ROOT_BINDIR = $(ROOTSYS)/bin
> ROOT_ETCDIR = $(ROOTSYS)/etc/vmc
> endif
>
> include $(ROOT_ETCDIR)/Makefile.$(PLATFORM)
>
>
> --- END of CUT HERE ---
>
> This part show us how ROOT_*DIR are prepared.
>
> Lets look also to ./configure script for root:
>
> --- CUT HERE ---
>
> ./configure --help
> `configure' configures ROOT 5.18/00d to adapt to many kind of systems.
>
> Usage: ./configure [architecture] [flag=value]
>
> The architecture to build for will be guessed from the output of 'uname'.
> If, however, that fails, or you don't want the 'native' compiler on the
> host platform, you can specify the architecture to use by passing as the
> FIRST argument one of the architecures given at the end of this message.
>
> FLAG DESCRIPTION DEFAULT
> --aclocaldir Autoconf macro install dir(<prefix>/share/aclocal)
> --bindir Binary installation dir (<prefix>/bin)
> --build Build configuration [debug, exceptions, ...],
> overrides the ROOTBUILD shell variable
> --cintincdir CINT interpeted headers (<libdir>/cint)
> --datadir Data installation dir (<prefix>/share/root)
> --docdir Documentation (<prefix>/share/doc/root)
> --elispdir Where to put Emacs Lisp
> (<prefix>/share/emacs/site-lisp)
> --etcdir Config installation dir (/etc/root)
> --fontdir Font installation dir (<datadir>/fonts)
> --iconpath Icon installation dir (<datadir>/icons)
> --incdir Header installation dir (<prefix>/include/root)
> --libdir Library installation dir (<prefix>/lib/root)
> --macrodir Macro installation dir (<datadir>/macros)
> --mandir Manpages installation dir (<prefix>/share/man/man1)
> --no-create Do not create output files, dry run
> --prefix Installation prefix (/usr/local)
> --srcdir Sources installation dir (<datadir>/src)
> --testdir Tests (<docdir>/test)
> --tutdir Tutorials (<docdir>/tutorial)
>
> If any of the flags --cintincdir, --datadir, --docdir, --etcdir, --iconpath
> --incdir, --libdir, --macrodir, --mandir, or --prefix is given,
> ROOT will be compiled with static directory names, and you should not set
> the ROOTSYS environment variable.
>
> --- END of CUT HERE ---
>
>
> This part: --etcdir Config installation dir (/etc/root)
> shows that default --etcdir is without prefix and variable --prefix will
> have
> affect to all variables excluding etcdir.
>
> But your Makefile for Geant4, for case where $ROOTSYS is not set, include
> this prefix:
> ROOT_ETCDIR = $(shell root-config --prefix)/etc/vmc
> Whatmore, even if --prefix=/ for ROOT, then this path is wrong:
> /etc/vmc instead of /etc/root/vmc
>
> This is a little bit confusing for me, and i see two solutions for this:
> 1. Small patch for Makefile:
> --- CUT HERE ---
> --- Makefile.old 2008-07-24 00:22:00.000000000 +0200
> +++ Makefile 2008-07-24 00:22:19.000000000 +0200
> @@ -27,7 +27,7 @@
> ifeq ($(ROOTSYS),)
> ROOT_INCDIR = $(shell root-config --incdir)
> ROOT_BINDIR = $(shell root-config --prefix)/bin
> -ROOT_ETCDIR = $(shell root-config --prefix)/etc/vmc
> +ROOT_ETCDIR = /etc/root/vmc
> else
> ROOT_INCDIR = $(ROOTSYS)/include
> ROOT_BINDIR = $(ROOTSYS)/bin
> --- END of CUT HERE ---
> But it is not good solutions still. What if I use --etcdir variable for
> ROOT?
>
> 2. Ask guys from ROOT to add options --etcdir for root-config to get this
> value. Maybe I should forward this e-mail to them?
> I have prepeared patches for root-config which include this features.
>
> Best regards,
>
> Rafal Lalik
>
>
> PS. https://savannah.cern.ch/bugs/?39259 Lets look what ROOT developers
> say about this.
>
> --Rafal Lalik
> GSI Darmstadt
> E-mail: R.Lalik_at_gsi.de
> Phone: +49-6159-71 1321
> Skype: r.lalik
> Department: Detektorlabor
> Location: C12 1.003
>
>
> Gesellschaft für Schwerionenforschung mbH
> Planckstraße 1
> D-64291 Darmstadt
> www.gsi.de
>
> Limited Liability Company
> Registered Office: Darmstadt, Commercial Register: Darmstadt, HRB 1528,
>
> Managing Directors: Professor Dr. Horst Stöcker, Dr. Alexander Kurz,
>
> Supervisory Board Chair: Dr. Beatrix Vierkorn-Rudolph,
> Deputy Chair: Ministerialdirigent Dr. Rolf Bernhardt
>

-- 
==============================================================
e-mail:  Ivana.Hrivnacova_at_cern.ch
address: Institut Physique Nucleaire, 91406 Orsay, France
phone:   (33) 01 69 15 65 94
==============================================================
Received on Mon Jul 28 2008 - 14:58:44 CEST

This archive was generated by hypermail 2.2.0 : Mon Jul 28 2008 - 17:25:01 CEST