summaryrefslogtreecommitdiff
path: root/Mac/OSX/Tools/pythonw.c
blob: e70a76f846f5ce84659b4f2306ee544658f8d8da (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
/*
 * This wrapper program executes a python executable hidden inside an
 * application bundle inside the Python framework. This is needed to run
 * GUI code: some GUI API's don't work unless the program is inside an
 * application bundle.
 */
#include <unistd.h>
#include <err.h>

static char Python[] = PYTHONWEXECUTABLE;

int main(int argc, char **argv) {
	argv[0] = Python;
	execv(Python, argv);
	err(1, "execv: %s", Python);
	/* NOTREACHED */
}