mirror of
https://github.com/vgough/encfs.git
synced 2024-11-24 17:03:13 +01:00
Replace "linux" define with more-standard "__linux__"
The "linux" define is not available with "g++ -std=c++11", which resulted in bug https://github.com/vgough/encfs/issues/398 . Available defines for gcc 7.1.1, g++ 7.1.7, clang 4.0.0: $ g++ -dM -E -x c++ /dev/null | grep linux $ g++ -dM -E -x c++ -std=c++11 /dev/null | grep linux $ echo "" | gcc -E -dM -c - | grep linux $ echo "" | clang -E - -dM | grep linux
This commit is contained in:
parent
85a2d74d68
commit
f5d37d2c65
@ -31,7 +31,7 @@
|
|||||||
#include "FileNode.h"
|
#include "FileNode.h"
|
||||||
#include "FileUtils.h"
|
#include "FileUtils.h"
|
||||||
#include "NameIO.h"
|
#include "NameIO.h"
|
||||||
#ifdef linux
|
#ifdef __linux__
|
||||||
#include <sys/fsuid.h>
|
#include <sys/fsuid.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
@ -24,7 +24,7 @@
|
|||||||
#include <sys/stat.h>
|
#include <sys/stat.h>
|
||||||
#include <sys/types.h>
|
#include <sys/types.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
#ifdef linux
|
#ifdef __linux__
|
||||||
#include <sys/fsuid.h>
|
#include <sys/fsuid.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
@ -19,7 +19,7 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
// defines needed for RedHat 7.3...
|
// defines needed for RedHat 7.3...
|
||||||
#ifdef linux
|
#ifdef __linux__
|
||||||
#define _XOPEN_SOURCE 500 // make sure pwrite() is pulled in
|
#define _XOPEN_SOURCE 500 // make sure pwrite() is pulled in
|
||||||
#endif
|
#endif
|
||||||
#define _BSD_SOURCE // pick up setenv on RH7.3
|
#define _BSD_SOURCE // pick up setenv on RH7.3
|
||||||
|
@ -18,7 +18,7 @@
|
|||||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#ifdef linux
|
#ifdef __linux__
|
||||||
#define _XOPEN_SOURCE 500 // pick up pread , pwrite
|
#define _XOPEN_SOURCE 500 // pick up pread , pwrite
|
||||||
#endif
|
#endif
|
||||||
#include "easylogging++.h"
|
#include "easylogging++.h"
|
||||||
|
@ -32,7 +32,7 @@
|
|||||||
#include <sys/time.h>
|
#include <sys/time.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
#include <utime.h>
|
#include <utime.h>
|
||||||
#ifdef linux
|
#ifdef __linux__
|
||||||
#include <sys/fsuid.h>
|
#include <sys/fsuid.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
@ -34,7 +34,7 @@ namespace encfs {
|
|||||||
#define HAVE_XATTR
|
#define HAVE_XATTR
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifndef linux
|
#ifndef __linux__
|
||||||
#include <cerrno>
|
#include <cerrno>
|
||||||
|
|
||||||
static __inline int setfsuid(uid_t uid) {
|
static __inline int setfsuid(uid_t uid) {
|
||||||
|
Loading…
Reference in New Issue
Block a user