Compatibility: use default prefix and std make switches
authorMarkus Bröker <mbroeker@volpe.spectre.org>
Sat, 03 Apr 2010 15:11:03 +0200
changeset 53 ec1eec96e433
parent 52 c9401e6a62cb
child 54 e21f837e2b13
Compatibility: use default prefix and std make switches
Makefile
src/CMakeLists.txt
--- a/Makefile
+++ b/Makefile
@@ -1,7 +1,8 @@
-MAKE=make --no-print-directory
+MAKE=make
 CMAKE=cmake
 RMDIR=rm -rf
 RM=rm -f
+INDENT=indent
 
 all: build
 
@@ -33,6 +34,6 @@
 	$(MAKE) -C build install
 
 beauty:
-	find . -name '*.[ch]' -exec indent {} \;
+	find . -name '*.[ch]' -exec $(INDENT) {} \;
 	find . -name '*.[ch]' -exec eraser {} \;
 	find . -name '*~' -exec rm -f {} \;
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
@@ -13,19 +13,18 @@
 ADD_DEFINITIONS(-DBOT_VERSION=0.99)
 
 # Includes
-INCLUDE_DIRECTORIES(../include)
+INCLUDE_DIRECTORIES(../include /usr/local/include)
 
 # Target Definitions
 ADD_EXECUTABLE(mcbot compat.c config.c database.c irc.c main.c parse.c)
 ADD_EXECUTABLE(dbtool database.c dbtool.c)
 
 # Install Rules
-INSTALL(TARGETS mcbot RUNTIME DESTINATION /usr/sbin)
-INSTALL(TARGETS dbtool RUNTIME DESTINATION /usr/bin)
+INSTALL(TARGETS mcbot RUNTIME DESTINATION sbin)
+INSTALL(TARGETS dbtool RUNTIME DESTINATION bin)
 INSTALL(DIRECTORY ../locale/ DESTINATION /var/lib/mcbot/data/locale)
-INSTALL(PROGRAMS ../scripts/runbot DESTINATION /etc/init.d/
-	RENAME mcbot)
-INSTALL(PROGRAMS ../scripts/mcbot.cgi DESTINATION /usr/lib/cgi-bin/)
+INSTALL(PROGRAMS ../scripts/runbot DESTINATION etc/rc.d/ RENAME mcbot)
+INSTALL(PROGRAMS ../scripts/mcbot.cgi DESTINATION lib/cgi-bin/)
 
 # Search required programs
 FIND_PROGRAM(MSGFMT_PROG msgfmt)