aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Makefile4
-rw-r--r--src/pipe.h1
-rw-r--r--src/tsar.c10
3 files changed, 8 insertions, 7 deletions
diff --git a/Makefile b/Makefile
index 79a4243..6fdd962 100644
--- a/Makefile
+++ b/Makefile
@@ -4,8 +4,8 @@ LDFLAGS+=-lX11 -lxcb
TSAR_OUT=tsarbar
-HEADERS=
-SRC=src/tsar.c
+HEADERS=src/pipe.h
+SRC=src/tsar.c src/pipe.c
.PHONY: default run clean
diff --git a/src/pipe.h b/src/pipe.h
index 798a4a1..3f81432 100644
--- a/src/pipe.h
+++ b/src/pipe.h
@@ -5,6 +5,7 @@
#define PIPE_PATH "/tmp/tsarc.pipe"
#define MAX_ARG_LEN 256
#define MAX_ARGS 4
+
void init_pipe();
void await_change();
void make_change(char[MAX_ARGS][MAX_ARG_LEN], int);
diff --git a/src/tsar.c b/src/tsar.c
index b4f9fb2..426ad35 100644
--- a/src/tsar.c
+++ b/src/tsar.c
@@ -1,15 +1,15 @@
+#include <stdarg.h>
+#include <stdbool.h>
#include <stdio.h>
#include <stdlib.h>
-#include <unistd.h>
-#include <stdbool.h>
-#include <stdarg.h>
#include <string.h>
+#include <unistd.h>
-#include "pipe.c"
-#include "pipe.h"
#include <xcb/xcb.h>
// #include <X11/Xft/Xft.h>
+#include "pipe.h"
+
xcb_connection_t* connection;
xcb_screen_t* screen;
xcb_window_t win;