mirror of
https://github.com/Ponce/slackbuilds
synced 2024-11-22 19:44:21 +01:00
12e3c47e47
Signed-off-by: David Spencer <idlemoor@slackbuilds.org>
63 lines
2.1 KiB
Diff
63 lines
2.1 KiB
Diff
diff -ur langdrill-0.3/src/Makefile langdrill-0.3/src/Makefile
|
|
--- langdrill-0.3/src/Makefile 2018-03-19 09:36:36.277390675 -0700
|
|
+++ langdrill-0.3/src/Makefile 2018-03-19 09:55:06.065284069 -0700
|
|
@@ -1,6 +1,5 @@
|
|
###### Files & Directories
|
|
DESTDIR=
|
|
-MY_DEBIAN_SYSTEM=
|
|
|
|
|
|
SRC = main.cc\
|
|
@@ -20,21 +19,10 @@
|
|
`vdk-config-2 --cflags` \
|
|
-Wall
|
|
|
|
-###### Test for Debian GNU/Linux
|
|
-# If your system is not Debian GNU/Linux please modify the values after
|
|
-# "else" statement. Modifying the values before else is useless, unless
|
|
-# you also set MY_DEBIAN_SYSTEM=1
|
|
-ifeq ($(MY_DEBIAN_SYSTEM),1)
|
|
- MY_MESSAGE_OF_THE_DAY=">>" $(TARGET) compilled for Debian GNU/Linux system. "<<"
|
|
- DRILL_DIR=$(DESTDIR)/usr/share/langdrill
|
|
- BIN_DIR=$(DESTDIR)/usr/bin
|
|
- MAN_DIR=$(DESTDIR)/usr/share/man/man1
|
|
-else
|
|
- MY_MESSAGE_OF_THE_DAY=">>" $(TARGET) compilled for NON-Debian GNU/Linux system. "<<"
|
|
- DRILL_DIR=$(DESTDIR)/usr/local/share/langdrill
|
|
- BIN_DIR=$(DESTDIR)/usr/local/bin
|
|
- MAN_DIR=$(DESTDIR)/usr/local/man/man1
|
|
-endif
|
|
+PREFIX ?= /usr/local
|
|
+DRILL_DIR ?= $(PREFIX)/share/langdrill
|
|
+BIN_DIR ?= $(PREFIX)/bin
|
|
+MAN_DIR ?= $(PREFIX)/share/man
|
|
|
|
CC = g++
|
|
CFLAGS = -g
|
|
@@ -62,21 +50,18 @@
|
|
rm -f $(TARGET) core *~
|
|
|
|
$(TARGET): tarclean $(OBJ)
|
|
- @echo $(MY_MESSAGE_OF_THE_DAY)
|
|
$(CC) $(CFLAGS) $(DEF_FLAGS) -o $(TARGET) $(OBJ) $(LFLAGS)
|
|
|
|
run: tarclean $(OBJ)
|
|
- @echo $(MY_MESSAGE_OF_THE_DAY)
|
|
$(CC) $(CFLAGS) $(DEF_FLAGS) -o $(TARGET) $(OBJ) $(LFLAGS)
|
|
./$(TARGET)
|
|
|
|
build: clean tarclean $(OBJ)
|
|
- @echo $(MY_MESSAGE_OF_THE_DAY)
|
|
$(CC) $(CFLAGS) $(DEF_FLAGS) -o $(TARGET) $(OBJ) $(LFLAGS)
|
|
|
|
install: all
|
|
- install -d $(BIN_DIR) $(DRILL_DIR) $(MAN_DIR)
|
|
- install ./$(TARGET) $(BIN_DIR)
|
|
- install -m644 $(DRILL_SUP) $(DRILL_DIR)
|
|
- ln -sf japanese.drill $(DRILL_DIR)/$(DRILL_DEF)
|
|
- install -m644 $(MAN_PAGE) $(MAN_DIR)
|
|
+ install -d $(DESTDIR)$(BIN_DIR) $(DESTDIR)$(DRILL_DIR) $(DESTDIR)$(MAN_DIR)/man1
|
|
+ install ./$(TARGET) $(DESTDIR)$(BIN_DIR)
|
|
+ install -m644 $(DRILL_SUP) $(DESTDIR)$(DRILL_DIR)
|
|
+ ln -sf japanese.drill $(DESTDIR)$(DRILL_DIR)/$(DRILL_DEF)
|
|
+ install -m644 $(MAN_PAGE) $(DESTDIR)$(MAN_DIR)/man1
|