summaryrefslogtreecommitdiff
path: root/src/plugins/scripts/CMakeLists.txt
blob: 7f3858d69f7d6909c279c9b75749baa371e0a18c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
# Copyright (c) 2003-2008 FlashCode <flashcode@flashtux.org>
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program.  If not, see <http://www.gnu.org/licenses/>.
#

SET(LIB_SCRIPTS_SRC script.c script.h)

ADD_DEFINITIONS(${CMAKE_SHARED_LIBRARY_C_FLAGS})
INCLUDE_DIRECTORIES(${CMAKE_BINARY_DIR})
ADD_LIBRARY(weechat_scripts STATIC ${LIB_SCRIPTS_SRC})

IF(NOT DISABLE_PERL)
  FIND_PACKAGE(Perl)
  IF(PERL_FOUND)
    ADD_SUBDIRECTORY( perl )
  ENDIF(PERL_FOUND)
ENDIF(NOT DISABLE_PERL)

IF(NOT DISABLE_PYTHON)
  FIND_PACKAGE(Python)
  IF(PYTHON_FOUND)
    ADD_SUBDIRECTORY( python )
  ENDIF(PYTHON_FOUND)
ENDIF(NOT DISABLE_PYTHON)

IF(NOT DISABLE_RUBY)
  FIND_PACKAGE(Ruby)
  IF(RUBY_FOUND)
    ADD_SUBDIRECTORY( ruby )
  ENDIF(RUBY_FOUND)
ENDIF(NOT DISABLE_RUBY)

IF(NOT DISABLE_LUA)
  FIND_PACKAGE(Lua)
  IF(LUA_FOUND)
    ADD_SUBDIRECTORY( lua )
  ENDIF(LUA_FOUND)
ENDIF(NOT DISABLE_LUA)