# HG changeset patch # User Jonathan Schleifer # Date 1222983902 -7200 # Node ID 34b21e766f5eb0db29b3b092ec5e02f8c7321780 # Parent 7d2882c8a37a6686ad2aa8c894260f8084930798# Parent 06079e59fc4b658eff3f9a526820bb981318694b Automated merge with ssh://hg.atheme.org//hg/audacious diff -r 7d2882c8a37a -r 34b21e766f5e buildsys.mk.in --- a/buildsys.mk.in Thu Oct 02 23:25:25 2008 +0200 +++ b/buildsys.mk.in Thu Oct 02 23:45:02 2008 +0200 @@ -29,7 +29,8 @@ OBJC = @OBJC@ AR = @AR@ LD = ${CC} -TR = @TR@ +RANLIB = @RANLIB@ +PYTHON = @PYTHON@ CFLAGS = @CFLAGS@ CXXFLAGS = @CXXFLAGS@ CPPFLAGS = @CPPFLAGS@ @@ -37,6 +38,7 @@ ERLCFLAGS = @ERLCFLAGS@ OBJCFLAGS = @OBJCFLAGS@ LDFLAGS = @LDFLAGS@ +PYTHON_FLAGS = @PYTHON_FLAGS@ LIBS = @LIBS@ PROG_IMPLIB_NEEDED = @PROG_IMPLIB_NEEDED@ PROG_IMPLIB_LDFLAGS = @PROG_IMPLIB_LDFLAGS@ @@ -46,8 +48,7 @@ LIB_LDFLAGS = @LIB_LDFLAGS@ LIB_PREFIX = @LIB_PREFIX@ LIB_SUFFIX = @LIB_SUFFIX@ -PLUGIN_DEFNAME := `echo ${subst ${PLUGIN_SUFFIX},,${PLUGIN}} | tr '[:lower:]' '[:upper:]' | tr '-' '_'` -PLUGIN_CPPFLAGS = @PLUGIN_CPPFLAGS@ -D${PLUGIN_DEFNAME}_CFGID=\"${subst ${PLUGIN_SUFFIX},,${PLUGIN}}\" +PLUGIN_CPPFLAGS = @PLUGIN_CPPFLAGS@ PLUGIN_CFLAGS = @PLUGIN_CFLAGS@ PLUGIN_LDFLAGS = @PLUGIN_LDFLAGS@ PLUGIN_SUFFIX = @PLUGIN_SUFFIX@ @@ -76,10 +77,11 @@ OBJS4 = ${OBJS3:.d=.o} OBJS5 = ${OBJS4:.erl=.beam} OBJS6 = ${OBJS5:.m=.o} -OBJS += ${OBJS6:.xpm=.o} +OBJS7 = ${OBJS6:.py=.pyc} +OBJS += ${OBJS7:.xpm=.o} .SILENT: -.SUFFIXES: .beam .c .cc .cxx .d .dep .erl .m .xpm +.SUFFIXES: .beam .c .cc .cxx .d .dep .erl .m .py .pyc .xpm .PHONY: all subdirs pre-depend depend install install-extra uninstall uninstall-extra clean distclean all: @@ -100,9 +102,21 @@ test -f .deps || regen=1; \ for i in ${SRCS}; do \ case $$i in \ - *.o) \ + *.c) \ + test $$i -nt .deps && regen=1; \ + deps="$$deps $${i%.c}.dep"; \ + ;; \ + *.cc) \ test $$i -nt .deps && regen=1; \ - deps="$${deps} $${i%.o}.dep"; \ + deps="$$deps $${i%.cc}.dep"; \ + ;; \ + *.cxx) \ + test $$i -nt .deps && regen=1; \ + deps="$$deps $${i%.cxx}.dep"; \ + ;; \ + *.m) \ + test $$i -nt .deps && regen=1; \ + deps="$$deps $${i%.m}.dep"; \ ;; \ esac; \ done; \ @@ -153,10 +167,11 @@ ${STATIC_LIB} ${STATIC_LIB_NOINST}: ${EXT_DEPS} ${OBJS} ${LINK_STATUS} - if ${AR} cr $@ ${OBJS}; then \ + if ${AR} cr $@ ${OBJS} && ${RANLIB} ${@}; then \ ${LINK_OK}; \ else \ ${LINK_FAILED}; \ + rm -f $@; \ fi .c.o: @@ -207,6 +222,14 @@ ${COMPILE_FAILED}; \ fi +.py.pyc: + ${COMPILE_STATUS} + if ${PYTHON} ${PYTHON_FLAGS} -c "import py_compile; py_compile.compile('$<')"; then \ + ${COMPILE_OK}; \ + else \ + ${COMPILE_FAILED}; \ + fi + .xpm.o: ${COMPILE_STATUS} if ${CC} ${CFLAGS} ${CPPFLAGS} -x c -c -o $@ $<; then \ diff -r 7d2882c8a37a -r 34b21e766f5e extra.mk.in --- a/extra.mk.in Thu Oct 02 23:25:25 2008 +0200 +++ b/extra.mk.in Thu Oct 02 23:45:02 2008 +0200 @@ -181,3 +181,6 @@ ARCH_X86 ?= @ARCH_X86@ VERSION ?= @VERSION@ AUDLDFLAGS ?= @AUDLDFLAGS@ +TR = @TR@ +PLUGIN_DEFNAME := `echo ${subst ${PLUGIN_SUFFIX},,${PLUGIN}} | tr '[:lower:]' '[:upper:]' | tr '-' '_'` +PLUGIN_CPPFLAGS += -D${PLUGIN_DEFNAME}_CFGID="\"${subst ${PLUGIN_SUFFIX},,${PLUGIN}}\""