4 ms·
I mean, the same is true with the C runtime.
by lalaithion 3y ago
I mean, the same is true with the C runtime.
- hulitu 3y ago> I mean, the same is true with the C runtime. My c compiler does not connect to internet during compiling.
- some_furry 3y agoWhat do you do if a dependent .so isn't found? Do you not have to install said dependency from the Internet and start (at least part of) the compile over?
- overthrow 3y agoNor does the Rust compiler. Rust's build system, Cargo, does however. And many C build systems do as well, e.g. https://cmake.org/cmake/help/latest/guide/using-dependencies/index.html#downloading-and-building-from-source-with-fetchcontent https://cmake.org/cmake/help/latest/guide/using-dependencies...
- steveklabnik 3y agoOptionally. Cargo doesn’t have to connect to the internet, and even has command line switches to fail if it tries to.
- hulitu 3y agoGood to know.
- hulitu 3y agoThank you for the tip. I shall do ifconfig eth0 down before compiling to avoid such issues.
- ittan 3y agoIsn't "C Runtime" inaccurate? Wouldn't it be the static or dynamic linked libraries for the particular program in question?
- pjmlp 3y agoNope, what do you think calls into main(), does floating point emulation, handles signals on non UNIX platforms, provides threading support?
- dahfizz 3y agoThe term "runtime" is overloaded here. The C runtime is not what people usually mean when they say a language has a runtime. There is a crt.0 "C Runtime" object. This is code that is literally run "at runtime". When you execute a binary, the C runtime is the first thing executed to setup the stack and call main(). This is just a bit of assembly that runs before main(). It shares ~nothing in common with "runtime" languages like Python or Java where the runtime is alive during the whole program's execution. The C run time does not handle floats or threads or anything like that. Software floats are dealt with by the compiler and threading is implemented as its own library (either in userspace or built into the kernel).
- pjmlp 3y agoI guess you can educate Microsoft on that then. https://learn.microsoft.com/en-us/cpp/c-runtime-library/c-run-time-library-reference?view=msvc-170 https://learn.microsoft.com/en-us/cpp/c-runtime-library/c-ru... It doesn't matter what people think, rather the CS point of view of a language runtime is. That library is the runtime. C implementation without the respective runtime is what is called a freestanding implementation as per ISO C.
- lanstin 3y agoLibraries and crt0.o and the like. Libgcc_s ; but it isn’t a runtime in the sense that some magic is doing GC or scheduling for routines. ABI that describes what the assembly should be doing, it isn’t a thing doing stuff.