diff options
author | Baptiste Daroussin <bapt@FreeBSD.org> | 2011-04-27 11:23:33 +0000 |
---|---|---|
committer | Baptiste Daroussin <bapt@FreeBSD.org> | 2011-04-27 11:23:33 +0000 |
commit | 2ecfdbfa142af14ff4ed646d66f14e7e2eb169af (patch) | |
tree | 5f54c26547eefc48d11d6f4ac7edbeddb7eb214a /www/httpsqs/files | |
parent | 5f6923d97bb2de4cadde9f4db675cf6047b36c5c (diff) |
Notes
Diffstat (limited to 'www/httpsqs/files')
-rw-r--r-- | www/httpsqs/files/Makefile | 18 | ||||
-rw-r--r-- | www/httpsqs/files/patch-httpsqs.c | 19 |
2 files changed, 37 insertions, 0 deletions
diff --git a/www/httpsqs/files/Makefile b/www/httpsqs/files/Makefile new file mode 100644 index 000000000000..36c03389a073 --- /dev/null +++ b/www/httpsqs/files/Makefile @@ -0,0 +1,18 @@ +# $FreeBSD$ +# Makefile for httpsqs (pmake) + +tokyocabinet_CFLAGS!= pkg-config --cflags tokyocabinet +libevent_CFLAGS!= pkg-config --cflags libevent +tokyocabinet_LIBS!= pkg-config --libs tokyocabinet +libevent_LIBS!= pkg-config --libs libevent +CFLAGS+= ${tokyocabinet_CFLAGS} ${libevent_CFLAGS} +LIBS+= ${tokyocabinet_LIBS} ${libevent_LIBS} + +all: httpsqs + +httpsqs: httpsqs.o prename.o + ${CC} ${LDFLAGS} ${LIBS} -o ${.TARGET} ${.ALLSRC} +httpsqs.o: httpsqs.c +prename.o: prename.c + +install: httpsqs diff --git a/www/httpsqs/files/patch-httpsqs.c b/www/httpsqs/files/patch-httpsqs.c new file mode 100644 index 000000000000..58fd2ef8dc2c --- /dev/null +++ b/www/httpsqs/files/patch-httpsqs.c @@ -0,0 +1,19 @@ +--- httpsqs.c.orig 2011-04-14 00:46:09.000000000 -0500 ++++ httpsqs.c 2011-04-23 03:19:34.920926265 -0500 +@@ -30,6 +30,7 @@ This is free software, and you are welco + #include <signal.h> + #include <stdbool.h> + #include <pthread.h> ++#include <sys/wait.h> + + #include <err.h> + #include <event.h> +@@ -656,7 +657,7 @@ int main(int argc, char *argv[], char *e + char httpsqs_path_file[1024] = { 0 }; // httpsqs_path_file 为 httpsqs 程序的绝对路径 + struct evbuffer *httpsqs_prename_buf; /* 原命令行参数 */ + httpsqs_prename_buf = evbuffer_new(); +- readlink("/proc/self/exe", httpsqs_path_file, sizeof(httpsqs_path_file)); ++ //readlink("/proc/self/exe", httpsqs_path_file, sizeof(httpsqs_path_file)); + evbuffer_add_printf(httpsqs_prename_buf, "%s", httpsqs_path_file); + for (httpsqs_prename_num = 1; httpsqs_prename_num < argc; httpsqs_prename_num++) { + evbuffer_add_printf(httpsqs_prename_buf, " %s", argv[httpsqs_prename_num]); |