Why do intelligent build systems not exist?
Clash Royale CLAN TAG#URR8PPP
.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty margin-bottom:0;
Various tools and mechanisms exist for tracing the execution of a process:
strace(ptrace)/DTrace
dnotify/inotify/FAM- LD_PRELOAD
Through the use of one or more of these, it should be possible to detect when a shell script starts a process, and it should be possible to record the inputs and outputs of that process on the filesystem.
It should be technically straightforward to instrument a common command shell, such as Bash, so that inputs and outputs of each command are recorded in a database somewhere, and so that command execution can be avoided when it can be ascertained that the inputs have not changed and the outputs are still around somewhere.
A strict implementation of this idea would suffer from making everything out of date whenever there is a system upgrade, for example, that touches Libc - or whenever a commonly-read file like /etc/passwd
changes. However, by restricting the set of inputs we care about to the source files in a project tree, we could have something very similar to Make and other build systems. The result, however, would have several advantages over rule-based systems like Make:
more concise - you only have to name the inputs and outputs of a command once, as part of the command itself, or as part of other input files (as with e.g. C header files)
more flexible - ability to use the build system as an interactive shell; possibility to track inputs or outputs being renamed
more correct - files will be rebuilt if the build specification changes; "out-of-date"-ness applies to commands+files rather than just files; not worrying about "recursive Make" issues
more extensible - this would be a better framework on which to build a caching facility, for example, to share computation when building two different checkouts of the same repository
Does the system I'm looking for exist? What are the obstacles to implementing and promoting such a system?
These are questions that I ask myself when I look at various build system options, particularly for data-processing applications where command execution can be very slow and dependency structures can be ad-hoc. Usually I choose GNU Make, but I wonder why something simpler and better hasn't come around.
compiling make
add a comment |
Various tools and mechanisms exist for tracing the execution of a process:
strace(ptrace)/DTrace
dnotify/inotify/FAM- LD_PRELOAD
Through the use of one or more of these, it should be possible to detect when a shell script starts a process, and it should be possible to record the inputs and outputs of that process on the filesystem.
It should be technically straightforward to instrument a common command shell, such as Bash, so that inputs and outputs of each command are recorded in a database somewhere, and so that command execution can be avoided when it can be ascertained that the inputs have not changed and the outputs are still around somewhere.
A strict implementation of this idea would suffer from making everything out of date whenever there is a system upgrade, for example, that touches Libc - or whenever a commonly-read file like /etc/passwd
changes. However, by restricting the set of inputs we care about to the source files in a project tree, we could have something very similar to Make and other build systems. The result, however, would have several advantages over rule-based systems like Make:
more concise - you only have to name the inputs and outputs of a command once, as part of the command itself, or as part of other input files (as with e.g. C header files)
more flexible - ability to use the build system as an interactive shell; possibility to track inputs or outputs being renamed
more correct - files will be rebuilt if the build specification changes; "out-of-date"-ness applies to commands+files rather than just files; not worrying about "recursive Make" issues
more extensible - this would be a better framework on which to build a caching facility, for example, to share computation when building two different checkouts of the same repository
Does the system I'm looking for exist? What are the obstacles to implementing and promoting such a system?
These are questions that I ask myself when I look at various build system options, particularly for data-processing applications where command execution can be very slow and dependency structures can be ad-hoc. Usually I choose GNU Make, but I wonder why something simpler and better hasn't come around.
compiling make
1
ccache does part of this for C, C++, Objective-C and Objective-C++ compilation. Reproducible builds are in some ways a variant of your use case.
– Stephen Kitt
Mar 14 at 11:36
1
MSBuild's File Tracker has certainly existed since MSBuild version 4.0. (-:
– JdeBP
Mar 14 at 11:42
Thanks, I knew about ccache, but not Microsoft's MSBuild.
– Metamorphic
Mar 14 at 18:09
add a comment |
Various tools and mechanisms exist for tracing the execution of a process:
strace(ptrace)/DTrace
dnotify/inotify/FAM- LD_PRELOAD
Through the use of one or more of these, it should be possible to detect when a shell script starts a process, and it should be possible to record the inputs and outputs of that process on the filesystem.
It should be technically straightforward to instrument a common command shell, such as Bash, so that inputs and outputs of each command are recorded in a database somewhere, and so that command execution can be avoided when it can be ascertained that the inputs have not changed and the outputs are still around somewhere.
A strict implementation of this idea would suffer from making everything out of date whenever there is a system upgrade, for example, that touches Libc - or whenever a commonly-read file like /etc/passwd
changes. However, by restricting the set of inputs we care about to the source files in a project tree, we could have something very similar to Make and other build systems. The result, however, would have several advantages over rule-based systems like Make:
more concise - you only have to name the inputs and outputs of a command once, as part of the command itself, or as part of other input files (as with e.g. C header files)
more flexible - ability to use the build system as an interactive shell; possibility to track inputs or outputs being renamed
more correct - files will be rebuilt if the build specification changes; "out-of-date"-ness applies to commands+files rather than just files; not worrying about "recursive Make" issues
more extensible - this would be a better framework on which to build a caching facility, for example, to share computation when building two different checkouts of the same repository
Does the system I'm looking for exist? What are the obstacles to implementing and promoting such a system?
These are questions that I ask myself when I look at various build system options, particularly for data-processing applications where command execution can be very slow and dependency structures can be ad-hoc. Usually I choose GNU Make, but I wonder why something simpler and better hasn't come around.
compiling make
Various tools and mechanisms exist for tracing the execution of a process:
strace(ptrace)/DTrace
dnotify/inotify/FAM- LD_PRELOAD
Through the use of one or more of these, it should be possible to detect when a shell script starts a process, and it should be possible to record the inputs and outputs of that process on the filesystem.
It should be technically straightforward to instrument a common command shell, such as Bash, so that inputs and outputs of each command are recorded in a database somewhere, and so that command execution can be avoided when it can be ascertained that the inputs have not changed and the outputs are still around somewhere.
A strict implementation of this idea would suffer from making everything out of date whenever there is a system upgrade, for example, that touches Libc - or whenever a commonly-read file like /etc/passwd
changes. However, by restricting the set of inputs we care about to the source files in a project tree, we could have something very similar to Make and other build systems. The result, however, would have several advantages over rule-based systems like Make:
more concise - you only have to name the inputs and outputs of a command once, as part of the command itself, or as part of other input files (as with e.g. C header files)
more flexible - ability to use the build system as an interactive shell; possibility to track inputs or outputs being renamed
more correct - files will be rebuilt if the build specification changes; "out-of-date"-ness applies to commands+files rather than just files; not worrying about "recursive Make" issues
more extensible - this would be a better framework on which to build a caching facility, for example, to share computation when building two different checkouts of the same repository
Does the system I'm looking for exist? What are the obstacles to implementing and promoting such a system?
These are questions that I ask myself when I look at various build system options, particularly for data-processing applications where command execution can be very slow and dependency structures can be ad-hoc. Usually I choose GNU Make, but I wonder why something simpler and better hasn't come around.
compiling make
compiling make
asked Mar 14 at 11:30
MetamorphicMetamorphic
365113
365113
1
ccache does part of this for C, C++, Objective-C and Objective-C++ compilation. Reproducible builds are in some ways a variant of your use case.
– Stephen Kitt
Mar 14 at 11:36
1
MSBuild's File Tracker has certainly existed since MSBuild version 4.0. (-:
– JdeBP
Mar 14 at 11:42
Thanks, I knew about ccache, but not Microsoft's MSBuild.
– Metamorphic
Mar 14 at 18:09
add a comment |
1
ccache does part of this for C, C++, Objective-C and Objective-C++ compilation. Reproducible builds are in some ways a variant of your use case.
– Stephen Kitt
Mar 14 at 11:36
1
MSBuild's File Tracker has certainly existed since MSBuild version 4.0. (-:
– JdeBP
Mar 14 at 11:42
Thanks, I knew about ccache, but not Microsoft's MSBuild.
– Metamorphic
Mar 14 at 18:09
1
1
ccache does part of this for C, C++, Objective-C and Objective-C++ compilation. Reproducible builds are in some ways a variant of your use case.
– Stephen Kitt
Mar 14 at 11:36
ccache does part of this for C, C++, Objective-C and Objective-C++ compilation. Reproducible builds are in some ways a variant of your use case.
– Stephen Kitt
Mar 14 at 11:36
1
1
MSBuild's File Tracker has certainly existed since MSBuild version 4.0. (-:
– JdeBP
Mar 14 at 11:42
MSBuild's File Tracker has certainly existed since MSBuild version 4.0. (-:
– JdeBP
Mar 14 at 11:42
Thanks, I knew about ccache, but not Microsoft's MSBuild.
– Metamorphic
Mar 14 at 18:09
Thanks, I knew about ccache, but not Microsoft's MSBuild.
– Metamorphic
Mar 14 at 18:09
add a comment |
0
active
oldest
votes
Your Answer
StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "106"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);
else
createEditor();
);
function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: false,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: null,
bindNavPrevention: true,
postfix: "",
imageUploader:
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
,
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);
);
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f506260%2fwhy-do-intelligent-build-systems-not-exist%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
0
active
oldest
votes
0
active
oldest
votes
active
oldest
votes
active
oldest
votes
Thanks for contributing an answer to Unix & Linux Stack Exchange!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f506260%2fwhy-do-intelligent-build-systems-not-exist%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
1
ccache does part of this for C, C++, Objective-C and Objective-C++ compilation. Reproducible builds are in some ways a variant of your use case.
– Stephen Kitt
Mar 14 at 11:36
1
MSBuild's File Tracker has certainly existed since MSBuild version 4.0. (-:
– JdeBP
Mar 14 at 11:42
Thanks, I knew about ccache, but not Microsoft's MSBuild.
– Metamorphic
Mar 14 at 18:09