Library with nested source file structure

Andreas Pakulat apaku at gmx.de
Fri Jun 30 14:20:27 BST 2006


On 30.06.06 14:27:02, Ingolf Steinbach wrote:
> Andreas Pakulat schrieb:
> > Just create a subproject for
> > include and for src, then in that create subprojects for each module.
> > Then you should be able to add whatever filenames you want, they only
> > have to be "unique" within that subproject (each subproject maps to a
> > directory).
> 
> Yes, that works (i.e. adding the files). However, these subprojects do
> not each produce a separate library but just contribute to the *one*
> library. It is not clear to me how to specify that.

To me neither, because I'm not autotools guru. First thing you should do
is read the autobook, it tells you the basics of autotools, which you
need to know to be able to work with the automake-manager.

I might be wrong, but each module should create a convenience library
which is then statically linked into the shared library.

For any such lib you need to create a target in the subproject. But
that's really all I know of this.

> > If you still have problems, please provide the steps to reproduce this
> > on a simple automake-based project.
> 
> See my example in the original post. The output of the top-
> level project should be *one* library plus all the public
> header files.

Well, the Makefile produced by the top-level-Makefile.am normally only
starts executing the subproject Makefiles. And all that should be done
during a simple make call, is building a shared lib in src/. make
install of course should copy also the include-files, but I don't really
know how this works with kdevelop.

I'd suggest you look around and find a project that already exists and
uses a similar layout. Then you can import that into kdevelop and see
what the autotools manager displays and try to adapt it to your own
project.

Andreas

-- 
You have no real enemies.




More information about the KDevelop mailing list