Rybadour / Spider-Fish

A simple Bullet Hell Shooter.
socr.uwindsor.ca/~giga
8 stars 4 forks source link

File System Layout #45

Open madebyjeffrey opened 12 years ago

madebyjeffrey commented 12 years ago

Project Directory: .

src/                 All source files that are multiplatform for game code
include/         All include files.
projects/        All projects for different platforms

Under src and include:

platform specific source files:
mac, windows, linux

Any specific sections:
May add libraries such as "collision" but will include platform specific code as above if needed.    

Under projects:

cmake/          
visualstudio10/
xcode/
gnumake/
erisco commented 12 years ago

I do not prefer the multi-platform and platform-specific sources to be in the same ancestry. This is just a preference though. Other than that, I am fine with this new structure.

madebyjeffrey commented 12 years ago

Please give me a specific example of what you mean, your words are not entirely clear. Also, an alternative should be provided if there is something better you can recommend.

erisco commented 12 years ago

src/mac makes mac-specific sources a child directory of multi-platform sources. I'd prefer src to contain exclusively multi-platform sources, and to put platform-specific sources in a directory such as platform/mac. This makes it easier to talk about all multi-platform sources and all platform-specific sources separately.

From a utility standpoint, for example, if I want to search for all multi-platform sources with the keyword "PhysicalEntity" using grep, I don't want to have to do fancy-work to exclude the platform-specific directories. From a logical standpoint, platform-specific isn't a specialization or refinement of multi-platform; rather, the two are mutually exclusive. Therefore, just like you wouldn't put your jpeg pictures in your text document directory, it doesn't make sense to put platform-specific sources in a multi-platform directory.

If it is desired to still group multi-platform and platform-specific together, we can have src/multi for multi-platform and src/mac, src/win, src/unix, and so on.