2020-03-01 05:58:02 +00:00
|
|
|
project(aaruremote-linux C)
|
2019-10-20 19:23:34 +01:00
|
|
|
|
|
|
|
|
if (NOT "${CMAKE_SYSTEM}" MATCHES "Linux")
|
|
|
|
|
return()
|
|
|
|
|
endif ()
|
|
|
|
|
|
2019-10-20 21:50:25 +01:00
|
|
|
set(PLATFORM_SOURCES list_devices.c linux.h device.c scsi.c usb.c ieee1394.c pcmcia.c ata.c sdhci.c ../unix/hello.c
|
2019-10-26 22:22:04 +01:00
|
|
|
../unix/network.c ../unix/unix.c mmc/ioctl.h ../unix/unix.h)
|
2019-10-20 19:23:34 +01:00
|
|
|
CHECK_LIBRARY_EXISTS("udev" udev_new "" HAS_UDEV)
|
|
|
|
|
CHECK_INCLUDE_FILES("linux/mmc/ioctl.h" HAVE_MMC_IOCTL_H)
|
|
|
|
|
|
2020-03-01 05:58:02 +00:00
|
|
|
add_executable(aaruremote ${PLATFORM_SOURCES})
|
2019-10-20 19:23:34 +01:00
|
|
|
|
|
|
|
|
if (HAS_UDEV)
|
2020-03-01 05:58:02 +00:00
|
|
|
target_link_libraries(aaruremote udev)
|
2019-10-20 19:23:34 +01:00
|
|
|
add_definitions(-DHAS_UDEV)
|
|
|
|
|
endif ()
|
|
|
|
|
|
|
|
|
|
if (HAVE_MMC_IOCTL_H)
|
|
|
|
|
add_definitions(-DHAS_UAPI_MMC)
|
|
|
|
|
endif ()
|
|
|
|
|
|
2020-03-01 05:58:02 +00:00
|
|
|
target_link_libraries(aaruremote aaruremotecore)
|