Commit graph

264 commits

Author SHA1 Message Date
Dmitrij D. Czarkoff 46df9ae5d8 In 'void *' functions return NULL instead of 0 2016-01-13 20:49:48 +01:00
Harry Jeffery efa33ab844 Fix strict build on GCC 2016-01-13 16:16:33 +00:00
Harry Jeffery f18e65c248 Merge pull request #74 from czarkoff/master
Add Travis CI support
2016-01-13 01:54:14 +00:00
Dmitrij D. Czarkoff ddcfe3341a Gather status of eXeC64/imv in Travis indicator 2016-01-13 02:20:02 +01:00
Dmitrij D. Czarkoff 50c95ac9dd Add explicit CFLAGS to .travis.yml
Include "-Werror" among flags, so that it is easier to catch compiler warnings.
2016-01-12 22:39:50 +01:00
Dmitrij D. Czarkoff c70995a724 Add Travis CI support
Unfortunately, Travis only wants to use Ubuntu LTS releases, so at least until
next Ubuntu LTS release we are stuck with ancient cmocka version.  So no
automated testing yet.
2016-01-09 17:55:13 +01:00
Harry Jeffery 3036f56bc6 Merge pull request #73 from czarkoff/test
Test
2016-01-07 22:02:49 +00:00
Dmitrij D. Czarkoff 83e7ad5222 Add test for file change detection 2016-01-06 02:52:06 +01:00
Dmitrij D. Czarkoff 16cccb11b1 Fix navigator_add test
It was not fixed after imv_navigator_poll_changed() function was changed.
2016-01-06 02:52:06 +01:00
Harry Jeffery 35cabe381d Merge pull request #72 from czarkoff/timeouts
Timeouts
2016-01-01 11:47:32 +00:00
Dmitrij D. Czarkoff 47b702afc8 Include <limits.h> 2016-01-01 12:28:14 +01:00
Dmitrij D. Czarkoff 1ca3d027de Reduce amount of stat(2) calls
Add 8-bit variable that is passed to imv_navigator_poll_changed().  Decrement it
on each run of main loop.  When it gets to 0, call stat(2).
2015-12-30 17:44:48 +01:00
Dmitrij D. Czarkoff c61a0a90db Allow fractional slideshow timeout
Accept slideshow timeout expressed as fractional numbers.  It is intentionally
lax, so that arguments like ".1" or "5." are accepted and give no surprises.
2015-12-30 15:48:03 +01:00
Harry Jeffery aa486c8df0 Merge pull request #71 from czarkoff/mandoc
Rewrite manual page using mdoc(7) markup language
2015-12-30 11:24:57 +00:00
Dmitrij D. Czarkoff 775b8ea73f Fix several issues with manual 2015-12-30 10:47:21 +01:00
Dmitrij D. Czarkoff a1455d9523 Rewrite manual page using mdoc(7) markup language 2015-12-29 23:32:26 +01:00
Harry Jeffery 8d9a91afca Merge pull request #70 from czarkoff/general
Hide functions that are not exposed via headers
2015-12-28 23:21:53 +00:00
Dmitrij D. Czarkoff a160a82b91 Add -Wmissing-prototypes to default CFLAGS 2015-12-28 23:15:30 +01:00
Dmitrij D. Czarkoff fe46955421 Hide functions that are not exposed via headers 2015-12-28 21:22:31 +01:00
Harry Jeffery 287b549ce0 Remove names from file copyright headers 2015-12-28 16:17:50 +00:00
Harry Jeffery 4f31c89351 Add AUTHORS file 2015-12-28 16:17:21 +00:00
Harry Jeffery 433d8195a7 Merge pull request #68 from czarkoff/reload
Use stat(2) to monitor file changes
2015-12-28 13:40:35 +00:00
Dmitrij D. Czarkoff a70919c9ca Add checks for malloc(3)
Exit(3) if memory allocation fails.
2015-12-28 11:59:52 +01:00
Dmitrij D. Czarkoff c6096967e3 Use stat(2) to monitor file changes
Makes file monitoring in imv completely POSIX.
2015-12-28 11:49:52 +01:00
Dmitrij D. Czarkoff d0b041f17c Use realloc(3) for extending buffer
It may save some CPU cycles if there is enough space to grow the array without
copying memory chunks.  Two side effects of the change:  proper error checking
added and dangerous memcpy(3) call removed.
2015-12-28 11:07:41 +01:00
Harry Jeffery f4373a1f83 Merge pull request #66 from czarkoff/master
Drop `obj` target
2015-12-27 15:05:49 +00:00
Dmitrij D. Czarkoff 96bd50edc9 Drop "obj" target
It was introduced to make object files depend on $(BUILDDIR) so that creating it
could be moved into separate rule, executed once.  That was a bad idea, because
"obj" had to be phony, thus making all targets that depend on it obsolete
between runs of make.  This change introduces order-only rule that makes object
files depend on $(BUILDDIR) without obsoleting other targets.
2015-12-27 12:33:38 +01:00
Harry Jeffery a339d07ec6 Merge pull request #65 from czarkoff/build
More changes to build infrastructure
2015-12-26 13:14:43 +00:00
Dmitrij D. Czarkoff cbecdeba3b Use simply expanded variables wherever possible
Recursively expanded variables (VAR = CONTENT) are evaluated when used.  Simply
extended variables (VAR := CONTENT) are expanded immediately, and remain stable
throughout lifetime of the process, reducing fragility of build system.
2015-12-26 14:09:52 +01:00
Dmitrij D. Czarkoff 5f3ebdd39e Generate all files in build directory
* Allow building off read-only source tree.
 * Allow setting build directory from environment.

These changes allow parallel building of imv for multiple architectures, which
is used by package management systems of some operating systems.
2015-12-26 14:09:41 +01:00
Dmitrij D. Czarkoff 4263e95ae0 Make "uninstall" target remove the same files "install" installs 2015-12-26 12:17:09 +01:00
Harry Jeffery 174b3a1a1a Fix usage examples
Fixes #61
2015-12-26 03:09:42 +00:00
Harry Jeffery 6562cfbd42 Improve readability of g_options
The default options block was getting quite ridiculous to try and read.
Let's improve the readability.
2015-12-26 03:02:39 +00:00
Harry Jeffery 1332a920f5 Merge pull request #64 from czarkoff/master
Build infrastructure improvements
2015-12-26 02:58:08 +00:00
Harry Jeffery 5f006803ee Merge pull request #62 from czarkoff/font
Use default font
2015-12-26 02:51:26 +00:00
Dmitrij D. Czarkoff 54560c988d Document default font change in help text 2015-12-25 23:50:18 +01:00
Dmitrij D. Czarkoff c681f5c58e Document default font in manual
Also reference the fonts.conf(5) manual, which explains fonts configuration.
2015-12-25 23:48:59 +01:00
Dmitrij D. Czarkoff 447e86d35d Fix verbose build 2015-12-25 23:27:11 +01:00
Harry Jeffery 3ae2fd34d3 Merge pull request #63 from czarkoff/stdin
Don't use "stdin" variable name
2015-12-25 21:58:16 +00:00
Dmitrij D. Czarkoff c42ab08819 Add verbose mode
If V variable is set to any value, commands will be echoed to standard output.
2015-12-25 17:52:01 +01:00
Dmitrij D. Czarkoff 77827c838e Make installation locations more configurable
This might be desired when platform has its own, custom layout (eg. OpenBSD or
Solaris), or when user wants to install the program to his home directory.
2015-12-25 15:29:12 +01:00
Dmitrij D. Czarkoff 6de6b358e8 Use "shell" macro in CFLAGS
When CFLAGS contain "`cmd`" construct, the "cmd" command is executed every time
when make issues shell command with expanded CFLAGS.  Using "$(shell cmd)"
instead forces make to expand output of "cmd" into CFLAGS.
2015-12-25 15:27:00 +01:00
Dmitrij D. Czarkoff 57d83b7b37 Respect default CFLAGS and LDFLAGS if set in environment
Some package management systems allow users to set default CFLAGS and LDFLAGS
and then supply them to the make via environment.  This change makes build
infrastructure respect such settings.

Also, don't force non-essential flags.
2015-12-25 15:11:32 +01:00
Dmitrij D. Czarkoff ab0c27611b Use "PREFIX" instead of "prefix"
Most package management systems already expect "PREFIX" macro to control
installation path.
2015-12-25 15:07:03 +01:00
Dmitrij D. Czarkoff 4823142b49 Use default font
"Monospace" is a font name reserved for default monospace font, which is
supposed to be set to particular font user prefers.
2015-12-25 15:02:58 +01:00
Dmitrij D. Czarkoff b07d09fd22 Don't use "stdin" variable name
At least on OpenBSD stdin, stdout and stderr are macros, and thus they are
expanded before compilation.
2015-12-25 14:57:19 +01:00
Harry Jeffery a01f3b3b1a Merge pull request #55 from khanley6/LinkingFix
Fixed linking order to properly link libraries. Linking failed prior
2015-12-12 18:11:50 +00:00
Kenneth Hanley 083bf9e5ee Fixed linking order to properly link libraries. Linking failed prior 2015-12-12 17:13:35 +00:00
Harry Jeffery f7365c85bd Release v1.2.0 2015-12-11 15:46:17 +00:00
Harry Jeffery 33790ffb7d Update README 2015-12-11 15:38:26 +00:00