Modify

Opened 15 years ago

Closed 14 years ago

#21 closed defect (fixed)

Failing to compile/link on SLC5/64bit with gcc 4.1.2

Reported by: andre.philippe.sailer@… Owned by: /C=FR/O=CNRS/OU=UMR8607/CN=Guy Le Meur/emailAddress=lemeur@…
Priority: major Milestone:
Component: GuineaPig++ Version:
Keywords: Cc: barbara.dalena@…

Description

If I try to compile guineapig++ 1.0.12 on SLC5 64bit with the gcc version 4.1.2 the compiler(linker?) ends with the following error messages:

Application guineapig++
------> (constituents.make) Starting guineapig++
------> (guineapig++.make) Rebuilding ../amd64_linux26/guineapig++_dependencies.make
../amd64_linux26/principal.o: In function `mainGuineapig(char**)':
principal.cc:(.text+0x7c): undefined reference to `GUINEA::GUINEA(char*)'
principal.cc:(.text+0x8c): undefined reference to `GUINEA::run(char*, char*)'
../amd64_linux26/principal.o: In function `PARTICLE_BEAM::~PARTICLE_BEAM()':
principal.cc:(.text._ZN13PARTICLE_BEAMD1Ev[PARTICLE_BEAM::~PARTICLE_BEAM()]+0x1e): undefined reference to `vtable for PARTICLE_BEAM'
principal.cc:(.text._ZN13PARTICLE_BEAMD1Ev[PARTICLE_BEAM::~PARTICLE_BEAM()]+0x26): undefined reference to `vtable for PARTICLE_BEAM'
../amd64_linux26/principal.o: In function `BEAM::~BEAM()':
principal.cc:(.text._ZN4BEAMD0Ev[BEAM::~BEAM()]+0x6c): undefined reference to `PHOTON_BEAM::~PHOTON_BEAM()'
principal.cc:(.text._ZN4BEAMD0Ev[BEAM::~BEAM()]+0xa2): undefined reference to `PHOTON_BEAM::~PHOTON_BEAM()'
../amd64_linux26/principal.o: In function `BEAM::~BEAM()':
principal.cc:(.text._ZN4BEAMD1Ev[BEAM::~BEAM()]+0x6c): undefined reference to `PHOTON_BEAM::~PHOTON_BEAM()'
principal.cc:(.text._ZN4BEAMD1Ev[BEAM::~BEAM()]+0x9b): undefined reference to `PHOTON_BEAM::~PHOTON_BEAM()'
../amd64_linux26/principal.o: In function `BEAM::output_flow() const':
principal.cc:(.text._ZNK4BEAM11output_flowEv[BEAM::output_flow() const]+0x442): undefined reference to `PARTICLE_BEAM::output_flow() const'
principal.cc:(.text._ZNK4BEAM11output_flowEv[BEAM::output_flow() const]+0x46a): undefined reference to `PARTICLE_BEAM::meanLostEnergy(float) const'
../amd64_linux26/principal.o: In function `PAIR_BEAM::~PAIR_BEAM()':
principal.cc:(.text._ZN9PAIR_BEAMD1Ev[PAIR_BEAM::~PAIR_BEAM()]+0x14): undefined reference to `vtable for PAIR_BEAM'
../amd64_linux26/principal.o: In function `GUINEA::~GUINEA()':
principal.cc:(.text._ZN6GUINEAD1Ev[GUINEA::~GUINEA()]+0x21): undefined reference to `vtable for GUINEA'
principal.cc:(.text._ZN6GUINEAD1Ev[GUINEA::~GUINEA()]+0x1af): undefined reference to `SPLINE::~SPLINE()'
principal.cc:(.text._ZN6GUINEAD1Ev[GUINEA::~GUINEA()]+0x1b7): undefined reference to `SPLINE::~SPLINE()'
principal.cc:(.text._ZN6GUINEAD1Ev[GUINEA::~GUINEA()]+0x240): undefined reference to `PHOTON_BEAM::~PHOTON_BEAM()'
principal.cc:(.text._ZN6GUINEAD1Ev[GUINEA::~GUINEA()]+0x2bd): undefined reference to `PHOTON_BEAM::~PHOTON_BEAM()'
principal.cc:(.text._ZN6GUINEAD1Ev[GUINEA::~GUINEA()]+0x2f1): undefined reference to `GRID::~GRID()'
principal.cc:(.text._ZN6GUINEAD1Ev[GUINEA::~GUINEA()]+0x30a): undefined reference to `file_close'
principal.cc:(.text._ZN6GUINEAD1Ev[GUINEA::~GUINEA()]+0x4b8): undefined reference to `SPLINE::~SPLINE()'
principal.cc:(.text._ZN6GUINEAD1Ev[GUINEA::~GUINEA()]+0x4c0): undefined reference to `SPLINE::~SPLINE()'
principal.cc:(.text._ZN6GUINEAD1Ev[GUINEA::~GUINEA()]+0x549): undefined reference to `PHOTON_BEAM::~PHOTON_BEAM()'
principal.cc:(.text._ZN6GUINEAD1Ev[GUINEA::~GUINEA()]+0x5c6): undefined reference to `PHOTON_BEAM::~PHOTON_BEAM()'
principal.cc:(.text._ZN6GUINEAD1Ev[GUINEA::~GUINEA()]+0x5fa): undefined reference to `GRID::~GRID()'
principal.cc:(.text._ZN6GUINEAD1Ev[GUINEA::~GUINEA()]+0x613): undefined reference to `file_close'
principal.cc:(.text._ZN6GUINEAD1Ev[GUINEA::~GUINEA()]+0x6c5): undefined reference to `PHOTON_BEAM::~PHOTON_BEAM()'
principal.cc:(.text._ZN6GUINEAD1Ev[GUINEA::~GUINEA()]+0x6f0): undefined reference to `PHOTON_BEAM::~PHOTON_BEAM()'
collect2: ld returned 1 exit status
mv: cannot stat `guineapig++.exe.new': No such file or directory
gmake[3]: *** [../amd64_linux26/guineapig++.exe] Error 1
gmake[2]: *** [guineapig++] Error 2
gmake[1]: *** [common_target] Error 2
gmake: *** [check_config] Error 2

See attached file for complete compiler output

Attachments (1)

outputcompile.txt (15.1 KB) - added by andre.philippe.sailer@… 15 years ago.
output from the compiler

Download all attachments as: .zip

Change History (6)

Changed 15 years ago by andre.philippe.sailer@…

Attachment: outputcompile.txt added

output from the compiler

comment:1 Changed 15 years ago by andre.philippe.sailer@…

Hello Again,

I think I found the problem. I copied all the files from the tar-ball to a different directory. Instead of guineapig++ I used gp++ as the root directory. This caused some of the paths for the linking to point to a wrong path.

If I keep the files in the guineapig++ there is no problem...

Maybe the makefiles can be changed to be independent of the path? Or some warning to keep the files in guineapig++ folder?

Thanks and best regards, André

comment:2 Changed 15 years ago by /C=FR/O=CNRS/OU=UMR8607/CN=Guy Le Meur/emailAddress=lemeur@…

Owner: set to /C=FR/O=CNRS/OU=UMR8607/CN=Guy Le Meur/emailAddress=lemeur@…
Status: newaccepted

comment:3 in reply to:  2 Changed 15 years ago by /C=FR/O=CNRS/OU=UMR8607/CN=Guy Le Meur/emailAddress=lemeur@…

Replying to /C=FR/O=CNRS/OU=UMR8607/CN=Guy Le Meur/emailAddress=lemeur@…:

Hello,

The problem is that the software CMT generates automatically the makfile. In order to do that one has to adopt a minimum convention. The convention is that a package is entirely characterized by its name. FOr example, if a package nedds somme library from an other package, the links are constructed through the name of this other package. For this reason the localization of packages has to be cohernet with the packages names. It is reasonable to assume thzt a package lies under the folder with its names. So the answer to the problem you ezncountered, would be to emit a warning when the folder name is not correct.

thank you,

Guy

comment:4 Changed 14 years ago by /C=FR/O=CNRS/OU=UMR8607/CN=Guy Le Meur/emailAddress=lemeur@…

Status: acceptednew

comment:5 Changed 14 years ago by /C=FR/O=CNRS/OU=UMR8607/CN=Guy Le Meur/emailAddress=lemeur@…

Resolution: fixed
Status: newclosed

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain /C=FR/O=CNRS/OU=UMR8607/CN=Guy Le Meur/emailAddress=lemeur@….
The resolution will be deleted. Next status will be 'reopened'.

Add Comment


E-mail address and name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.