2014-08-30 10:17:52 +00:00
|
|
|
if(APPLE)
|
2015-04-09 04:28:24 +00:00
|
|
|
file(GLOB OSQUERY_OBJC_TABLES "*/darwin/*.mm")
|
2015-02-03 05:21:36 +00:00
|
|
|
ADD_OSQUERY_OBJCXX_LIBRARY(FALSE osquery_tables_objc
|
2015-04-09 04:28:24 +00:00
|
|
|
${OSQUERY_OBJC_TABLES}
|
2014-08-30 10:17:52 +00:00
|
|
|
)
|
2014-08-30 10:24:35 +00:00
|
|
|
|
2015-04-09 04:28:24 +00:00
|
|
|
file(GLOB OSQUERY_DARWIN_TABLES "*/darwin/*.cpp")
|
2015-02-03 05:21:36 +00:00
|
|
|
ADD_OSQUERY_LIBRARY(FALSE osquery_tables_darwin
|
2015-04-09 04:28:24 +00:00
|
|
|
${OSQUERY_DARWIN_TABLES}
|
2014-08-30 10:24:35 +00:00
|
|
|
)
|
2014-09-06 01:12:37 +00:00
|
|
|
|
2015-02-03 05:21:36 +00:00
|
|
|
ADD_OSQUERY_LINK(FALSE "-framework CoreFoundation")
|
|
|
|
ADD_OSQUERY_LINK(FALSE "-framework Security")
|
|
|
|
ADD_OSQUERY_LINK(FALSE "-framework OpenDirectory")
|
|
|
|
ADD_OSQUERY_LINK(FALSE "-framework DiskArbitration")
|
2015-05-20 17:50:25 +00:00
|
|
|
ADD_OSQUERY_LINK(FALSE "-framework CoreServices")
|
|
|
|
|
|
|
|
file(GLOB OSQUERY_DARWIN_TABLES_TESTS "*/darwin/tests/*.cpp")
|
|
|
|
ADD_OSQUERY_TABLE_TEST(${OSQUERY_DARWIN_TABLES_TESTS})
|
2014-11-13 20:00:41 +00:00
|
|
|
elseif(FREEBSD)
|
2015-04-09 04:28:24 +00:00
|
|
|
file(GLOB OSQUERY_FREEBSD_TABLES "*/freebsd/*.cpp")
|
2015-02-03 05:21:36 +00:00
|
|
|
ADD_OSQUERY_LIBRARY(FALSE osquery_tables_freebsd
|
2015-04-09 04:28:24 +00:00
|
|
|
${OSQUERY_FREEBSD_TABLES}
|
2014-11-13 20:00:41 +00:00
|
|
|
)
|
2015-04-27 09:12:58 +00:00
|
|
|
|
|
|
|
file(GLOB OSQUERY_FREEBSD_TABLES_TESTS "*/freebsd/tests/*.cpp")
|
|
|
|
ADD_OSQUERY_TABLE_TEST(${OSQUERY_FREEBSD_TABLES_TESTS})
|
2014-09-05 14:54:41 +00:00
|
|
|
else()
|
2015-04-09 04:28:24 +00:00
|
|
|
file(GLOB OSQUERY_LINUX_TABLES "*/linux/*.cpp")
|
2015-02-03 05:21:36 +00:00
|
|
|
ADD_OSQUERY_LIBRARY(FALSE osquery_tables_linux
|
2015-04-09 04:28:24 +00:00
|
|
|
${OSQUERY_LINUX_TABLES}
|
2014-09-05 14:54:41 +00:00
|
|
|
)
|
2014-10-29 05:59:25 +00:00
|
|
|
|
2015-04-27 09:12:58 +00:00
|
|
|
file(GLOB OSQUERY_LINUX_TABLES_TESTS "*/linux/tests/*.cpp")
|
|
|
|
ADD_OSQUERY_TABLE_TEST(${OSQUERY_LINUX_TABLES_TESTS})
|
|
|
|
|
2015-05-10 18:42:30 +00:00
|
|
|
if(CENTOS OR RHEL OR AMAZON)
|
2014-12-31 17:33:19 +00:00
|
|
|
# CentOS specific tables
|
2015-04-09 04:28:24 +00:00
|
|
|
file(GLOB OSQUERY_REDHAT_TABLES "*/centos/*.cpp")
|
2015-02-03 05:21:36 +00:00
|
|
|
ADD_OSQUERY_LIBRARY(FALSE osquery_tables_redhat
|
2015-04-09 04:28:24 +00:00
|
|
|
${OSQUERY_REDHAT_TABLES}
|
2014-12-31 17:33:19 +00:00
|
|
|
)
|
2014-12-30 22:24:49 +00:00
|
|
|
|
2015-05-13 07:31:02 +00:00
|
|
|
ADD_OSQUERY_LINK(FALSE "rpm rpmio")
|
2014-12-31 17:33:19 +00:00
|
|
|
elseif(UBUNTU)
|
2014-12-31 18:06:54 +00:00
|
|
|
# Ubuntu specific tables
|
2015-04-09 04:28:24 +00:00
|
|
|
file(GLOB OSQUERY_UBUNTU_TABLES "*/ubuntu/*.cpp")
|
2015-02-03 05:21:36 +00:00
|
|
|
ADD_OSQUERY_LIBRARY(FALSE osquery_tables_ubuntu
|
2015-04-09 04:28:24 +00:00
|
|
|
${OSQUERY_UBUNTU_TABLES}
|
2014-12-31 18:06:54 +00:00
|
|
|
)
|
|
|
|
|
2015-05-13 07:31:02 +00:00
|
|
|
ADD_OSQUERY_LINK(FALSE "apt-pkg dpkg")
|
2014-12-23 19:39:03 +00:00
|
|
|
endif()
|
|
|
|
|
2015-02-03 05:21:36 +00:00
|
|
|
ADD_OSQUERY_LINK(FALSE "blkid")
|
2015-05-13 07:31:02 +00:00
|
|
|
ADD_OSQUERY_LINK(FALSE "cryptsetup libdevmapper.so libgcrypt.so")
|
2015-02-03 05:21:36 +00:00
|
|
|
ADD_OSQUERY_LINK(FALSE "udev")
|
|
|
|
ADD_OSQUERY_LINK(FALSE "uuid")
|
2015-04-28 00:41:58 +00:00
|
|
|
ADD_OSQUERY_LINK(FALSE "ip4tc")
|
2014-08-30 10:17:52 +00:00
|
|
|
endif()
|
|
|
|
|
2015-05-07 04:58:23 +00:00
|
|
|
file(GLOB OSQUERY_CROSS_TABLES "[!ue]*/*.cpp")
|
|
|
|
ADD_OSQUERY_LIBRARY(FALSE osquery_tables
|
|
|
|
${OSQUERY_CROSS_TABLES}
|
|
|
|
)
|
2014-08-17 08:44:22 +00:00
|
|
|
|
2015-04-27 09:12:58 +00:00
|
|
|
file(GLOB OSQUERY_CROSS_TABLES_TESTS "[!u]*/tests/*.cpp")
|
|
|
|
ADD_OSQUERY_TABLE_TEST(${OSQUERY_CROSS_TABLES_TESTS})
|
|
|
|
|
2015-04-09 04:28:24 +00:00
|
|
|
file(GLOB OSQUERY_UTILITY_TABLES "utility/*.cpp")
|
|
|
|
ADD_OSQUERY_LIBRARY(TRUE osquery_tables_utility
|
|
|
|
${OSQUERY_UTILITY_TABLES}
|
2014-12-24 04:07:12 +00:00
|
|
|
)
|
|
|
|
|
2015-05-07 04:58:23 +00:00
|
|
|
if(NOT FREEBSD)
|
|
|
|
file(GLOB OSQUERY_UTILS "utils/*.cpp")
|
|
|
|
ADD_OSQUERY_LIBRARY(FALSE osquery_utils
|
|
|
|
${OSQUERY_UTILS}
|
|
|
|
)
|
2015-04-17 20:03:43 +00:00
|
|
|
|
2015-05-07 04:58:23 +00:00
|
|
|
file(GLOB OSQUERY_UTILS_TESTS "utils/tests/*.cpp")
|
|
|
|
ADD_OSQUERY_TEST(FALSE ${OSQUERY_UTILS_TESTS})
|
|
|
|
endif()
|