Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Godot uses SCsub files to build sub dependencies #43

Open
clemens-tolboom opened this issue Jan 27, 2021 · 7 comments
Open

Godot uses SCsub files to build sub dependencies #43

clemens-tolboom opened this issue Jan 27, 2021 · 7 comments
Labels
build-release Related to the build and release pipeline. enhancement New feature or request

Comments

@clemens-tolboom
Copy link
Contributor

clemens-tolboom commented Jan 27, 2021

In https://github.com/godotengine/godot/blob/master/SConstruct#L630 they use

    # Build subdirs, the build order is dependent on link order.
    SConscript("core/SCsub")

could we use?

# Build the extractor libraries
SConscript("src/raster-tile-extractor/SConstruct")
SConscript("src/vector-extractor/SConstruct")

and would that make the build cleaner?

See also https://scons.org/doc/production/HTML/scons-user.html#chap-hierarchical

@clemens-tolboom
Copy link
Contributor Author

This would probably help with rebuilding from scratch using scons --clean

Oops

vector-extractor clemens$ scons --clean
scons: Reading SConscript files ...
No valid target platform selected.

@kb173
Copy link
Member

kb173 commented Jan 27, 2021

Good idea, I'll try that!

@clemens-tolboom
Copy link
Contributor Author

Godot uses in core/SCsub which gave me an error while testing. The nice effect is the SCsub will become almost empty.

#!/usr/bin/env python

Import("env")

In https://discord.com/channels/571796279483564041/571796280146133047/803911823106506763 I asked about our build results ... we need 4! *.dynlibs .... why can't we build all into one file? I'm a C++ noob/learned it in 1992 :-p

@kb173
Copy link
Member

kb173 commented Jan 27, 2021

I've played around with it a bit, and I'm not 100% sure whether we really want to use that kind of SConscript() call. It does make hierarchical builds easier, but we also want the ability to build only one of the libraries (e.g. when testing new functionality in that part). The paths get mingled with this SConscript() call, which actually makes some things more difficult :/

Still, scons --clean would be quite practical, I'll see if there's another way for that.

@clemens-tolboom
Copy link
Contributor Author

Not sure how your testing goes right now.

Is https://scons.org/doc/production/HTML/scons-user.html#chap-add-method pseudo builder which talks about def BuildTestProg to build for a particular Env which I read as a sub directory.

@kb173 kb173 added enhancement New feature or request build-release Related to the build and release pipeline. labels Jan 28, 2021
@clemens-tolboom
Copy link
Contributor Author

If we align this with how Godot does adding Web, Android and iOS could be easier.

What do you think?

@clemens-tolboom
Copy link
Contributor Author

Any idea?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
build-release Related to the build and release pipeline. enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants