kmscon/Makefile.am
Ran Benita 6d451a2015 build: use gnu autotools
This commit adds basic autoconf + automake files to build the project.
It also adds a main.c stub in order to simulate the main binary.

The configure script uses pkg-config to find the libraries. The usual
stuff should work. The only additional option right now is:
        ./configure --enable-debug [To enable debugging symbols]
The Makefile should also support the standard stuff:
        make [To build the kmscon binary]
        make check [To build the test_* binaries]
        make dist [To create a tarball]
        make clean
        make install
        etc.

To start from a clean tree (e.g. git clean -dfx), do something like the
following:
        ./autogen.sh
        ./configure --enable-debug CFLAGS=-O0
        make

It all should work well enough for now.

Signed-off-by: Ran Benita <ran234@gmail.com>
Signed-off-by: David Herrmann <dh.herrmann@googlemail.com>
2011-12-01 16:21:37 +01:00

55 lines
1.0 KiB
Makefile

ACLOCAL_AMFLAGS = -I m4
bin_PROGRAMS = kmscon
check_PROGRAMS = test_console test_output
noinst_LTLIBRARIES = libkmscon-core.la
AM_CFLAGS = \
-Wall \
-I $(srcdir)/src
AM_LDFLAGS = \
-Wl,--as-needed
if DEBUG
AM_CFLAGS += -g
endif
libkmscon_core_la_SOURCES = \
src/console.c src/console.h \
src/output.c src/output.h \
src/console_char.c
libkmscon_core_la_CFLAGS = \
$(AM_CFLAGS) \
$(EGL_CFLAGS) \
$(GBM_CFLAGS) \
$(OPENGL_CFLAGS) \
$(CAIRO_CFLAGS) \
$(PANGO_CFLAGS)
libkmscon_core_la_LIBADD = \
$(EGL_LIBS) \
$(GBM_LIBS) \
$(OPENGL_LIBS) \
$(CAIRO_LIBS) \
$(PANGO_LIBS)
kmscon_SOURCES = src/main.c
kmscon_LDADD = libkmscon-core.la
kmscon_CFLAGS = \
$(AM_CFLAGS) \
$(CAIRO_CFLAGS)
test_console_SOURCES = tests/test_console.c
test_console_LDADD = libkmscon-core.la \
$(OPENGL_LIBS)
test_console_CFLAGS = $(kmscon_CFLAGS) \
$(OPENGL_CFLAGS)
test_output_SOURCES = tests/test_output.c
test_output_LDADD = libkmscon-core.la \
$(OPENGL_LIBS)
test_output_CPPFLAGS = $(kmscon_CFLAGS) \
$(OPENGL_CFLAGS)
dist_doc_DATA = README TODO