gittup / tup

Tup is a file-based build system.
http://gittup.org/tup/
GNU General Public License v2.0
1.17k stars 145 forks source link

Using existing copies of lua, pcre2, sqlite3 instead of built-in copies #494

Open ryandesign opened 7 months ago

ryandesign commented 7 months ago

I see that tup bundles lua 5.4.6, pcre2 10.42, and sqlite3 3.45.2. I already have these installed on my system, and in the case of pcre2 my version is newer. How can I tell tup to use these existing libraries instead of building its own?

gittup commented 7 months ago

Lua is slightly modified in tup to support things like the += operand, so if you used a local version you would find that some Tupfile.luas would fail to parse. As such, there isn't a supported way to use a local version, though you could modify tup's own Tupfiles yourself if you were interested in pursuing this.

SQLite3 is also built-in by default for performance reasons, though it is not modified from the stock version (other than to specify specific compilation flags). You can use a local libsqlite3 by adding this to the tup.config used to build tup:

CONFIG_TUP_USE_SYSTEM_SQLITE=y

For pcre2, the embedded version is only used on Windows since there isn't a native packaged version easy to use. On Linux and macOS, the system's libpcre2 is used by default.

ryandesign commented 6 months ago

SQLite3 is also built-in by default for performance reasons

How would SQLite3 being built-in result in better performance than an external SQLite3?

adding this to the tup.config used to build tup

What's tup.config? See #496.