| 1 |
## -*- mode: CMake -*- |
| 2 |
## |
| 3 |
## Copyright (c) 2012, 2013, 2014, 2015, 2016 The University of Utah |
| 4 |
## All rights reserved. |
| 5 |
## |
| 6 |
## This file is distributed under the University of Illinois Open Source |
| 7 |
## License. See the file COPYING for details. |
| 8 |
|
| 9 |
############################################################################### |
| 10 |
|
| 11 |
cmake_minimum_required(VERSION 2.8.12) |
| 12 |
|
| 13 |
# find_package(FLEX) is done by the topmost "CMakeLists.txt" file. |
| 14 |
|
| 15 |
############################################################################### |
| 16 |
|
| 17 |
project(clex) |
| 18 |
|
| 19 |
include_directories(${PROJECT_BINARY_DIR}) |
| 20 |
include_directories(${PROJECT_SOURCE_DIR}) |
| 21 |
include_directories(${CMAKE_BINARY_DIR}) |
| 22 |
|
| 23 |
FLEX_TARGET(clex_scanner |
| 24 |
clex.l |
| 25 |
${PROJECT_BINARY_DIR}/clex.c |
| 26 |
) |
| 27 |
|
| 28 |
add_executable(clex |
| 29 |
${FLEX_clex_scanner_OUTPUTS} |
| 30 |
defs.h |
| 31 |
driver.c |
| 32 |
) |
| 33 |
|
| 34 |
############################################################################### |
| 35 |
|
| 36 |
project(strlex) |
| 37 |
include_directories(${PROJECT_BINARY_DIR}) |
| 38 |
include_directories(${PROJECT_SOURCE_DIR}) |
| 39 |
include_directories(${CMAKE_BINARY_DIR}) |
| 40 |
|
| 41 |
FLEX_TARGET(strlex_scanner |
| 42 |
strlex.l |
| 43 |
${PROJECT_BINARY_DIR}/strlex.c |
| 44 |
) |
| 45 |
|
| 46 |
add_executable(strlex |
| 47 |
${FLEX_strlex_scanner_OUTPUTS} |
| 48 |
defs.h |
| 49 |
driver.c |
| 50 |
) |
| 51 |
|
| 52 |
############################################################################### |
| 53 |
|
| 54 |
install(TARGETS clex strlex |
| 55 |
RUNTIME DESTINATION "libexec" |
| 56 |
) |
| 57 |
|
| 58 |
############################################################################### |
| 59 |
|
| 60 |
## End of file. |