src/CMakeLists.txt
changeset 53 ec1eec96e433
parent 52 c9401e6a62cb
child 56 99f85cd9b310
equal deleted inserted replaced
52:c9401e6a62cb 53:ec1eec96e433
    11 ADD_DEFINITIONS(-Wall -O2 -ansi)
    11 ADD_DEFINITIONS(-Wall -O2 -ansi)
    12 ADD_DEFINITIONS(-D_XOPEN_SOURCE=500)
    12 ADD_DEFINITIONS(-D_XOPEN_SOURCE=500)
    13 ADD_DEFINITIONS(-DBOT_VERSION=0.99)
    13 ADD_DEFINITIONS(-DBOT_VERSION=0.99)
    14 
    14 
    15 # Includes
    15 # Includes
    16 INCLUDE_DIRECTORIES(../include)
    16 INCLUDE_DIRECTORIES(../include /usr/local/include)
    17 
    17 
    18 # Target Definitions
    18 # Target Definitions
    19 ADD_EXECUTABLE(mcbot compat.c config.c database.c irc.c main.c parse.c)
    19 ADD_EXECUTABLE(mcbot compat.c config.c database.c irc.c main.c parse.c)
    20 ADD_EXECUTABLE(dbtool database.c dbtool.c)
    20 ADD_EXECUTABLE(dbtool database.c dbtool.c)
    21 
    21 
    22 # Install Rules
    22 # Install Rules
    23 INSTALL(TARGETS mcbot RUNTIME DESTINATION /usr/sbin)
    23 INSTALL(TARGETS mcbot RUNTIME DESTINATION sbin)
    24 INSTALL(TARGETS dbtool RUNTIME DESTINATION /usr/bin)
    24 INSTALL(TARGETS dbtool RUNTIME DESTINATION bin)
    25 INSTALL(DIRECTORY ../locale/ DESTINATION /var/lib/mcbot/data/locale)
    25 INSTALL(DIRECTORY ../locale/ DESTINATION /var/lib/mcbot/data/locale)
    26 INSTALL(PROGRAMS ../scripts/runbot DESTINATION /etc/init.d/
    26 INSTALL(PROGRAMS ../scripts/runbot DESTINATION etc/rc.d/ RENAME mcbot)
    27 	RENAME mcbot)
    27 INSTALL(PROGRAMS ../scripts/mcbot.cgi DESTINATION lib/cgi-bin/)
    28 INSTALL(PROGRAMS ../scripts/mcbot.cgi DESTINATION /usr/lib/cgi-bin/)
       
    29 
    28 
    30 # Search required programs
    29 # Search required programs
    31 FIND_PROGRAM(MSGFMT_PROG msgfmt)
    30 FIND_PROGRAM(MSGFMT_PROG msgfmt)
    32 IF (MSGFMT_PROG)
    31 IF (MSGFMT_PROG)
    33     EXEC_PROGRAM(${MSGFMT_PROG} ../locale ARGS -o de/LC_MESSAGES/mcbot.mo de/mcbot.po)
    32     EXEC_PROGRAM(${MSGFMT_PROG} ../locale ARGS -o de/LC_MESSAGES/mcbot.mo de/mcbot.po)