config now allows for custom installation paths (for easier packaging)

git-svn-id: svn://svn.code.sf.net/p/qjoypad/code/trunk@98 c05e91a0-76c8-4ec0-b377-ef19ce7cc080
This commit is contained in:
John Toman
2009-08-08 20:33:49 +00:00
committed by virtuoussin13
parent 78eb5aafb3
commit a23ba507aa
3 changed files with 22 additions and 602 deletions

View File

@ -1,590 +0,0 @@
#############################################################################
# Makefile for building: qjoypad
# Generated by qmake (2.01a) (Qt 4.5.1) on: Mon May 25 00:43:37 2009
# Project: qjoypad.pro
# Template: app
# Command: /usr/bin/qmake -unix -o Makefile qjoypad.pro
#############################################################################
####### Compiler, tools and options
CC = gcc
CXX = g++
DEFINES = -DDEVDIR="\"/dev/input\"" -DICON24="\"/share/pixmaps/qjoypad/icon24.png\"" -DICON64="\"/share/pixmaps/qjoypad/icon64.png\"" -DQT_NO_DEBUG -DQT_GUI_LIB -DQT_CORE_LIB -DQT_SHARED
CFLAGS = -pipe -march=i686 -mtune=generic -O2 -pipe -Wall -W -D_REENTRANT $(DEFINES)
CXXFLAGS = -g -pipe -march=i686 -mtune=generic -O2 -pipe -Wall -W -D_REENTRANT $(DEFINES)
INCPATH = -I/usr/share/qt/mkspecs/linux-g++ -I. -I/usr/include/QtCore -I/usr/include/QtGui -I/usr/include -I. -Itrayicon -I. -I.
LINK = g++
LFLAGS = -Wl,-O1 -Wl,-rpath,/usr/lib
LIBS = $(SUBLIBS) -L/usr/lib -lXtst -lQtGui -L/usr/lib -L/usr/X11R6/lib -pthread -lpng -lfreetype -lgobject-2.0 -lSM -lICE -pthread -pthread -lXrender -lfontconfig -lXext -lX11 -lQtCore -lz -lm -pthread -lgthread-2.0 -lrt -lglib-2.0 -ldl -lpthread
AR = ar cqs
RANLIB =
QMAKE = /usr/bin/qmake
TAR = tar -cf
COMPRESS = gzip -9f
COPY = cp -f
SED = sed
COPY_FILE = $(COPY)
COPY_DIR = $(COPY) -r
INSTALL_FILE = install -m 644 -p
INSTALL_DIR = $(COPY_DIR)
INSTALL_PROGRAM = install -m 755 -p
DEL_FILE = rm -f
SYMLINK = ln -sf
DEL_DIR = rmdir
MOVE = mv -f
CHK_DIR_EXISTS= test -d
MKDIR = mkdir -p
####### Output directory
OBJECTS_DIR = ./
####### Files
SOURCES = axis.cpp \
axis_edit.cpp \
axisw.cpp \
button.cpp \
button_edit.cpp \
buttonw.cpp \
event.cpp \
flash.cpp \
icon.cpp \
joypad.cpp \
joypadw.cpp \
joyslider.cpp \
keycode.cpp \
layout.cpp \
layout_edit.cpp \
main.cpp \
quickset.cpp \
getkey.cpp \
trayicon/trayicon.cpp \
trayicon/trayicon_x11.cpp moc_axis.cpp \
moc_axis_edit.cpp \
moc_button.cpp \
moc_button_edit.cpp \
moc_flash.cpp \
moc_icon.cpp \
moc_joypad.cpp \
moc_joypadw.cpp \
moc_keycode.cpp \
moc_layout.cpp \
moc_getkey.cpp \
moc_trayicon.cpp
OBJECTS = axis.o \
axis_edit.o \
axisw.o \
button.o \
button_edit.o \
buttonw.o \
event.o \
flash.o \
icon.o \
joypad.o \
joypadw.o \
joyslider.o \
keycode.o \
layout.o \
layout_edit.o \
main.o \
quickset.o \
getkey.o \
trayicon.o \
trayicon_x11.o \
moc_axis.o \
moc_axis_edit.o \
moc_button.o \
moc_button_edit.o \
moc_flash.o \
moc_icon.o \
moc_joypad.o \
moc_joypadw.o \
moc_keycode.o \
moc_layout.o \
moc_getkey.o \
moc_trayicon.o
DIST = /usr/share/qt/mkspecs/common/g++.conf \
/usr/share/qt/mkspecs/common/unix.conf \
/usr/share/qt/mkspecs/common/linux.conf \
/usr/share/qt/mkspecs/qconfig.pri \
/usr/share/qt/mkspecs/features/qt_functions.prf \
/usr/share/qt/mkspecs/features/qt_config.prf \
/usr/share/qt/mkspecs/features/exclusive_builds.prf \
/usr/share/qt/mkspecs/features/default_pre.prf \
/usr/share/qt/mkspecs/features/release.prf \
/usr/share/qt/mkspecs/features/default_post.prf \
/usr/share/qt/mkspecs/features/warn_on.prf \
/usr/share/qt/mkspecs/features/qt.prf \
/usr/share/qt/mkspecs/features/unix/thread.prf \
/usr/share/qt/mkspecs/features/moc.prf \
/usr/share/qt/mkspecs/features/resources.prf \
/usr/share/qt/mkspecs/features/uic.prf \
/usr/share/qt/mkspecs/features/yacc.prf \
/usr/share/qt/mkspecs/features/lex.prf \
/usr/share/qt/mkspecs/features/include_source_dir.prf \
qjoypad.pro
QMAKE_TARGET = qjoypad
DESTDIR =
TARGET = qjoypad
first: all
####### Implicit rules
.SUFFIXES: .o .c .cpp .cc .cxx .C
.cpp.o:
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o "$@" "$<"
.cc.o:
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o "$@" "$<"
.cxx.o:
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o "$@" "$<"
.C.o:
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o "$@" "$<"
.c.o:
$(CC) -c $(CFLAGS) $(INCPATH) -o "$@" "$<"
####### Build rules
all: Makefile $(TARGET)
$(TARGET): $(OBJECTS)
$(LINK) $(LFLAGS) -o $(TARGET) $(OBJECTS) $(OBJCOMP) $(LIBS)
Makefile: qjoypad.pro /usr/share/qt/mkspecs/linux-g++/qmake.conf /usr/share/qt/mkspecs/common/g++.conf \
/usr/share/qt/mkspecs/common/unix.conf \
/usr/share/qt/mkspecs/common/linux.conf \
/usr/share/qt/mkspecs/qconfig.pri \
/usr/share/qt/mkspecs/features/qt_functions.prf \
/usr/share/qt/mkspecs/features/qt_config.prf \
/usr/share/qt/mkspecs/features/exclusive_builds.prf \
/usr/share/qt/mkspecs/features/default_pre.prf \
/usr/share/qt/mkspecs/features/release.prf \
/usr/share/qt/mkspecs/features/default_post.prf \
/usr/share/qt/mkspecs/features/warn_on.prf \
/usr/share/qt/mkspecs/features/qt.prf \
/usr/share/qt/mkspecs/features/unix/thread.prf \
/usr/share/qt/mkspecs/features/moc.prf \
/usr/share/qt/mkspecs/features/resources.prf \
/usr/share/qt/mkspecs/features/uic.prf \
/usr/share/qt/mkspecs/features/yacc.prf \
/usr/share/qt/mkspecs/features/lex.prf \
/usr/share/qt/mkspecs/features/include_source_dir.prf \
/usr/lib/libQtGui.prl \
/usr/lib/libQtCore.prl
$(QMAKE) -unix -o Makefile qjoypad.pro
/usr/share/qt/mkspecs/common/g++.conf:
/usr/share/qt/mkspecs/common/unix.conf:
/usr/share/qt/mkspecs/common/linux.conf:
/usr/share/qt/mkspecs/qconfig.pri:
/usr/share/qt/mkspecs/features/qt_functions.prf:
/usr/share/qt/mkspecs/features/qt_config.prf:
/usr/share/qt/mkspecs/features/exclusive_builds.prf:
/usr/share/qt/mkspecs/features/default_pre.prf:
/usr/share/qt/mkspecs/features/release.prf:
/usr/share/qt/mkspecs/features/default_post.prf:
/usr/share/qt/mkspecs/features/warn_on.prf:
/usr/share/qt/mkspecs/features/qt.prf:
/usr/share/qt/mkspecs/features/unix/thread.prf:
/usr/share/qt/mkspecs/features/moc.prf:
/usr/share/qt/mkspecs/features/resources.prf:
/usr/share/qt/mkspecs/features/uic.prf:
/usr/share/qt/mkspecs/features/yacc.prf:
/usr/share/qt/mkspecs/features/lex.prf:
/usr/share/qt/mkspecs/features/include_source_dir.prf:
/usr/lib/libQtGui.prl:
/usr/lib/libQtCore.prl:
qmake: FORCE
@$(QMAKE) -unix -o Makefile qjoypad.pro
dist:
@$(CHK_DIR_EXISTS) .tmp/qjoypad1.0.0 || $(MKDIR) .tmp/qjoypad1.0.0
$(COPY_FILE) --parents $(SOURCES) $(DIST) .tmp/qjoypad1.0.0/ && $(COPY_FILE) --parents axis.h axis_edit.h axisw.h button.h button_edit.h buttonw.h constant.h device.h error.h event.h flash.h icon.h joypad.h joypadw.h joyslider.h keycode.h layout.h getkey.h layout_edit.h quickset.h trayicon/trayicon.h .tmp/qjoypad1.0.0/ && $(COPY_FILE) --parents axis.cpp axis_edit.cpp axisw.cpp button.cpp button_edit.cpp buttonw.cpp event.cpp flash.cpp icon.cpp joypad.cpp joypadw.cpp joyslider.cpp keycode.cpp layout.cpp layout_edit.cpp main.cpp quickset.cpp getkey.cpp trayicon/trayicon.cpp trayicon/trayicon_x11.cpp .tmp/qjoypad1.0.0/ && (cd `dirname .tmp/qjoypad1.0.0` && $(TAR) qjoypad1.0.0.tar qjoypad1.0.0 && $(COMPRESS) qjoypad1.0.0.tar) && $(MOVE) `dirname .tmp/qjoypad1.0.0`/qjoypad1.0.0.tar.gz . && $(DEL_FILE) -r .tmp/qjoypad1.0.0
clean:compiler_clean
-$(DEL_FILE) $(OBJECTS)
-$(DEL_FILE) *~ core *.core
####### Sub-libraries
distclean: clean
-$(DEL_FILE) $(TARGET)
-$(DEL_FILE) Makefile
mocclean: compiler_moc_header_clean compiler_moc_source_clean
mocables: compiler_moc_header_make_all compiler_moc_source_make_all
compiler_moc_header_make_all: moc_axis.cpp moc_axis_edit.cpp moc_button.cpp moc_button_edit.cpp moc_flash.cpp moc_icon.cpp moc_joypad.cpp moc_joypadw.cpp moc_keycode.cpp moc_layout.cpp moc_getkey.cpp moc_trayicon.cpp
compiler_moc_header_clean:
-$(DEL_FILE) moc_axis.cpp moc_axis_edit.cpp moc_button.cpp moc_button_edit.cpp moc_flash.cpp moc_icon.cpp moc_joypad.cpp moc_joypadw.cpp moc_keycode.cpp moc_layout.cpp moc_getkey.cpp moc_trayicon.cpp
moc_axis.cpp: constant.h \
axis.h
/usr/bin/moc $(DEFINES) $(INCPATH) axis.h -o moc_axis.cpp
moc_axis_edit.cpp: axis.h \
constant.h \
joyslider.h \
keycode.h \
axis_edit.h
/usr/bin/moc $(DEFINES) $(INCPATH) axis_edit.h -o moc_axis_edit.cpp
moc_button.cpp: keycode.h \
constant.h \
button.h
/usr/bin/moc $(DEFINES) $(INCPATH) button.h -o moc_button.cpp
moc_button_edit.cpp: button.h \
keycode.h \
constant.h \
button_edit.h
/usr/bin/moc $(DEFINES) $(INCPATH) button_edit.h -o moc_button_edit.cpp
moc_flash.cpp: flash.h
/usr/bin/moc $(DEFINES) $(INCPATH) flash.h -o moc_flash.cpp
moc_icon.cpp: constant.h \
icon.h
/usr/bin/moc $(DEFINES) $(INCPATH) icon.h -o moc_icon.cpp
moc_joypad.cpp: button.h \
keycode.h \
constant.h \
axis.h \
joypadw.h \
axisw.h \
flash.h \
axis_edit.h \
joyslider.h \
joypad.h \
error.h \
buttonw.h \
button_edit.h \
quickset.h \
joypad.h
/usr/bin/moc $(DEFINES) $(INCPATH) joypad.h -o moc_joypad.cpp
moc_joypadw.cpp: axisw.h \
axis.h \
constant.h \
flash.h \
axis_edit.h \
joyslider.h \
keycode.h \
joypad.h \
button.h \
joypadw.h \
buttonw.h \
button_edit.h \
quickset.h \
error.h \
joypadw.h
/usr/bin/moc $(DEFINES) $(INCPATH) joypadw.h -o moc_joypadw.cpp
moc_keycode.cpp: constant.h \
keycode.h
/usr/bin/moc $(DEFINES) $(INCPATH) keycode.h -o moc_keycode.cpp
moc_layout.cpp: joypad.h \
button.h \
keycode.h \
constant.h \
axis.h \
joypadw.h \
axisw.h \
flash.h \
axis_edit.h \
joyslider.h \
buttonw.h \
button_edit.h \
quickset.h \
error.h \
device.h \
trayicon/trayicon.h \
icon.h \
layout_edit.h \
layout.h \
layout.h
/usr/bin/moc $(DEFINES) $(INCPATH) layout.h -o moc_layout.cpp
moc_getkey.cpp: constant.h \
getkey.h
/usr/bin/moc $(DEFINES) $(INCPATH) getkey.h -o moc_getkey.cpp
moc_trayicon.cpp: trayicon/trayicon.h
/usr/bin/moc $(DEFINES) $(INCPATH) trayicon/trayicon.h -o moc_trayicon.cpp
compiler_rcc_make_all:
compiler_rcc_clean:
compiler_image_collection_make_all: qmake_image_collection.cpp
compiler_image_collection_clean:
-$(DEL_FILE) qmake_image_collection.cpp
compiler_moc_source_make_all:
compiler_moc_source_clean:
compiler_uic_make_all:
compiler_uic_clean:
compiler_yacc_decl_make_all:
compiler_yacc_decl_clean:
compiler_yacc_impl_make_all:
compiler_yacc_impl_clean:
compiler_lex_make_all:
compiler_lex_clean:
compiler_clean: compiler_moc_header_clean
####### Compile
axis.o: axis.cpp axis.h \
constant.h \
event.h
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o axis.o axis.cpp
axis_edit.o: axis_edit.cpp axis_edit.h \
axis.h \
constant.h \
joyslider.h \
keycode.h
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o axis_edit.o axis_edit.cpp
axisw.o: axisw.cpp axisw.h \
axis.h \
constant.h \
flash.h \
axis_edit.h \
joyslider.h \
keycode.h
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o axisw.o axisw.cpp
button.o: button.cpp button.h \
keycode.h \
constant.h \
event.h
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o button.o button.cpp
button_edit.o: button_edit.cpp button_edit.h \
button.h \
keycode.h \
constant.h
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o button_edit.o button_edit.cpp
buttonw.o: buttonw.cpp buttonw.h \
button.h \
keycode.h \
constant.h \
button_edit.h \
flash.h
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o buttonw.o buttonw.cpp
event.o: event.cpp event.h
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o event.o event.cpp
flash.o: flash.cpp flash.h
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o flash.o flash.cpp
icon.o: icon.cpp icon.h \
constant.h
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o icon.o icon.cpp
joypad.o: joypad.cpp joypad.h \
button.h \
keycode.h \
constant.h \
axis.h \
joypadw.h \
axisw.h \
flash.h \
axis_edit.h \
joyslider.h \
buttonw.h \
button_edit.h \
quickset.h \
error.h
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o joypad.o joypad.cpp
joypadw.o: joypadw.cpp joypadw.h \
axisw.h \
axis.h \
constant.h \
flash.h \
axis_edit.h \
joyslider.h \
keycode.h \
joypad.h \
button.h \
error.h \
buttonw.h \
button_edit.h \
quickset.h
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o joypadw.o joypadw.cpp
joyslider.o: joyslider.cpp joyslider.h \
constant.h
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o joyslider.o joyslider.cpp
keycode.o: keycode.cpp keycode.h \
constant.h \
getkey.h
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o keycode.o keycode.cpp
layout.o: layout.cpp layout.h \
joypad.h \
button.h \
keycode.h \
constant.h \
axis.h \
joypadw.h \
axisw.h \
flash.h \
axis_edit.h \
joyslider.h \
buttonw.h \
button_edit.h \
quickset.h \
error.h \
device.h \
trayicon/trayicon.h \
icon.h \
layout_edit.h
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o layout.o layout.cpp
layout_edit.o: layout_edit.cpp layout_edit.h \
flash.h \
layout.h \
joypad.h \
button.h \
keycode.h \
constant.h \
axis.h \
joypadw.h \
axisw.h \
axis_edit.h \
joyslider.h \
buttonw.h \
button_edit.h \
quickset.h \
error.h \
device.h \
trayicon/trayicon.h \
icon.h
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o layout_edit.o layout_edit.cpp
main.o: main.cpp layout.h \
joypad.h \
button.h \
keycode.h \
constant.h \
axis.h \
joypadw.h \
axisw.h \
flash.h \
axis_edit.h \
joyslider.h \
buttonw.h \
button_edit.h \
quickset.h \
error.h \
device.h \
trayicon/trayicon.h \
icon.h \
layout_edit.h \
event.h
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o main.o main.cpp
quickset.o: quickset.cpp quickset.h \
joypad.h \
button.h \
keycode.h \
constant.h \
axis.h \
joypadw.h \
axisw.h \
flash.h \
axis_edit.h \
joyslider.h \
buttonw.h \
button_edit.h \
error.h \
getkey.h
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o quickset.o quickset.cpp
getkey.o: getkey.cpp getkey.h \
constant.h
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o getkey.o getkey.cpp
trayicon.o: trayicon/trayicon.cpp trayicon/trayicon.h
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o trayicon.o trayicon/trayicon.cpp
trayicon_x11.o: trayicon/trayicon_x11.cpp trayicon/trayicon.h
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o trayicon_x11.o trayicon/trayicon_x11.cpp
moc_axis.o: moc_axis.cpp
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o moc_axis.o moc_axis.cpp
moc_axis_edit.o: moc_axis_edit.cpp
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o moc_axis_edit.o moc_axis_edit.cpp
moc_button.o: moc_button.cpp
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o moc_button.o moc_button.cpp
moc_button_edit.o: moc_button_edit.cpp
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o moc_button_edit.o moc_button_edit.cpp
moc_flash.o: moc_flash.cpp
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o moc_flash.o moc_flash.cpp
moc_icon.o: moc_icon.cpp
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o moc_icon.o moc_icon.cpp
moc_joypad.o: moc_joypad.cpp
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o moc_joypad.o moc_joypad.cpp
moc_joypadw.o: moc_joypadw.cpp
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o moc_joypadw.o moc_joypadw.cpp
moc_keycode.o: moc_keycode.cpp
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o moc_keycode.o moc_keycode.cpp
moc_layout.o: moc_layout.cpp
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o moc_layout.o moc_layout.cpp
moc_getkey.o: moc_getkey.cpp
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o moc_getkey.o moc_getkey.cpp
moc_trayicon.o: moc_trayicon.cpp
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o moc_trayicon.o moc_trayicon.cpp
####### Install
install_target: first FORCE
@$(CHK_DIR_EXISTS) $(INSTALL_ROOT)/bin/ || $(MKDIR) $(INSTALL_ROOT)/bin/
-$(INSTALL_PROGRAM) "$(QMAKE_TARGET)" "$(INSTALL_ROOT)/bin/$(QMAKE_TARGET)"
-strip "$(INSTALL_ROOT)/bin/$(QMAKE_TARGET)"
uninstall_target: FORCE
-$(DEL_FILE) "$(INSTALL_ROOT)/bin/$(QMAKE_TARGET)"
-$(DEL_DIR) $(INSTALL_ROOT)/bin/
install_icons: first FORCE
@$(CHK_DIR_EXISTS) $(INSTALL_ROOT)/share/pixmaps/qjoypad/ || $(MKDIR) $(INSTALL_ROOT)/share/pixmaps/qjoypad/
cp ../icons/* /share/pixmaps/qjoypad; cd /share/pixmaps/qjoypad; ln -sf gamepad4-24x24.png icon24.png; ln -sf gamepad3-64x64.png icon64.png; chmod -R a+r /share/pixmaps/qjoypad
install_doc: first FORCE
@$(CHK_DIR_EXISTS) $(INSTALL_ROOT)/doc/qjoypad3/ || $(MKDIR) $(INSTALL_ROOT)/doc/qjoypad3/
cp ../README.txt ../LICENSE.txt /doc/qjoypad3
install: install_target install_icons install_doc FORCE
uninstall: uninstall_target FORCE
FORCE:

View File

@ -3,6 +3,7 @@
devdir="/dev/input" devdir="/dev/input"
prefix="/usr/local" prefix="/usr/local"
installdir="";
plain_keys="" plain_keys=""
for arg in $* for arg in $*
@ -25,7 +26,9 @@ Options:
less attractive and readable, but will save processor power less attractive and readable, but will save processor power
and ensure that you see the right names for keys you press. and ensure that you see the right names for keys you press.
--help Show this message. --install-dir=DIR Sets an optional installation path that will be prepended
to prefix during installation.
--help Show this message.
"; exit 0;; "; exit 0;;
--devdir=*) devdir=${arg##*=} --devdir=*) devdir=${arg##*=}
if [[ ! -d $devdir ]] if [[ ! -d $devdir ]]
@ -34,11 +37,17 @@ Options:
exit 1 exit 1
fi ;; fi ;;
--prefix=*) prefix=${arg##*=} --prefix=*) prefix=${arg##*=}
if [[ ! -d $prefix ]] if [[ ! -d $prefix ]]
then then
echo "Invalid prefix directory given: $prefix" echo "Invalid prefix directory given: $prefix"
exit 1 exit 1
fi ;; fi;;
--install-dir=*) installdir=${arg##*=}
if [[ ! -d $installdir ]]
then
echo "invalid destination directory given: $installdir";
exit 1
fi;;
--plain_keys) plain_keys="PLAIN_KEYS";; --plain_keys) plain_keys="PLAIN_KEYS";;
*) echo "Unrecognized argument: \"$arg\". Try ./config --help for help." *) echo "Unrecognized argument: \"$arg\". Try ./config --help for help."
esac esac
@ -47,8 +56,10 @@ done
arg1="DEVDIR=$devdir" arg1="DEVDIR=$devdir"
arg2="PREFIX=$prefix" arg2="PREFIX=$prefix"
arg3="DEFINES += $plain_keys" arg3="DEFINES += $plain_keys"
arg4="DESTDIR=${installdir}/${prefix}/bin"
arg5="INSTALL=$installdir"
qmake -makefile "$arg1" "$arg2" "$arg3" qjoypad.pro qmake -makefile "$arg1" "$arg2" "$arg3" "$arg4" "$arg5" qjoypad.pro
echo " echo "
Configuring QJoyPad installation... Configuring QJoyPad installation...

View File

@ -11,12 +11,11 @@
##### Setup Targets ##### ##### Setup Targets #####
target.path = $$PREFIX/bin icons.path = $$INSTALL/$$PREFIX/share/pixmaps/qjoypad
icons.conf_path = $$PREFIX/share/pixmaps/qjoypad
icons.path = $$PREFIX/share/pixmaps/qjoypad
icons.extra = cp ../icons/* $${icons.path}; cd $${icons.path}; ln -sf gamepad4-24x24.png icon24.png; ln -sf gamepad3-64x64.png icon64.png; chmod -R a+r $${icons.path} icons.extra = cp ../icons/* $${icons.path}; cd $${icons.path}; ln -sf gamepad4-24x24.png icon24.png; ln -sf gamepad3-64x64.png icon64.png; chmod -R a+r $${icons.path}
doc.path = $$PREFIX/doc/qjoypad3 doc.path = $$INSTALL/$$PREFIX/share/doc/qjoypad3
doc.extra = cp ../README.txt ../LICENSE.txt $${doc.path} doc.extra = cp ../README.txt ../LICENSE.txt $${doc.path}
@ -26,9 +25,9 @@ doc.extra = cp ../README.txt ../LICENSE.txt $${doc.path}
##### Setup Compile ##### ##### Setup Compile #####
DEFINES += DEVDIR='"$$DEVDIR"' DEFINES += DEVDIR='\\\"$$DEVDIR\\\"'
DEFINES += ICON24='\"$${icons.path}/icon24.png\"' DEFINES += ICON24='\\\"$${icons.conf_path}/icon24.png\\\"'
DEFINES += ICON64='\"$${icons.path}/icon64.png\"' DEFINES += ICON64='\\\"$${icons.conf_path}/icon64.png\\\"'
TEMPLATE = app TEMPLATE = app
DEPENDPATH += trayicon DEPENDPATH += trayicon