diff options
author | Johannes Schickel | 2016-03-15 14:23:56 +0100 |
---|---|---|
committer | Johannes Schickel | 2016-03-15 14:24:23 +0100 |
commit | 7725e00e9a10f5bb93ebad2c1befdc448e0d945c (patch) | |
tree | 9380283f244517a49236e9f10a95c17ef43329d6 /backends/audiocd/linux | |
parent | f75bc481415c0b3e56627aaa84c6151a62c789b5 (diff) | |
download | scummvm-rg350-7725e00e9a10f5bb93ebad2c1befdc448e0d945c.tar.gz scummvm-rg350-7725e00e9a10f5bb93ebad2c1befdc448e0d945c.tar.bz2 scummvm-rg350-7725e00e9a10f5bb93ebad2c1befdc448e0d945c.zip |
LINUX: Guard Linux audio CD code.
Diffstat (limited to 'backends/audiocd/linux')
-rw-r--r-- | backends/audiocd/linux/linux-audiocd.cpp | 19 | ||||
-rw-r--r-- | backends/audiocd/linux/linux-audiocd.h | 2 |
2 files changed, 15 insertions, 6 deletions
diff --git a/backends/audiocd/linux/linux-audiocd.cpp b/backends/audiocd/linux/linux-audiocd.cpp index a86860106a..a5838e1c5a 100644 --- a/backends/audiocd/linux/linux-audiocd.cpp +++ b/backends/audiocd/linux/linux-audiocd.cpp @@ -42,15 +42,13 @@ * */ -#include <errno.h> -#include <fcntl.h> -#include <unistd.h> -#include <linux/cdrom.h> -#include <sys/ioctl.h> -#include <sys/stat.h> +// Enable all forbidden symbols to allow us to include and use necessary APIs. +#define FORBIDDEN_SYMBOL_ALLOW_ALL #include "backends/audiocd/linux/linux-audiocd.h" +#ifdef USE_LINUXCD + #include "backends/audiocd/audiocd-stream.h" #include "backends/audiocd/default/default-audiocd.h" #include "common/array.h" @@ -58,6 +56,13 @@ #include "common/str.h" #include "common/debug.h" +#include <errno.h> +#include <fcntl.h> +#include <unistd.h> +#include <linux/cdrom.h> +#include <sys/ioctl.h> +#include <sys/stat.h> + enum { kLeadoutTrack = 0xAA }; @@ -460,3 +465,5 @@ bool LinuxAudioCDManager::hasDevice(const DeviceList &devices, dev_t device) { AudioCDManager *createLinuxAudioCDManager() { return new LinuxAudioCDManager(); } + +#endif // USE_LINUXCD diff --git a/backends/audiocd/linux/linux-audiocd.h b/backends/audiocd/linux/linux-audiocd.h index 69046e936a..09d6353991 100644 --- a/backends/audiocd/linux/linux-audiocd.h +++ b/backends/audiocd/linux/linux-audiocd.h @@ -45,6 +45,8 @@ #ifndef BACKENDS_AUDIOCD_LINUX_H #define BACKENDS_AUDIOCD_LINUX_H +#include "common/scummsys.h" + #ifdef USE_LINUXCD class AudioCDManager; |