Horde3D

Next-Generation Graphics Engine
It is currently 28.03.2024, 09:21

All times are UTC + 1 hour




Post new topic Reply to topic  [ 40 posts ]  Go to page Previous  1, 2, 3
Author Message
PostPosted: 11.10.2010, 03:05 
Offline

Joined: 30.09.2010, 03:06
Posts: 21
Reviving a little this topic.

I have do a setup of a *partial* mercurial repo here but the thing that I want to suguest is:

  • The directory organization
  • Elimination of the files like *.sln and pass completely to cmake-gui (which helps a lot)
  • Use a directory for output like BUILD (which is ignored by default in .hgignore, where cmake outputs its files, and tells the target to build there mainly files like *.obj and so on).


Practically the first 2 folders there: Binaries and CMake should be deleted (they really doesn' t contain src code... and the output of each one depends on the plataform used). Content moved to the top. Extensions and Horde3D as their own: Bindings, Samples and Documentation (thought they can be moved to at the top and you have all the samples on the same dir and the documentation on the same dir. Doing it what is left is the source code and the bindings for Horde3D or the Terrain extension alone, an extra tidy up would be to have a folder for *.h and *.c if that makes any sense).

By the way, inside the TOP CMakeLists.txt I have added
Code:
SET(THEBASE ${CMAKE_SOURCE_DIR})


So that is possible use things like here

Code:
include_directories(${THEBASE}/Horde3D/Bindings/C++)
include_directories(${THEBASE}/Horde3D/Samples/glfw)


Inside others CMakeLists.txt instead of relative ../.. paths.

I also have included a tutorials folder for use this little organization.


--------------------- edit
I like to see if some one has http://www.ivy.fr/mercurial/ref/v1.0/Me ... 120dpi.png I mean I like the visual dispoay for git http://ktown.kde.org/~zrusin/git/git-ch ... medium.png.


Top
 Profile  
Reply with quote  
PostPosted: 11.10.2010, 15:36 
Offline

Joined: 30.09.2010, 03:06
Posts: 21
By the way, if you want to put the host at university I suguest http://www.indefero.net/open-source/ which I haven't used at all, but I guess is nice to try?


Top
 Profile  
Reply with quote  
PostPosted: 12.10.2010, 22:13 
Offline
Engine Developer

Joined: 10.09.2006, 15:52
Posts: 1217
I wonder what the main advantages are that you see for your proposed structure.

tyoc213 wrote:
Elimination of the files like *.sln and pass completely to cmake-gui (which helps a lot)

MSVC is the standard in the games industry and I assume it is the main development environment for a lot of our users. Not every Windows developer has installed or likes to use CMake ;)

tyoc213 wrote:
Use a directory for output like BUILD (which is ignored by default in .hgignore, where cmake outputs its files, and tells the target to build there mainly files like *.obj and so on).

All temporary files of the build process are already written to a folder Build.

tyoc213 wrote:
Practically the first 2 folders there: Binaries and CMake should be deleted

We have a Binaries folder because the official package contains precompiled binaries for Windows. That way people can easily try out the samples and developers using bindings for other languages don't have to compile the code. All this is not really required but provides some convenience.


Top
 Profile  
Reply with quote  
PostPosted: 13.10.2010, 00:12 
Offline

Joined: 22.11.2007, 17:05
Posts: 707
Location: Boston, MA
marciano wrote:
tyoc213 wrote:
Use a directory for output like BUILD (which is ignored by default in .hgignore, where cmake outputs its files, and tells the target to build there mainly files like *.obj and so on).
All temporary files of the build process are already written to a folder Build.
The key here is the case. Uppercase BUILD is ignored by default by mercurial, so won't be mistakenly checked in to a repository.
Quote:
We have a Binaries folder because the official package contains precompiled binaries for Windows. That way people can easily try out the samples and developers using bindings for other languages don't have to compile the code. All this is not really required but provides some convenience.
In some ways I would agree with tyoc that the binary samples should be separate from the source distribution, and not checked into the source repository. We could build them with each release, and package them in a separate download.

_________________
Tristam MacDonald - [swiftcoding]


Top
 Profile  
Reply with quote  
PostPosted: 13.10.2010, 20:25 
Offline

Joined: 30.09.2010, 03:06
Posts: 21
Quote:
The key here is the case. Uppercase BUILD is ignored by default by mercurial, so won't be mistakenly checked in to a repository.

Not exactly, in my .hgignore I only have 2 rules nothing more.

Code:
glob:BUILD/*
glob:Binaries/Debug/*


Like a newcomer and hobbyist (I'm still learning GLSL which I wanted to learn long time a go... so), when I saw those sln files and have installed VS C++ 2010 (and C#), I clicked on them run and when building I get errors in the output about mismatched name and output... so I go for correcting errors like this, and in a later post I explain how to add a "new project" with my assumptions about the migration changes to the properties of the project I have done... like you see there I have marqued them as deprecated and actually I'm writing about how to use cmake-gui for do the correct job: compile main sources and add your own source.

I think if a project provides a way to do things, then the ones that use it (yeah is like the tabs in python that some people say "why!!!!") should get used to it. That is why I request to forget sln files (and because compatibility issues with anterior and new VS 2010).

I have used previously cmake in Linux for some work and watching that there are CMakeLists.txt in folders doesn't have apealed me to use cmake, but instead to migrate first with the automatic wizard and then modifying "manually" the configurations.


About the adventages... they are mainly about structure personally I will like to see for example glfw in a top folder called externals or some like that.


But at less let me say that the main adventage is

  • To add SET(THEBASE ${CMAKE_SOURCE_DIR}) to main CMakeLists.txt let 'know' in subfolders wher CMakeLists.txt is pressent where the real path is

Because is more easy to know where the other things are knowing the initial base, specially samples... (also I guess glfw could be inside a top "external" folder).

  • Moving Content to THEBASE let you have only one Content dir which can be used for the extensions and the code base (I think they don't overlap), and samples, and maybe tutorials? without need to calculate 2 different paths (like the Terrain sample setup of content).
  • Using only CMake let you choose if build or not Terrain, Samples.

That is why I say to forget sln files... shame that like I see for anterior VS and 2010 are named the same not like vcproj and vcxproj.


-------------- edit

Actually asking I know this now...

CMAKE_SOURCE_DIR *is* the "top" directory, it remains the same even on subfolders.
CMAKE_CURRENT_SOURCE_DIR to get the subfolder's source dir.

So THEBASE is not necesary... so I guess you should use that info for rewrite some of the cmake files.


Top
 Profile  
Reply with quote  
PostPosted: 13.10.2010, 20:45 
Offline

Joined: 30.09.2010, 03:06
Posts: 21
swiftcoder wrote:
Quote:
We have a Binaries folder because the official package contains precompiled binaries for Windows. That way people can easily try out the samples and developers using bindings for other languages don't have to compile the code. All this is not really required but provides some convenience.
In some ways I would agree with tyoc that the binary samples should be separate from the source distribution, and not checked into the source repository. We could build them with each release, and package them in a separate download.


More than that, you can divide source files in: src and iclude when packaging the distribution with exe and content, also include the headers and the lib for star coding without the real source ;).


Top
 Profile  
Reply with quote  
PostPosted: 09.11.2010, 19:04 
Offline

Joined: 09.11.2010, 17:29
Posts: 2
have you guys ever considered hosting horde3d at code.google.com, plus switching to mercurial? thats what im using right now and i can only praise the google guys for creating such amazing repository :-)

_________________
http://indiegamelab.tumblr.com


Top
 Profile  
Reply with quote  
PostPosted: 09.11.2010, 19:09 
Offline

Joined: 15.06.2008, 11:21
Posts: 166
Location: Germany
I actually don't know any reason for choosing code.google.com over bitbucket. My experience with google code is a bit old already, but when I tried it completely lacked proper support for personal forks etc, while at the same time not having and features bitbucket does not have.


Top
 Profile  
Reply with quote  
PostPosted: 10.11.2010, 00:12 
Offline

Joined: 22.11.2007, 17:05
Posts: 707
Location: Boston, MA
phoenix64 wrote:
I actually don't know any reason for choosing code.google.com over bitbucket. My experience with google code is a bit old already, but when I tried it completely lacked proper support for personal forks etc, while at the same time not having and features bitbucket does not have.
That has been my general impression as well.

Moreover, the longer I use Mercurial, the more I begin to question my initial evaluation that mercurial was a superior product to Git. Apart from Windows support, Git seems to outdo Mercurial in most areas - particularly change-set management.

_________________
Tristam MacDonald - [swiftcoding]


Top
 Profile  
Reply with quote  
PostPosted: 10.11.2010, 16:26 
Offline

Joined: 15.06.2008, 11:21
Posts: 166
Location: Germany
Actually, my only problem with mercurial is how much effort stable branches take (no real branches available, one has to setup separate repos). Besides that, mercurial is fine - as long as one has the rebase plugin.

But the windows isssues might really outweight this one, I didn't look very far yet, but here it keeps complaining about what I think are EOL changes even if it is supposed to use clever encoding.


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 40 posts ]  Go to page Previous  1, 2, 3

All times are UTC + 1 hour


Who is online

Users browsing this forum: No registered users and 17 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB® Forum Software © phpBB Group