Code

*: make variables more local
[ncmpc.git] / Makefile.am
index 994ce7a3d63b6d81b07ed4ec72231ae49931e039..72e93a183c1232d744fc41923344d46bbdf8aedf 100644 (file)
@@ -2,7 +2,7 @@ SUBDIRS = \
   po
 
 ACLOCAL_AMFLAGS = -I m4
-AUTOMAKE_OPTIONS = foreign 1.9 dist-bzip2 subdir-objects
+AUTOMAKE_OPTIONS = foreign 1.11 dist-bzip2 dist-xz subdir-objects
 
 AM_CPPFLAGS = \
        $(LIBMPDCLIENT_CFLAGS) \
@@ -12,7 +12,6 @@ AM_CPPFLAGS = \
        -DSYSCONFDIR=\""$(sysconfdir)"\"
 
 ncmpc_headers = \
-       src/resolver.h \
        src/gidle.h \
        src/mpdclient.h \
        src/playlist.h \
@@ -21,13 +20,14 @@ ncmpc_headers = \
        src/conf.h \
        src/command.h \
        src/ncu.h \
+       src/ncfix.h \
        src/player_command.h \
        src/window.h \
        src/title_bar.h \
        src/progress_bar.h \
        src/status_bar.h \
        src/screen.h \
-       src/screen_message.h \
+       src/screen_status.h \
        src/screen_interface.h \
        src/screen_list.h \
        src/screen_find.h \
@@ -56,22 +56,24 @@ ncmpc_headers = \
        src/screen_keydef.h \
        src/screen_lyrics.h \
        src/screen_outputs.h \
+       src/screen_chat.h \
        src/screen_text.h \
        src/plugin.h \
        src/lyrics.h \
-       src/str_pool.h \
-       src/lirc.h
+       src/lirc.h \
+       src/ncmpc_curses.h
 
 bin_PROGRAMS = src/ncmpc
 
 src_ncmpc_LDADD = \
+       $(CURSES_LIB) \
        $(LIBMPDCLIENT_LIBS) \
        $(GLIB_LIBS) \
        $(LIBLIRCCLIENT_LIBS)
 
 src_ncmpc_SOURCES = \
+       src/Compiler.h \
        $(ncmpc_headers) \
-       src/resolver.c \
        src/main.c \
        src/gidle.c \
        src/mpdclient.c \
@@ -85,7 +87,7 @@ src_ncmpc_SOURCES = \
        src/progress_bar.c \
        src/status_bar.c \
        src/screen.c \
-       src/screen_message.c \
+       src/screen_status.c \
        src/screen_list.c \
        src/screen_find.c \
        src/screen_utils.c \
@@ -99,8 +101,21 @@ src_ncmpc_SOURCES = \
        src/charset.c \
        src/wreadln.c \
        src/strfsong.c \
-       src/utils.c \
-       src/str_pool.c
+       src/utils.c
+
+#
+# Windows resource file
+#
+
+src/win/ncmpc_win32_rc.$(OBJEXT): src/win/ncmpc_win32_rc.rc
+       $(WINDRES) -i $< -o $@
+
+if HAVE_WINDOWS
+noinst_DATA = src/win/ncmpc_win32_rc.rc
+
+src_ncmpc_DEPENDENCIES = src/win/ncmpc_win32_rc.$(OBJEXT)
+src_ncmpc_LDFLAGS = -Wl,src/win/ncmpc_win32_rc.$(OBJEXT)
+endif
 
 if NCMPC_MINI
 else
@@ -146,12 +161,16 @@ if ENABLE_OUTPUTS_SCREEN
 src_ncmpc_SOURCES += src/screen_outputs.c
 endif
 
+if ENABLE_CHAT_SCREEN
+src_ncmpc_SOURCES += src/screen_chat.c
+endif
+
 if ENABLE_LIRC
 src_ncmpc_SOURCES += src/lirc.c
 endif
 
 
-# build the smalles possible ncmpc binary
+# build the smallest possible ncmpc binary
 src/ncmpc-tiny: $(filter-out %.h,$(src_ncmpc_SOURCES))
        $(COMPILE) --combine -fwhole-program $(src_ncmpc_LDFLAGS) $(src_ncmpc_LDADD) $(LIBS) $^ -o $@
        strip --strip-all $@
@@ -166,8 +185,8 @@ check_PROGRAMS = \
        test/run_hscroll
 
 test_run_hscroll_SOURCES = test/run_hscroll.c src/hscroll.c src/charset.c
-test_run_hscroll_CPPFLAGS = -Isrc $(AM_CPPFLAGS)
-test_run_hscroll_LDFLAGS = $(GLIB_LIBS)
+test_run_hscroll_CPPFLAGS = -I$(srcdir)/src $(AM_CPPFLAGS)
+test_run_hscroll_LDADD = @CURSES_LIB@ $(GLIB_LIBS)
 
 #
 # sparse
@@ -186,7 +205,7 @@ sparse-check:
 # lyrics plugins
 #
 
-lyrics_plugins = lyrics/01-hd.sh lyrics/02-lyricwiki.rb lyrics/03-leoslyrics.py
+lyrics_plugins = lyrics/10-hd.sh lyrics/15-leoslyrics.sh lyrics/20-lyricwiki.rb lyrics/30-leoslyrics.py
 
 if ENABLE_LYRICS_SCREEN
 
@@ -204,10 +223,33 @@ doc_DATA = \
        AUTHORS NEWS README
 man_MANS = doc/ncmpc.1
 
+if ENABLE_DOCUMENTATION
+doc/api/html/index.html: doc/doxygen.conf
+       @mkdir -p $(@D)
+       $(DOXYGEN) $<
+
+all-local: doc/api/html/index.html
+
+clean-local:
+       rm -rf doc/api
+
+# copied from MPD, disabled  --jn
+#---------------------------------------
+#install-data-local: doc/api/html/index.html
+#      $(mkinstalldirs) $(DESTDIR)$(docdir)/api/html
+#      $(INSTALL_DATA) -c -m 644 doc/api/html/*.* \
+#              $(DESTDIR)$(docdir)/api/html
+#
+#uninstall-local:
+#      rm -f $(DESTDIR)$(docdir)/api/html/*.*
+#---------------------------------------
+endif
+
 #
 # Distribution
 #
 
 EXTRA_DIST = autogen.sh \
        $(lyrics_plugins) \
-       $(man_MANS) $(doc_DATA)
+       $(man_MANS) $(doc_DATA) doc/doxygen.conf \
+       src/win/ncmpc_win32_rc.rc.in