File: CMakeLists.txt

package info (click to toggle)
hatari 2.5.0%2Bdfsg-1
  • links: PTS
  • area: main
  • in suites: trixie
  • size: 12,744 kB
  • sloc: ansic: 164,630; cpp: 8,685; python: 6,251; objc: 1,899; asm: 1,742; sh: 1,668; javascript: 146; makefile: 86; xml: 32
file content (35 lines) | stat: -rw-r--r-- 1,621 bytes parent folder | download | duplicates (2)
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
# conftypes.py is created to source directory (instead of build directory)
# so that Hatari UI can be tested directly from the source directory
add_custom_command(OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/conftypes.py
	COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/gentypes.py < ${CMAKE_CURRENT_SOURCE_DIR}/../src/configuration.c > ${CMAKE_CURRENT_BINARY_DIR}/conftypes.py
	DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/../src/configuration.c ${CMAKE_CURRENT_SOURCE_DIR}/gentypes.py)
add_custom_target(conftypes ALL DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/conftypes.py)

INSTALL(PROGRAMS hatariui
	DESTINATION ${BINDIR})

INSTALL(PROGRAMS hatariui.py debugui.py
	DESTINATION ${DATADIR}/hatariui/)

# Hatari UI images go to same place as python code.
# Changing that would require change also in uihelpers.py
INSTALL(FILES hatari-icon.png hatari-logo.png
	config.py dialogs.py hatari.py uihelpers.py
	${CMAKE_CURRENT_BINARY_DIR}/conftypes.py
	DESTINATION ${DATADIR}/hatariui/)

# Hatari UI Help menu items are searched from docdir.
# Changing their target dir would require change also in uihelpers.py
INSTALL(FILES README TODO release-notes.txt
	DESTINATION ${DOCDIR}/hatariui/)

INSTALL(FILES hatariui.desktop
	DESTINATION share/applications)

if(ENABLE_MAN_PAGES)
	add_custom_target(hatariui_man ALL DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/hatariui.1.gz)
	add_custom_command(OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/hatariui.1.gz
		COMMAND gzip -c -9 ${CMAKE_CURRENT_SOURCE_DIR}/hatariui.1 > ${CMAKE_CURRENT_BINARY_DIR}/hatariui.1.gz
		DEPENDS hatariui.1)
	INSTALL(FILES ${CMAKE_CURRENT_BINARY_DIR}/hatariui.1.gz DESTINATION ${MANDIR})
endif(ENABLE_MAN_PAGES)