#include "cli.hpp"
#include "os_path.hpp"
+#include "os_process.hpp"
#include "trace_tools.hpp"
static const char *synopsis = "Identify differences between two traces.";
#ifdef _WIN32
std::cerr << "The 'apitrace diff' command is not yet supported on this O/S.\n";
+ return 1;
#else
- execv(command.str(), args);
-#endif
-
- std::cerr << "Error: Failed to execute " << argv[0] << "\n";
+ os::Path apitrace = os::getProcessName();
+ setenv("APITRACE", apitrace.str(), 1);
- return 1;
+ return os::execute(args);
+#endif
}
const Command diff_command = {