Closed NQNStudios closed 1 month ago
I tested it locally on a fresh clone and actually it needs a couple more things.
Ok, I just tested it locally and a fresh clone on linux can just run scons
as long as they have all the dependencies, plus cmake
to build TGUI
- Catch2 is now a subtree, not a submodule, because subtrees automatically clone without
git clone --recursive
orgit submodule update --init
I'm a bit unsure about this part…
It's basically the same as a submodule, but we'll never have to remind anyone to call submodule update --init
. I pulled the same version of Catch2 as we were using before.
If Catch2 were an optional dependency I could see an advantage to not always cloning it. But currently we have a state where everyone who tries to build from a normal git clone will get an easily avoidable compiler error--I don't see the point.
After reading up on subtree and checking why I made Catch a submodule in the first place, I'm even less sold on the idea of the subtree. If the only issue is that submodules aren't automatically cloned, I think I'd rather just add a step in scons that makes sure the submodules are present before building things that depend on them. In other words, have scons call git submodule update --init
for you.
And I also notice that you made TGUI a subtree here. I think linking it in as a submodule would actually be a good idea. I guess that would suggest that scons then needs to call cmake for TGUI, which is really weird, but whatever.
People building with Xcode or Visual Studio will still fall into the trap of Catch2 being missing, though
On Thu, May 30, 2024 at 5:46 PM Celtic Minstrel @.***> wrote:
After reading up on subtree and checking why I made Catch a submodule in the first place, I'm even less sold on the idea of the subtree. If the only issue is that submodules aren't automatically cloned, I think I'd rather just add a step in scons that makes sure the submodules are present before building things that depend on them. In other words, have scons call git submodule update --init for you.
And I also notice that you made TGUI a subtree here. I think linking it in as a submodule would actually be a good idea.
— Reply to this email directly, view it on GitHub https://github.com/calref/cboe/pull/356#issuecomment-2141011044, or unsubscribe https://github.com/notifications/unsubscribe-auth/AATXBKMHSNXV7RNFR7MV3B3ZE6233AVCNFSM6AAAAABIRMYIL2VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDCNBRGAYTCMBUGQ . You are receiving this because you authored the thread.Message ID: @.***>
That's true, but people building with Xcode or Visual Studio would still be able to build the game even if Catch is missing. They'd only get a build failure if they try to build the tests. (This should be true of scons too, I just haven't bothered to work out how to make scons have multiple targets.)
I went through all of @clort81's challenges when building the latest source code, and added automation/documentation for everything with a known solution.
git clone --recursive
orgit submodule update --init