diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/firejail/Makefile.in | 7 | ||||
-rw-r--r-- | src/firejail/bandwidth.c | 10 | ||||
-rw-r--r-- | src/firejail/fs_trace.c | 2 | ||||
-rw-r--r-- | src/firejail/output.c | 2 |
4 files changed, 12 insertions, 9 deletions
diff --git a/src/firejail/Makefile.in b/src/firejail/Makefile.in index f2419c0cd..255784ac7 100644 --- a/src/firejail/Makefile.in +++ b/src/firejail/Makefile.in | |||
@@ -1,6 +1,9 @@ | |||
1 | all: firejail | 1 | all: firejail |
2 | 2 | ||
3 | PREFIX=@prefix@ | 3 | prefix=@prefix@ |
4 | exec_prefix=@exec_prefix@ | ||
5 | libdir=@libdir@ | ||
6 | |||
4 | VERSION=@PACKAGE_VERSION@ | 7 | VERSION=@PACKAGE_VERSION@ |
5 | NAME=@PACKAGE_NAME@ | 8 | NAME=@PACKAGE_NAME@ |
6 | HAVE_SECCOMP_H=@HAVE_SECCOMP_H@ | 9 | HAVE_SECCOMP_H=@HAVE_SECCOMP_H@ |
@@ -13,7 +16,7 @@ H_FILE_LIST = $(wildcard *.[h]) | |||
13 | C_FILE_LIST = $(wildcard *.c) | 16 | C_FILE_LIST = $(wildcard *.c) |
14 | OBJS = $(C_FILE_LIST:.c=.o) | 17 | OBJS = $(C_FILE_LIST:.c=.o) |
15 | BINOBJS = $(foreach file, $(OBJS), $file) | 18 | BINOBJS = $(foreach file, $(OBJS), $file) |
16 | CFLAGS += -ggdb $(HAVE_FATAL_WARNINGS) -O2 -DVERSION='"$(VERSION)"' -DPREFIX='"$(PREFIX)"' $(HAVE_SECCOMP) $(HAVE_SECCOMP_H) $(HAVE_CHROOT) $(HAVE_BIND) -fstack-protector-all -D_FORTIFY_SOURCE=2 -fPIE -pie -Wformat -Wformat-security | 19 | CFLAGS += -ggdb $(HAVE_FATAL_WARNINGS) -O2 -DVERSION='"$(VERSION)"' -DPREFIX='"$(prefix)"' -DLIBDIR='"$(libdir)"' $(HAVE_SECCOMP) $(HAVE_SECCOMP_H) $(HAVE_CHROOT) $(HAVE_BIND) -fstack-protector-all -D_FORTIFY_SOURCE=2 -fPIE -pie -Wformat -Wformat-security |
17 | LDFLAGS += -pie -Wl,-z,relro -Wl,-z,now -lpthread | 20 | LDFLAGS += -pie -Wl,-z,relro -Wl,-z,now -lpthread |
18 | 21 | ||
19 | %.o : %.c $(H_FILE_LIST) | 22 | %.o : %.c $(H_FILE_LIST) |
diff --git a/src/firejail/bandwidth.c b/src/firejail/bandwidth.c index d949c1965..c5bb77925 100644 --- a/src/firejail/bandwidth.c +++ b/src/firejail/bandwidth.c | |||
@@ -447,18 +447,18 @@ void bandwidth_pid(pid_t pid, const char *command, const char *dev, int down, in | |||
447 | cmd = NULL; | 447 | cmd = NULL; |
448 | if (devname) { | 448 | if (devname) { |
449 | if (strcmp(command, "set") == 0) { | 449 | if (strcmp(command, "set") == 0) { |
450 | if (asprintf(&cmd, "%s/lib/firejail/fshaper.sh --%s %s %d %d", | 450 | if (asprintf(&cmd, "%s/firejail/fshaper.sh --%s %s %d %d", |
451 | PREFIX, command, devname, down, up) == -1) | 451 | LIBDIR, command, devname, down, up) == -1) |
452 | errExit("asprintf"); | 452 | errExit("asprintf"); |
453 | } | 453 | } |
454 | else { | 454 | else { |
455 | if (asprintf(&cmd, "%s/lib/firejail/fshaper.sh --%s %s", | 455 | if (asprintf(&cmd, "%s/firejail/fshaper.sh --%s %s", |
456 | PREFIX, command, devname) == -1) | 456 | LIBDIR, command, devname) == -1) |
457 | errExit("asprintf"); | 457 | errExit("asprintf"); |
458 | } | 458 | } |
459 | } | 459 | } |
460 | else { | 460 | else { |
461 | if (asprintf(&cmd, "%s/lib/firejail/fshaper.sh --%s", PREFIX, command) == -1) | 461 | if (asprintf(&cmd, "%s/firejail/fshaper.sh --%s", LIBDIR, command) == -1) |
462 | errExit("asprintf"); | 462 | errExit("asprintf"); |
463 | } | 463 | } |
464 | assert(cmd); | 464 | assert(cmd); |
diff --git a/src/firejail/fs_trace.c b/src/firejail/fs_trace.c index 23ba113e0..6058bf3c4 100644 --- a/src/firejail/fs_trace.c +++ b/src/firejail/fs_trace.c | |||
@@ -58,7 +58,7 @@ void fs_trace(void) { | |||
58 | FILE *fp = fopen(preload, "w"); | 58 | FILE *fp = fopen(preload, "w"); |
59 | if (!fp) | 59 | if (!fp) |
60 | errExit("fopen"); | 60 | errExit("fopen"); |
61 | fprintf(fp, "%s/lib/firejail/libtrace.so\n", PREFIX); | 61 | fprintf(fp, "%s/firejail/libtrace.so\n", LIBDIR); |
62 | fclose(fp); | 62 | fclose(fp); |
63 | if (chown(preload, 0, 0) < 0) | 63 | if (chown(preload, 0, 0) < 0) |
64 | errExit("chown"); | 64 | errExit("chown"); |
diff --git a/src/firejail/output.c b/src/firejail/output.c index c2ab9f157..b12551d60 100644 --- a/src/firejail/output.c +++ b/src/firejail/output.c | |||
@@ -88,7 +88,7 @@ void check_output(int argc, char **argv) { | |||
88 | continue; | 88 | continue; |
89 | ptr += sprintf(ptr, "%s ", argv[i]); | 89 | ptr += sprintf(ptr, "%s ", argv[i]); |
90 | } | 90 | } |
91 | sprintf(ptr, "| %s/lib/firejail/ftee %s", PREFIX, outfile); | 91 | sprintf(ptr, "| %s/firejail/ftee %s", LIBDIR, outfile); |
92 | 92 | ||
93 | // run command | 93 | // run command |
94 | char *a[4]; | 94 | char *a[4]; |