From dcf59305ec6c919b44238a7c42ed8a2b239f7a83 Mon Sep 17 00:00:00 2001 From: Cerem Cem ASLAN Date: Mon, 7 Dec 2020 00:48:27 +0300 Subject: [PATCH] Changed samples output directory form /tmp to ./tmp. It's considered a bad practice to run any executable from within /tmp directory. See https://serverfault.com/q/72356/261445 --- .gitignore | 1 + Makefile | 7 ++++--- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/.gitignore b/.gitignore index d2bc6286..e9bc9132 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,4 @@ *.pyc .*.swo .*.swp +tmp diff --git a/Makefile b/Makefile index f110b150..8ab3515b 100644 --- a/Makefile +++ b/Makefile @@ -35,17 +35,18 @@ samples: echo "#####################################"; \ echo -n "Press to start..."; \ read _; \ + mkdir -p ./tmp; \ echo ceu --pre --pre-input=$$i --pre-args=\"-I./include\" \ --ceu --ceu-features-os=true --ceu-features-lua=true --ceu-features-thread=true --ceu-features-dynamic=true --ceu-err-unused=pass \ --env --env-types=env/types.h --env-threads=env/threads.h --env-main=env/main.c \ --cc --cc-args=\"-llua5.3 -lpthread\" \ - --cc-output=/tmp/$$(basename $$i .ceu); \ + --cc-output=./tmp/$$(basename $$i .ceu); \ ceu --pre --pre-input=$$i --pre-args=\"-I./include\" \ --ceu --ceu-features-async=true --ceu-features-os=true --ceu-features-lua=true --ceu-features-thread=true --ceu-features-dynamic=true --ceu-err-unused=pass \ --env --env-types=env/types.h --env-threads=env/threads.h --env-main=env/main.c \ --cc --cc-args="-llua5.3 -lpthread" \ - --cc-output=/tmp/$$(basename $$i .ceu); \ - /tmp/$$(basename $$i .ceu); \ + --cc-output=./tmp/$$(basename $$i .ceu); \ + ./tmp/$$(basename $$i .ceu); \ echo ">>> OK"; \ echo; \ echo; \