I keep running into an error when I want to compile code written in C++ using Python script to run "make" in x directory. Compiling the code takes about few seconds so I am using time module to have the script sleep for 60 seconds to finish compiling the code.
Here is the code:
from subprocess import call
from time import sleep
def make_ut_adsmain():
os.system("make ../../ads/main/unittest")
# call(["ls", "-l"])
sleep(60)
make_ut_adsmain()
# Run other functions when compiled...
Error
make: *** No rule to make target `../../ads/main/unittest'. Stop.
The code never really compiles because the rest of the code depends on the log file which never gets created. Please guide me.