blob: f8f7291d57fd1363d09597bccac4059b8b284345 (
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
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
|
ADD_DEFINITIONS(-Wall)
if(FQTERM_USE_STATIC_QT)
ADD_DEFINITIONS(-DFQTERM_USE_STATIC_QT)
endif(FQTERM_USE_STATIC_QT)
find_library(APPKIT_LIBRARY AppKit)
FIND_LIBRARY(CARBON_LIBRARY Carbon)
include_directories(
${QT_INCLUDE_DIR}
${QT_QTCORE_INCLUDE_DIR}
${QT_QTGUI_INCLUDE_DIR}
${CMAKE_CURRENT_SOURCE_DIR}/src/common
${CMAKE_CURRENT_SOURCE_DIR}/src/protocol
${CMAKE_CURRENT_SOURCE_DIR}/src/terminal
${CMAKE_CURRENT_SOURCE_DIR}/src/utilities
${CMAKE_CURRENT_SOURCE_DIR}/src/ui
${CMAKE_CURRENT_SOURCE_DIR}/src/unite
)
link_directories(
${QT_PLUGINS_DIR}/codecs
${QT_PLUGINS_DIR}/imageformats
)
set(MACOSX_BUNDLE_INFO_STRING "FQTerm for you")
set(MACOSX_BUNDLE_ICON_FILE "fqterm")
set(MACOSX_BUNDLE_GUI_IDENTIFIER "FQTerm")
set(MACOSX_BUNDLE_LONG_VERSION_STRING "FQTerm ${FQTERM_VERSION}")
set(MACOSX_BUNDLE_SHORT_VERSION_STRING "${FQTERM_VERSION}")
set(MACOSX_BUNDLE_BUNDLE_NAME "FQTerm")
set(MACOSX_BUNDLE_BUNDLE_VERSION "1.0")
set(MACOSX_BUNDLE_COPYRIGHT "2008, fqterm@gmail.com, FireLakeWalker@gmail.com")
ADD_EXECUTABLE(fqterm
MACOSX_BUNDLE
src/fqterm/main.cpp
)
set(FQ_QT_PLUGINS
qcncodecs qjpcodecs qkrcodecs qtwcodecs
qjpeg qgif qmng)
if(FQTERM_USE_STATIC_QT)
set(FQ_QT_STATIC_PLUGINS
${FQ_QT_PLUGINS})
endif(FQTERM_USE_STATIC_QT)
target_link_libraries(fqterm
${FQTERM_LIBS}
${QT_LIBRARIES}
${QT_QTCORE_LIBRARY}
${QT_QTGUI_LIBRARY}
${QT_QTNETWORK_LIBRARY}
${QT_QTSCRIPT_LIBRARY}
${APPKIT_LIBRARY}
${CARBON_LIBRARY}
${FQ_QT_STATIC_PLUGINS}
${PYTHON_LIB}
${ZLIB_LIBRARIES}
${QT_QTXML_LIBRARIES}
${OPENSSL_CRYPTO_LIBRARY}
)
add_dependencies(fqterm
fqterm_main
fqterm_common
fqterm_terminal
fqterm_protocol
fqterm_ui
fqterm_utilities
fqterm_unite
fqterm_qm_target
)
add_custom_target(love
COMMAND FQTERM_RESOURCE=${CMAKE_SOURCE_DIR}/res ${CMAKE_BINARY_DIR}/fqterm.app/Contents/MacOS/fqterm
DEPENDS ${CMAKE_BINARY_DIR}/fqterm.app/Contents/MacOS/fqterm
)
INSTALL(
DIRECTORY ${CMAKE_SOURCE_DIR}/res/
DESTINATION ${CMAKE_BINARY_DIR}/fqterm.app/Contents/Resources/
DIRECTORY_PERMISSIONS
OWNER_EXECUTE OWNER_WRITE OWNER_READ
GROUP_EXECUTE GROUP_READ
WORLD_EXECUTE WORLD_READ
FILE_PERMISSIONS
OWNER_WRITE OWNER_READ
GROUP_READ
WORLD_READ
PATTERN "*.svn*" EXCLUDE
)
INSTALL(
FILES ${fqterm_qm_files}
DESTINATION ${CMAKE_BINARY_DIR}/fqterm.app/Contents/Resources/dict/
PERMISSIONS
OWNER_WRITE OWNER_READ
GROUP_READ
WORLD_READ
)
add_custom_target(package
COMMAND make install
COMMAND rm -f ${CMAKE_BINARY_DIR}/fqterm.dmg
COMMAND hdiutil create -verbose -srcfolder ${CMAKE_BINARY_DIR}/fqterm.app ${CMAKE_BINARY_DIR}/fqterm.dmg
DEPENDS ${CMAKE_BINARY_DIR}/fqterm.app
)
set(CMAKE_INSTALL_PREFIX ${CMAKE_BINARY_DIR})
include(DeployQt4)
INSTALL_QT4_EXECUTABLE(fqterm.app "${FQ_QT_PLUGINS}" "" "")
|