Commit graph

57 commits

Author SHA1 Message Date
Harry Jeffery fe4d9bcf92 Update loader unit tests 2017-11-26 14:10:33 +00:00
Harry Jeffery e2954b8108 Provide default global config file 2017-11-23 22:18:28 +00:00
Dmitrij D. Czarkoff f328300810 Unconditionally echo build commands 2016-11-22 15:50:49 +01:00
Dmitrij D. Czarkoff 8febdbbd35 Simplify VERSION handling
Also, use default abbreviation length, so that abbreviated object name in
VERSION would match github's display of commit IDs.
2016-11-22 15:55:45 +01:00
Dmitrij D. Czarkoff 9aea3f0dda Separate preprocessor flags from compiler flags, libs from linker flags
PR #98 hints that we were venturing into downstream's territory: compiler and
linker flags may be OS-specific, while preprocessor flags and libraries are our
responsibility.  Provide clean separation between these categories.

Downstreams may still need to provide "--std=c99" in CFLAGS though.
2016-11-22 15:48:04 +01:00
Harry Jeffery e59d0e9e12 Release v2.1.3 2016-10-22 12:35:20 +01:00
Göktürk Yüksek 07f61719e7
Fix the linking order of tests in the Makefile for --as-needed
When '--as-needed' linker flag is added to LDFLAGS, linker strips out
the symbols from the libraries needed for the tests due to the order
in which the libraries appear on the command line. List the source
files before the libraries to fix the linking issue.

For more information, see:
https://wiki.gentoo.org/wiki/Project:Quality_Assurance/As-needed#Importance_of_linking_order

Signed-off-by: Göktürk Yüksek <gokturk@gentoo.org>
2016-05-25 08:31:55 -04:00
Harry Jeffery 3e6402456b Release v2.1.2 2016-05-15 23:36:46 +01:00
Dmitrij D. Czarkoff 8e9c6f5e57 Fix build of imv on GNU libc
Previously imv used -std=gnu11 flag which activated GNU "extensions" of C11
standard.  This masked a portability issue in imv: strduo(3) should not have
been visible in `src/loader.c` without inclusion of `<string.h>` header.  This
have been fixed.  To remidy GNU libc's stange choice to hide X/Open interfaces
in C99 code by default _XOPEN_SOURCE macro was also set.  (This should have no
effect on most other platforms.)
2016-05-13 06:30:52 +02:00
Dmitrij D. Czarkoff 7353178d6d Release v2.1.1 2016-05-13 00:43:36 +02:00
Dmitrij D. Czarkoff 6dad3c7bbf Fix compatibility with older gcc versions 2016-05-12 14:27:17 +02:00
Harry Jeffery 0e8205237e Release v2.1.0 2016-04-27 12:08:01 +01:00
Dmitrij D. Czarkoff 9ecdf4d258 Include git commit hash in version number
When operating in git repo, build system will include abbreviated git hash in
imv version number.  If there is no git repo around (eg. building from tarball),
fall back to version number in Makefile.

Fixes #90
2016-04-25 21:13:50 +02:00
Dmitrij D. Czarkoff 66de2c49e5 Remove duplicated "-g" flag 2016-02-25 01:27:22 +01:00
Dmitrij D. Czarkoff b4dfe40a57 Fix "check" target
for i in "..."; do ...; done ideom guarantees single iteration with $i set to
everything between "in" and ';'.
2016-02-21 15:03:21 +01:00
Dmitrij D. Czarkoff 1efd760b8d Force "-g" flag for tests 2016-02-21 15:07:13 +01:00
Harry Jeffery bc90a0adcc Release imv v2.0.0 2016-02-08 11:02:29 +00:00
Dmitrij D. Czarkoff a160a82b91 Add -Wmissing-prototypes to default CFLAGS 2015-12-28 23:15:30 +01: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
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
Dmitrij D. Czarkoff 447e86d35d Fix verbose build 2015-12-25 23:27:11 +01: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
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 c2871c5323 Tell gcc to be pedantic 2015-12-10 15:55:29 +00:00
Harry Jeffery c8f4c755c3 Add testing infrastructure 2015-12-08 16:39:31 +00:00
Harry Jeffery 6a2ce5abdb Document pthreads dependency
The linking argument isn't strictly needed, since SDL pulls that in, but
there's no harm in manually specifying it for people reading the
Makefile to see.
2015-11-29 15:24:14 +00:00
Harry Jeffery ea7c76c2f8 Add make uninstall rule 2015-11-22 20:32:04 +00:00
Harry Jeffery 2737649cef Use fontconfig to search for fonts 2015-11-19 23:25:33 +00:00
Harry Jeffery 53fd3b8f3a Add an overlay option '-d'.
TODO: The font needs to be configurable with an option.

Refs #35
2015-11-17 17:14:57 +00:00
Harry Jeffery 4d1a6d581b Release v1.1.0 2015-11-14 23:30:01 +00:00
Guillaume Brogi ef861fe433 Add a imv.desktop file 2015-11-12 12:33:48 +01:00
Harry Jeffery f2ce793d62 Release version v1.0.0 2015-11-11 21:07:29 +00:00
Harry Jeffery a225d45614 Fix makefile 2015-11-11 21:07:29 +00:00
Harry Jeffery 894d38730f Print version information in help 2015-11-11 20:40:59 +00:00
Harry Jeffery ee3c3432cb Improve Makefile 2015-11-11 15:38:34 +00:00
Harry Jeffery c155280cb8 Move manpage into doc directory 2015-11-11 15:28:59 +00:00
Harry Jeffery 8b527949b0 Update makefile to use a build directory 2015-11-11 15:22:41 +00:00
Harry Jeffery d414db0f65 Add debug target 2015-11-10 20:50:10 +00:00
Jose Diez 185216adcd Separate viewport logic into imv_viewport 2015-11-10 16:17:56 +00:00
Harry Jeffery 507d24d156 Create manpage 2015-11-10 16:12:10 +00:00
Harry Jeffery 9bad6406b6 Use new image class 2015-11-10 14:57:43 +00:00
Harry Jeffery 7567416c17 Use navigator class to manage input files 2015-11-10 11:11:58 +00:00
Harry Jeffery 64251e45e4 Use new imv_texture class 2015-11-10 01:13:09 +00:00