Note some cross-compilers might not install the ncurses config scripts
and only the pkg-config files, but at least the atari SDK from NS does.
For others it might be required to check for the .pc files first.
The text is copied from ttyclock.c, only:
- rewrapped
- replaced the copyright character with (c)
- updated copyright years and add one for contributors
See also: GH #52
CFLAGS and LDFLAGS may be passed in by an upstream build system. we
want to make sure we absolutely add our dependency flags otherwise
stuff like hardening flags will break the build
Closes: #29
previous Makefile changes didn't actually work for pkg-config. they
were taken from the Debian package, which operated differently.
furthermore, the ncurses5-config lines were incorrect: they were using
both ncursesw and ncurses and would fail if --libdir was
empty. instead, we use the more proper --cflags and --libs that all do
the right thing.
this should, arguably, only be done with pkg-config, but i didn't want
to introduce an additional dependency.
See: #38
the way this was working before, we would populate the ttyclock->lt
field *after* fetching the ttyclock->tm structure, which means that
would get the `localtime` of the *previous* iteration. this created a
one second delay in the clock display that was, I believe,
unintentional. this accounts for part of the 2s delay when compared to
other clocks like vtclock or xclock.
Closes: #40
this creates warnings in Debian, as there are checks to see if we use proper hardening flags, for example.
besides, we *almost* show all the tags in the compile rule, might as well not silence it
Prior to this commit, my blinking colon pull req made blinking default.
This commit makes it so that you have to pass in a flag -B to make the
colons blink. This fits with the style of this program.