mas.to is one of the many independent Mastodon servers you can use to participate in the fediverse.
Hello! mas.to is a fast, up-to-date and fun Mastodon server.

Administered by:

Server stats:

12K
active users

I’ve created a new C++ build system: g++ *

@rifkin @jef

I used to start quickie C programs with:

----------------------------
#ifdef notdef
gcc $0 -o $(basename $0 .c)
exit $?
#endif

int main....

---------------------------

Then I could compile by saying "sh foo.c"

This was especially useful if the compile line was complicated (e.g., the C program required linking with special libraries or something).

(Actually I used back-quotes instead of $(....), but this phone doesn't have back-quote on this keyboard.)

Matt Mascarenhas

@lain_7 @rifkin @jef Basically same here:

────
0
ctime -begin ${0%.*}.ctm
clang -g -fsanitize=address -std=c99 $0 -o ${0%.*}
ctime -end ${0%.*}.ctm
exit

────

That's the intro to all my new .c files. (ctime, by the way, times the build.) I got the idea from Won Chun, and like to think of it grandly as "The Won Build System".