[Demudi-commits] r56 - / vkeybd vkeybd/branches vkeybd/branches/upstream vkeybd/branches/upstream/current
Free Ekanayaka
free-guest@haydn.debian.org
Sat, 30 Oct 2004 06:43:58 -0600
Author: free-guest
Date: 2004-10-30 06:43:45 -0600 (Sat, 30 Oct 2004)
New Revision: 56
Added:
vkeybd/
vkeybd/branches/
vkeybd/branches/upstream/
vkeybd/branches/upstream/current/
vkeybd/branches/upstream/current/Makefile
vkeybd/tags/
Log:
[svn-inject] Installing original source of vkeybd
Added: vkeybd/branches/upstream/current/Makefile
===================================================================
--- vkeybd/branches/upstream/current/Makefile 2004-10-30 12:43:12 UTC (rev 55)
+++ vkeybd/branches/upstream/current/Makefile 2004-10-30 12:43:45 UTC (rev 56)
@@ -0,0 +1,124 @@
+#
+# Makefile for vkeybd
+# copyright (c) 1997-2000 by Takashi Iwai
+#
+
+VERSION = 0.1.16
+
+#
+# installation directory
+#
+PREFIX = /usr/local
+# binary and Tcl script are put there
+BIN_DIR = $(PREFIX)/bin
+# man page
+MAN_SUFFIX = 1
+MAN_DIR = $(PREFIX)/share/man
+
+# data directory (/usr/share)
+DATA_DIR = $(PREFIX)/share
+
+#
+# preset and keyboard file are put here
+#
+VKBLIB_DIR = $(DATA_DIR)/vkeybd
+
+#
+# device selections -- multiple avaialble
+# to disable the device, set value 0 (do not comment out!)
+#
+USE_AWE = 1
+USE_MIDI = 1
+USE_ALSA = 1
+USE_LADCCA = 0
+
+#
+# Tcl/Tk library -- depends on your distribution
+#
+TCL_VERSION = 8.4
+TCLLIB = -ltcl$(TCL_VERSION)
+TCLINC =
+TKLIB = -ltk$(TCL_VERSION)
+TKINC =
+XLIB = -L/usr/X11R6/lib -lX11
+XINC = -I/usr/X11R6/include
+EXTRALIB += -ldl
+
+#----------------------------------------------------------------
+# device definitions
+#----------------------------------------------------------------
+
+# AWE device
+ifeq (1,$(USE_AWE))
+DEVICES += -DVKB_USE_AWE
+DEVOBJS += oper_awe.o
+endif
+
+# MIDI device
+ifeq (1,$(USE_MIDI))
+DEVICES += -DVKB_USE_MIDI
+DEVOBJS += oper_midi.o
+endif
+
+# ALSA sequencer
+ifeq (1,$(USE_ALSA))
+DEVICES += -DVKB_USE_ALSA
+DEVOBJS += oper_alsa.o
+EXTRALIB += -lasound
+endif
+
+#
+# LADCCA stuff
+#
+ifeq (1,$(USE_LADCCA))
+LADCCACFLAGS = $(shell pkg-config --cflags ladcca-1.0) \
+ $(shell pkg-config --exists ladcca-1.0 && echo "-DHAVE_LADCCA" )
+LADCCALIBS = $(shell pkg-config --libs ladcca-1.0)
+DEVICES += $(LADCCACFLAGS)
+EXTRALIB += $(LADCCALIBS)
+endif
+
+#----------------------------------------------------------------
+# dependencies
+#----------------------------------------------------------------
+
+VKB_TCLFILE = $(VKBLIB_DIR)/vkeybd.tcl
+
+CFLAGS = -Wall -O -DVKB_TCLFILE=\"$(VKB_TCLFILE)\" \
+ -DVKBLIB_DIR=\"$(VKBLIB_DIR)\"\
+ -DVERSION_STR=\"$(VERSION)\"\
+ $(DEVICES) $(XINC) $(TCLINC) $(TKINC) $(LADCCACFLAGS)
+
+TARGETS = vkeybd sftovkb
+
+all: $(TARGETS)
+
+vkeybd: vkb.o vkb_device.o $(DEVOBJS) $(EXTRAOBJS)
+ $(CC) -o $@ $^ $(TKLIB) $(TCLLIB) $(XLIB) $(EXTRALIB) -lm
+
+sftovkb: sftovkb.o sffile.o malloc.o fskip.o
+ $(CC) -o $@ $^ -lm
+
+install: $(TARGETS) vkeybd.tcl vkeybd.list
+ mkdir -p $(DESTDIR)$(BIN_DIR)
+ install -c -s vkeybd $(DESTDIR)$(BIN_DIR)
+ install -c -s sftovkb $(DESTDIR)$(BIN_DIR)
+ rm -f $(DESTDIR)$(BIN_DIR)/vkeybd.tcl
+ mkdir -p $(DESTDIR)$(VKBLIB_DIR)
+ install -c -m 444 vkeybd.tcl $(DESTDIR)$(VKBLIB_DIR)
+ install -c -m 444 vkeybd.list $(DESTDIR)$(VKBLIB_DIR)
+
+install-man:
+ mkdir -p $(DESTDIR)$(MAN_DIR)/man$(MAN_SUFFIX)
+ install -c -m 444 vkeybd.man $(DESTDIR)$(MAN_DIR)/man$(MAN_SUFFIX)/vkeybd.$(MAN_SUFFIX)
+
+install-desktop:
+ mkdir -p $(DESTDIR)$(DATA_DIR)/applications
+ install -c vkeybd.desktop $(DESTDIR)$(DATA_DIR)/applications
+ mkdir -p $(DESTDIR)$(DATA_DIR)/pixmaps
+ install -c pixmaps/*.png $(DESTDIR)$(DATA_DIR)/pixmaps
+
+install-all: install install-man install-desktop
+
+clean:
+ rm -f *.o $(TARGETS)