Skip to content

Commit

Permalink
Decouple xmp and libxmp
Browse files Browse the repository at this point in the history
The player application now has its own buildsystem separated from the
library buildsystem.

Signed-off-by: Claudio Matsuoka <[email protected]>
  • Loading branch information
cmatsuoka committed Feb 11, 2012
1 parent aa112da commit adfc0c5
Show file tree
Hide file tree
Showing 43 changed files with 1,218 additions and 24 deletions.
340 changes: 340 additions & 0 deletions COPYING

Large diffs are not rendered by default.

Empty file added INSTALL
Empty file.
24 changes: 0 additions & 24 deletions Makefile

This file was deleted.

70 changes: 70 additions & 0 deletions Makefile.in
Original file line number Diff line number Diff line change
@@ -0,0 +1,70 @@
VERSION = 3.9.0

CC = @CC@
CFLAGS = -c @CFLAGS@ @DEFS@ @CPPFLAGS@
LD = @CC@
LDFLAGS = @LDFLAGS@
LIBS = @LIBS@
INSTALL = @INSTALL@
DESTDIR =
prefix = @prefix@
exec_prefix = @prefix@
datarootdir = @datarootdir@
BINDIR = @bindir@
LIBDIR = @libdir@
MANDIR = @mandir@/man1
SYSCONFDIR = @sysconfdir@/xmp
SHELL = /bin/sh

DIST = xmp-$(VERSION)
DFILES = README INSTALL configure configure.ac Makefile.in
DDIRS = src drivers
V = 0

all: binaries

include src/Makefile
include src/drivers/Makefile

CFLAGS += -I. -DVERSION=\"$(VERSION)\"

.SUFFIXES: .c .o .lo .a .so .dll

.c.o:
@CMD='$(CC) $(CFLAGS) -o $*.o $<'; \
if [ "$(V)" -gt 0 ]; then echo $$CMD; else echo CC $*.o ; fi; \
eval $$CMD

binaries: src/xmp

clean:
@rm -f $(OBJS)

install: install-xmp install-docs

depend:
@echo Building dependencies...
@echo > $@
@for i in $(OBJS) do \
c="$${i%.o}.c"; l="$${i%.o}.lo"; \
$(CC) $(CFLAGS) -MM $$c | \
sed "s!^.*\.o:!$$i $$l:!" >> $@ ; \
done

dist: dist-prepare dist-subdirs

dist-prepare:
rm -Rf $(DIST) $(DIST).tar.gz
mkdir -p $(DIST)
cp -RPp $(DFILES) $(DIST)/

dist-subdirs: $(addprefix dist-,$(DDIRS))
chmod -R u+w $(DIST)/*
tar cvf - $(DIST) | gzip -9c > $(DIST).tar.gz
rm -Rf $(DIST)
ls -l $(DIST).tar.gz

$(OBJS): Makefile

sinclude depend

Empty file added README
Empty file.
27 changes: 27 additions & 0 deletions configure.ac
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
dnl AC_CONFIG_AUX_DIR(./scripts)
AC_INIT
0>confdefs.h

AC_ARG_WITH(libxmp, [ --with-libxmp=<path> libxmp prefix (optional)],
libxmp_path="$withval")

AC_PROG_CC

if test "$libxmp_path" != ""; then
CINCS="${CINCS} -I${libxmp_path}/include"
LIBS="${LIBS} -L${libxmp_path}/lib"
fi
CPPFLAGS="${CINCS}"

AC_CHECK_HEADER(xmp.h)
if test "${ac_cv_header_xmp_h}" = "yes"; then
AC_CHECK_LIB(xmp,xmp_player_start,,
AC_MSG_ERROR(Can't find libxmp))
else
AC_MSG_ERROR(Can't find libxmp header files)
fi


AC_PROG_INSTALL
AC_CONFIG_FILES([Makefile])
AC_OUTPUT
Loading

0 comments on commit adfc0c5

Please sign in to comment.