Upload to unstable
[darcs-mirror-screen-message.debian.git] / Makefile.am
1
2 sm_SOURCES = sm.c
3 sm_CFLAGS = $(DEPS_CFLAGS)
4 sm_LDADD = $(DEPS_LIBS)
5
6 execgamesdir= $(prefix)/games
7 execgames_PROGRAMS=sm
8
9 sm.desktop: sm.desktop.in
10         sed -e s%@BINPATH@%${execgamesdir}% <$< >$@
11
12 desktopdir = $(datadir)/applications
13 desktop_DATA = sm.desktop
14
15 icondir = $(datadir)/icons/hicolor/48x48/apps
16 dist_icon_DATA = sm.png
17
18 gtk_update_icon_cache = gtk-update-icon-cache -f -t $(datadir)/icons/hicolor
19
20 install-data-hook: update-icon-cache
21 uninstall-hook: update-icon-cache
22 update-icon-cache:
23         @-if test -z "$(DESTDIR)"; then \
24                 echo "Updating Gtk icon cache."; \
25                 $(gtk_update_icon_cache); \
26         else \
27                 echo "*** Icon cache not updated.  After (un)install, run this:"; \
28                 echo "***   $(gtk_update_icon_cache)"; \
29         fi
30
31 dist_man_MANS = sm.6
32 EXTRA_DIST = sm.py sm.desktop.in sm.html sm.webapp webapp.html README.Win32 sm.ico sm.rc sm-128.png sm.svg
33 CLEANFILES = sm.desktop 
34
35 if WIN32
36 AM_LDFLAGS = -Wl,--subsystem,windows
37 sm_LDADD += sm-icon.o
38
39 INSTALLER_BASE = screen-message-setup-@PACKAGE_VERSION@
40 INSTALLER = $(INSTALLER_BASE).exe
41 CLEANFILES +=  setup.iss $(INSTALLER)
42
43 sm-icon.o: sm.rc
44         $(WINDRES) $< $@
45
46 $(INSTALLER): setup.iss sm.exe README.Win32
47         "$(WINE)" "$(ISCC)" /O. "/F$(INSTALLER_BASE)" $< 
48
49 installer: $(INSTALLER)
50
51 endif