Questions tagged [tup]

Tup is a file-based build system for Linux, OSX, and Windows. It inputs a list of file changes and a directed acyclic graph (DAG), then processes the DAG to execute the appropriate commands required to update dependent files.

Tup is a file-based build system for Linux, OSX, and Windows. It inputs a list of file changes and a directed acyclic graph (DAG), then processes the DAG to execute the appropriate commands required to update dependent files. Updates are performed with very little overhead since tup implements powerful build algorithms to avoid doing unnecessary work. This means you can stay focused on your project rather than on your build system.

Tup's manual and informational site can be found at http://gittup.org/tup.

23 questions
27
votes
2 answers

LLDB not showing source code

I am trying to debug a C++ program I am writing, but when I run it in LLDB and stop the program, it only shows me the assembler, not the original source. e.g. after the crash I’m trying to debug: Process 86122 stopped * thread #13: tid = 0x142181,…
Leo
  • 4,217
  • 4
  • 25
  • 41
6
votes
1 answer

Compiling using VS tools and Tup build-system

I am trying to compile an interpreter for the J programming language called "unbox" which can be found at: https://github.com/iocane/unbox It uses the tup build-system and the github instructions specify to use the tup command from the Visual…
TheYogi
  • 976
  • 8
  • 15
5
votes
3 answers

Why does tup need one Tupfile per directory?

I've read a lot about the tup build system. In many places, it is said that tup "does not support recursive rules" and that you need to have one Tupfile per directory. Yet I have not seen an official statement or explanation. Is the above claim…
nh2
  • 24,526
  • 11
  • 79
  • 128
4
votes
1 answer

Using Lua libraries from within tup

I'm using tup to replace a complicated Makefile and I'd like to call out to other Lua libraries from my tup code. In particular. I'd like to use luafilesystem and yaml to generate build rules. However, I can't find a way to load these libraries from…
Wicker
  • 43
  • 2
3
votes
1 answer

Git commit SHA as part of tup-built binary

I'm building a project with tup and would like to include the current commit's SHA into the binary. The problem is that tup doesn't recognize dependencies in the .git directory and the version file is not rebuild when the git HEAD changes. The…
Julian Stecklina
  • 1,271
  • 1
  • 10
  • 24
3
votes
1 answer

Wildcard for subdirectories in Tupfile

I'd like to know if there's any wildcard for directory structure in Tupfile, something like %B.o, which takes input filename without extension. My Tupfile rules currently look like this: : foreach src/*.cpp |> !cxx_c_debug |> build/d/o/%B.o :…
honza42
  • 101
  • 6
3
votes
1 answer

How do you use environment variables in Tup run statements?

I'm trying to run a file given an environment variable to generate some environment-specific rules. However, Tup doesn't allow for environment variables to be used in Tupfiles directly (you can send them through to child processes using the export…
Qix - MONICA WAS MISTREATED
  • 14,451
  • 16
  • 82
  • 145
3
votes
2 answers

Tricks for porting a large software project to tup build system

What is the best way to port a software project with thousands of .cpp files and associated headers in a fairly well structured source tree to the tup build system? If the tree looks like: colors/ …
Andrew Wagner
  • 22,677
  • 21
  • 86
  • 100
2
votes
1 answer

Tup variants not building correctly

I switched from make to tup and am trying to get it to build different variants (debug and production). My source tree looks like this: | .tup | bin | build_debug | | tup.config | build_default | | tup.config | include (headers directory) | src…
MetalOn
  • 33
  • 4
2
votes
1 answer

set pipefail for commands run by tup

In a large amount of Tupfiles I use extensive pipelining, e.g. : input |> < %f command1 | command2 > %o |> output The problem with this is that Tup calls system which executes these :-rules in sh, which doesn't support set -o pipefail. As a result,…
Erik
  • 6,470
  • 5
  • 36
  • 37
2
votes
0 answers

Again on build systems. Let's talk about complete correctness

Recently I tried tup and I am VERY impressed by its correctness and speed, and the fact that monitoring the file system makes the tool really robust. It is also very easy to understand. It never gets anything wrong, and when it does, it will show…
Germán Diago
  • 7,473
  • 1
  • 36
  • 59
2
votes
2 answers

How to assign a variable the output of a shell command in Tupfile?

I'd like to assign a variable in a Tupfile the output of the command find . -name "*.cpp" -exec dirname {} \; | sort -u. How can I do it?
e271p314
  • 3,841
  • 7
  • 36
  • 61
2
votes
1 answer

tup monitor not working?

I'm trying to use tup to auto compile my files. After init, I can use tup upd in the command line, but whenever I do tup monitor -a, nothing happens. The command executes, there is no result/error/response, and when I change a file, tup does not…
Derek
  • 11,980
  • 26
  • 103
  • 162
2
votes
1 answer

How to configure tup build system for different build configurations, e.g. debug or release flags?

I am quite new to tup but still love its features. One issue I am thinking about how does tup support different build options, e.g. debug or release (-> different CFLAGS)? I did not find any useful results using google.
Jonas
  • 2,974
  • 4
  • 24
  • 23
1
vote
0 answers

Tup -- manually inserting a generated node

Say I have a project A that depends on project B and that B takes a long time to build. Both project A and project B use tup. I already have B built in its separate directory. Can I now copy B into A or create a submodules that points to B, add the…
Petr Skocik
  • 58,047
  • 6
  • 95
  • 142
1
2