5 ms·
I don't think the author realized that the `configure` script at the center of his rant is auto-generated by `autoconf`, and not written by a human... The sour
by Galanwe 4y ago
I don't think the author realized that the `configure` script at the center of his rant is auto-generated by `autoconf`, and not written by a human...
The source is a straightfoward `configure.ac` of 75 commented lines of code (13 with comments removed)
- kelnos 4y agoI felt like the author did realize that, and the "written by the devil" comment was a direct reference to autoconf (which certainly qualifies as a devil). Who knows, though.
- segfaultbuserr 4y agozetalyrae also correctly pointed out that much of the text is "handwritten but transcluded". Most of the code snippets that appeared in autoconf was originally written by hand and stored in reusable modules, including 100+ tests in autoconf. So overall the volume of code is still huge. I guess it at least demonstrated the power of modularity. Almost nobody can understand it, but it still works...
- zetalyrae 4y agoBash is not an acceptable compilation target. And much of the text is handwritten but transcluded.
- Galanwe 4y ago> Bash is not an acceptable compilation target The whole point of autotools is to make sure that your project can run on the largest possible set of unix-like operating systems. `sh` is actually the very best compilation target for that, looking back in time, whatever other language that could have been chosen (most likely perl) would have been a huge mistake.
- zetalyrae 4y agoThe alternative is a C program querying the filesystem (or, better yet, a database and a daemon to prevent duplicate ./configure work).
- Galanwe 4y agoI don't think you understand the role of autoconf... The whole point is that you _don't know_ yet what compiler is available, which version/flavor of C is supported, which API or syscall are available, etc. Autoconf was litterally made so that you can write C code that is somewhat portable. Suggesting that it should have been written in C and built locally is non-sensical.
- GoblinSlayer 4y agoDoesn't cmake do this job too?
- zetalyrae 4y agoI meant a compiled binary program.
- cryptonector 4y ago> Oh hai! -bootstrapping problem
- segfaultbuserr 4y agoIf I recall correctly, the original compilation target is not even /bin/bash but the /bin/sh. Originally, the ./configure script generated by autoconf must run on several incompatible flavors of Unix at that time, including AIX, SunOS, and BSD, powered by several different CPU architectures, such as x86, Alpha, SPARC, and MIPS, so shipping binaries or using the Bash syntax was not acceptable. It must strictly use the original sh syntax. Though I suspect lots of Bashism has lurked in over the years since nobody still tests it anymore.
- lowq 4y agoAs far as configure is concerned, I'd like to add that 16394 is close to 2^14, not 2^16.