aboutsummaryrefslogtreecommitdiffstats
path: root/host/lib/CMakeLists.txt
diff options
context:
space:
mode:
authorJosh Blum <josh@joshknows.com>2010-02-25 18:26:00 +0000
committerJosh Blum <josh@joshknows.com>2010-02-25 18:26:00 +0000
commita9f8ba6e37e1349ce61b5022ddaff1c64dd52bd3 (patch)
tree20f00ce9d86c52b194831c026cf8a5f0d6419186 /host/lib/CMakeLists.txt
parentc95a158548e93d1ea37061e0b937e78ab0486b57 (diff)
downloaduhd-a9f8ba6e37e1349ce61b5022ddaff1c64dd52bd3.tar.gz
uhd-a9f8ba6e37e1349ce61b5022ddaff1c64dd52bd3.tar.bz2
uhd-a9f8ba6e37e1349ce61b5022ddaff1c64dd52bd3.zip
added usrp1e conditional compilation, and checking of device node (aka file for now)
Diffstat (limited to 'host/lib/CMakeLists.txt')
-rw-r--r--host/lib/CMakeLists.txt14
1 files changed, 11 insertions, 3 deletions
diff --git a/host/lib/CMakeLists.txt b/host/lib/CMakeLists.txt
index edfefa127..96fba6e53 100644
--- a/host/lib/CMakeLists.txt
+++ b/host/lib/CMakeLists.txt
@@ -41,9 +41,17 @@ SET(libuhd_sources
########################################################################
# Conditionally add the usrp1e sources
########################################################################
-LIST(APPEND libuhd_sources
- usrp/usrp1e/usrp1e_none.cpp
-)
+INCLUDE(CheckIncludeFile)
+CHECK_INCLUDE_FILE("linux/ioctl.h" HAS_LINUX_IOCTL_H)
+IF(HAS_LINUX_IOCTL_H)
+ LIST(APPEND libuhd_sources
+ usrp/usrp1e/usrp1e_impl.cpp
+ )
+ELSE(HAS_LINUX_IOCTL_H)
+ LIST(APPEND libuhd_sources
+ usrp/usrp1e/usrp1e_none.cpp
+ )
+ENDIF(HAS_LINUX_IOCTL_H)
########################################################################
# Setup libuhd library