summarylogtreecommitdiffstats
path: root/discount.patch
blob: 945b8a2c6023bbebe433af08bb7b77d65a4f15af (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
50
51
52
53
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 4a7131e..87d2386 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -2,26 +2,6 @@ project(MarkMyWords)
 
 cmake_minimum_required(VERSION 2.6)
 
-# build the markdown lib
-include(ExternalProject)
-set(DISCOUNT_DEP_PATH ${CMAKE_SOURCE_DIR}/deps/discount)
-set(DISCOUNT_LIB_PATH ${CMAKE_BINARY_DIR}/libmarkdown.a)
-set(DISCOUNT_INCLUDE_PATH ${DISCOUNT_DEP_PATH})
-
-ExternalProject_Add(discount
-  PREFIX ${DISCOUNT_DEP_PATH}
-  SOURCE_DIR ${DISCOUNT_DEP_PATH}
-  CONFIGURE_COMMAND
-      ${DISCOUNT_DEP_PATH}/configure.sh --src=${DISCOUNT_DEP_PATH}
-                                        --prefix=${CMAKE_BINARY_DIR}
-                                        --libdir=${CMAKE_BINARY_DIR}
-                                        --with-fenced-code
-  BUILD_COMMAND make install
-  BUILD_IN_SOURCE 1
-)
-
-include_directories(${DISCOUNT_INCLUDE_PATH})
-
 # build UI lib
 list(APPEND CMAKE_MODULE_PATH ${CMAKE_SOURCE_DIR}/cmake)
 
@@ -39,6 +19,7 @@ pkg_check_modules(DEPS REQUIRED
   gtksourceview-3.0>=3.10
   gthread-2.0
   gtk+-3.0>=3.9.10
+  libmarkdown
 )
 
 add_definitions(${DEPS_CFLAGS})
@@ -115,13 +96,6 @@ OPTIONS
 
 add_executable(mark-my-words ${VALA_C} ${generated_resources})
 
-target_link_libraries(mark-my-words
-  ${DISCOUNT_LIB_PATH})
-
-add_dependencies(mark-my-words
-  discount
-)
-
 install(TARGETS mark-my-words RUNTIME
   DESTINATION bin)