How to add a specific .o file generated (with cmake)
Laurent Montel
montel at kde.org
Wed Oct 18 18:10:46 CEST 2006
On Wednesday 18 October 2006 17:58, Alexander Neundorf wrote:
> On Wednesday 18 October 2006 17:42, Laurent Montel wrote:
> > Hi,
> > Into kalzium we generate a .o file.
> > We want to link it with kalzium binary.
> >
> > How is it possible to specify a obj file when we want to create a binary
> > ? (obj file is a C file)
>
> Can you please explain a bit more ? It sounds a bit like a hack.
We have an object file generated (into kdeedu/kalzium/src/solver/) with ocalm
program.
We generate directly a obj file.
After we must add this object file when we will create binary kalzium.
For the moment I try to use :
set_source_files_properties (
eqresult.cpp PROPERTIES
OBJECT_DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/solver.o
)
For the moment it's not perfect.
ocalm doesn't generate a lib but just an object file
> It should be possible to add the object file with the full path either to
> the sources or using target_link_libraries(). I never did that, but I can
> vaguely remember some message on the mailing list already quite long ago.
> Bye
> Alex
More information about the Kde-buildsystem
mailing list