diff options
Diffstat (limited to 'pow')
-rw-r--r-- | pow/Makefile | 6 | ||||
-rw-r--r-- | pow/pywrap/Makefile.in | 14 | ||||
-rw-r--r-- | pow/pywrap/python.c | 6 |
3 files changed, 25 insertions, 1 deletions
diff --git a/pow/Makefile b/pow/Makefile index 6b58d9da..df1ea9fb 100644 --- a/pow/Makefile +++ b/pow/Makefile @@ -12,15 +12,19 @@ SOURCES = POW-${VERSION}/lib/__init__.py \ POW-${VERSION}/dumpasn1.cfg \ POW-${VERSION}/POW.c -all: ${STAMP} +all: ${STAMP} pywrap/python ${STAMP}: ${SOURCES} cd POW-${VERSION}; python setup.py build ln -sf POW-${VERSION}/build/lib.* buildlib touch $@ +pywrap/python: + cd pywrap; ${MAKE} python + clean: rm -rf POW-${VERSION}/build buildlib + cd pywrap; ${MAKE} $@ install: @echo Not attempting to install modified POW, if you want that, do it yourself diff --git a/pow/pywrap/Makefile.in b/pow/pywrap/Makefile.in new file mode 100644 index 00000000..8370451a --- /dev/null +++ b/pow/pywrap/Makefile.in @@ -0,0 +1,14 @@ +OPENSSL_BUILD_DIRECTORY = @abs_top_builddir@/openssl/openssl + +CC=gcc +CFLAGS=`python-config --cflags` +LDFLAGS=-Wl,-rpath,$(OPENSSL_BUILD_DIRECTORY) -L$(OPENSSL_BUILD_DIRECTORY) +LIBS=-lcrypto -lssl `python-config --libs` + +all: python + +python: python.o + $(CC) $(LDFLAGS) -o $@ $< $(LIBS) + +clean: + rm -f *.o python diff --git a/pow/pywrap/python.c b/pow/pywrap/python.c new file mode 100644 index 00000000..10638721 --- /dev/null +++ b/pow/pywrap/python.c @@ -0,0 +1,6 @@ +#include <Python.h> + +int main(int argc, char **argv) +{ + return Py_Main(argc, argv); +} |