Garfield installation issue

yes i did it…


now again in the /home/ahmer/Desktop/garfield
mkdir build
cd build
source thisroot.sh
cmake
make
like this?

As I said in my first reply, the file garfield-v2.tar.gz has nothing to do with Garfield++ and is of no use for building or running Garfield++.

ok dear i understand. now i have to make build directory in garfield-v2 and cmake, make and make install in this?

Dear i have mkdir in the garfield-v2. and cmake, make, and make install. all this and i’m here now. is it ok?
installation complete? anything else to do?

Looks good!

1 Like

i want to ask one more thing my head asked me to do cmake with full examples and docs on but the program was giving errors and i have done it with just cmake $GARFIELD_HOME. can you see what the issue or can i resolve it?

solution that i told you better understanding do not use the tar file etc. just make a directory and git clone command and when its done follow the procedure as hschindl told us. and you can see mine questions and issues as i discussed with hschindl.

Building the examples is switched on by default, so just typing

cmake $GARFIELD_HOME

as you did is fine.

PS: the square brackets in cmake [-DCMAKE_INSTALL_PREFIX=...] and so on indicate optional arguments. So you would have to remove the square brackets ([]) when you type the command.

ok ok thanks a lot hschindl. i’m really very sorry that i have very much disturb you. thanks a lot. and what you think as i typed the command line which represents the paths about the geant4.sh. is it interface with the geant4 or not?

i have tried to run the geant4garfieldinterface example and its giving errors during the cmake can i get some help?

Hello @ahmer_k,

It seems that the Garfield header directory is not part of the compiler search path. Please, check the CMake configuration log (the output of the cmake command) to see any relevant error/warning messages, e.g. Cannot find Garfield package or so.

Cheers,
J.

Is it possible that you forgot to source the setup.sh script in the Garfield++ build folder?
Can you type echo $CMAKE_PREFIX_PATH and see if it includes the Garfield++ install directory?

ok dear thanks for your time. i’ll check.

nope. i did it at the end and send you screenshot. ok dear i’ll check thank you.

see i have this is it ok? i was running an example.

i did it further like this and again this happend.

As I said earlier, you need to source the setup.sh script in $GARFIELD_HOME/build.
Please do the following:

cd ~/Desktop/garfield-v2/Examples/Geant4GarfieldInterface/
rm  -rf build
mkdir build
cd build
source /home/ahmer/Desktop/root/test_build/bin/thisroot.sh
source /home/ahmer/Desktop/Geant4/geant4.10.06.p01-install/bin/geant4.sh
source /home/ahmer/Desktop/garfield-v2/build/setup.sh
cmake ..
make

ooo…thanks dear i thought as i have done it once in installation no need to do it now. i’ll do like this. thank you.

thanks a lot dear you have solved my problem. thanks a lot again. :slight_smile: