Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / fpc-pascal / 2010-06

linking name issue

4 messages · 3 people ·

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

spir

Hello,

I have renamed a unit previously called "UnitType" to "UnitSystem". The unit name itself, its file name, and the name used to import it in a uses clause inside a testing program where all changed. But the linker still expects the previous name:
testUnit.pas(78,1) Warning: Object UnitType.o not found, Linking may fail ! testUnit.pas(79,1) Error: Error while linking
Note: UnitSystem compile finely, UnitSystem.o exists. I'm blocked!

Denis
________________________________

vit esse estrany ☣

spir.wikidot.com

Jonas Maebe
to spir
spir wrote 5 lines
I have renamed a unit previously called "UnitType" to "UnitSystem". The unit name itself, its file name, and the name used to import it in a uses clause inside a testing program where all changed. But the linker still expects the previous name: testUnit.pas(78,1) Warning: Object UnitType.o not found, Linking may fail ! testUnit.pas(79,1) Error: Error while linking Note: UnitSystem compile finely, UnitSystem.o exists.

Maybe you did not recompile all units that used the old unit name? Try rebuilding the program (compile with the -B option, or delete all .ppu files).

Jonas

spir
to David Emerson
Try deleting testunit.o and/or testunit.a, testunit.ppu

Yes, there was another unit still referencing "UnitType" -- but not used by the TestUnit test prog. Strange that it may prevent testUnit to compile and link. Anything, deleted all but .pas files and it works fine. Thank you for your help.

Denis
________________________________

vit esse estrany ☣

spir.wikidot.com