Re: [anjuta-list] Fwd: Project Structure
- From: Sébastien Granjoux <seb sfo free fr>
- To: Victor Bernado <vbernado gmail com>
- Cc: anjuta-list gnome org
- Subject: Re: [anjuta-list] Fwd: Project Structure
- Date: Sun, 01 May 2011 23:14:33 +0200
Hi,
Le 01/05/2011 19:31, Victor Bernado a écrit :
At C++ I miss the "package" not for de concept, but for de structure of
clases. For example, I have 2 clases (I have more, but for the example
is enought) Biker and BikerDAO, and I would have a directory for
"entities" and another for "DAO" under "src", the src directoy will be:
-src
|-entities
| |-biker.h
| |-biker.cc
| |-....
|-DAO
| |-bikerDAO.h
| |-bikerDAO.cc
| |-....
|-main.cc
I don't know if that is possible in C++, but I think that it could be.
I was trying to do it with Anjuta. To create de directoy structure I
think that I have to create a group "entites" and a group "DAO", and
under everyone of this groups, I need to create a target but, what type
of target? I think that static library won't be correct, and dynamic
library too. Header filer perhaps? or miscelaneous data?
I already try it, and when I compile the target "domain" (it seems like
entities), the output is "no rule to make target 'domain'". And when I
compile the main it apear various "undefined references" to functions of
the clases at entities "package".
What is it the wrong action?
The main issue is not with C++ but with autotools project which is the
default and the most advanced project backend in Anjuta.
A group is more than just a directory, it is a directory and a
Makefile.am file. This file contains targets which can be compiled
independently.
So you can create a group for entities and another one for DAO. Then I
think you have to create a static library target in each group and
assign all your source files to it. Then you need a program target for
your main program and set its library properties to use those two static
libraries.
Another solution is to create only two directories for entities and DA0
and one target for your main program and add all your source files to it
(with the subdirectories source files when needed). I'm not sure adding
source files in a subdirectory can be done with the GUI currently
though. I think you have to edit the Makefile.am file in the src
directory with a text editor.
Where I can find I good documentation of
Anjuta, because the Anjuta IDE Manual isn't helpful for this.
That's the best documentation at the moment. We are currently rewriting
the documentation using a new format (Mallard) but it will be for the
next release (3.2). You can still get it from git here:
http://git.gnome.org/browse/anjuta/tree/manuals/anjuta-manual/C
and read it running "yelp index.page" if you have a recent version of
yelp. Else There are links on some tuturials on Anjuta web site too.
Anyway, I don't think it describes your case.
Thanks, and sorry for my english, I'm spanish...
No problem, most people here haven't english as their mother tongue.
Regards,
Sébastien
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]