5 ms·
I've hit command line length limits on both Windows and Linux (and they're different lengths). Typically when I've run into it, it's been with build systems, e
by hermitdev 4y ago
I've hit command line length limits on both Windows and Linux (and they're different lengths).
Typically when I've run into it, it's been with build systems, especially those built around make/gnumake. Have a set of object files that need linking, what do you do? Typically, just expanding the variable holding the list as an argument list to ld or whatever works just fine. Until the project grows substantially and you're linking hundreds or thousands of object files. And what if they're in a different path? A subfolder? What if you're using absolute paths to object file locations? These things can blow up in weird and surprising ways and it's not always obvious what the cause is.
Thankfully, most tools used to build software typically have a mechanism to read arguments from a file that doesn't suffer from this limitation.
Also, as a sibling comment mentions: globs expansions. Typically done by the shell, then passed to the invocation target. Better to pass the glob in quoted and have invoked program do the expansion...
Just a couple places I've seen the problem.