Update ticproc to new build system

This commit is contained in:
Andrew Pamment 2017-03-19 14:38:01 +10:00
parent cb09b8a593
commit 7f5e567a2b
10 changed files with 65 additions and 19 deletions

View File

@ -6,7 +6,7 @@ ZMODEM = deps/Xmodem/libzmodem.a
LUA = deps/lua/liblua.a
ODOORS = deps/odoors/libs-`uname -s`/libODoors.a
all: magicka magimail magiedit
all: magicka magimail magiedit ticproc
${LUA}:
cd deps/lua && $(MAKE) -f Makefile freebsd MAKEFLAGS=
@ -33,6 +33,9 @@ magimail: $(JAMLIB)
magiedit: $(ODOORS)
cd utils/magiedit && $(MAKE)
ticproc:
cd utils/ticproc && $(MAKE)
.PHONY: clean
clean:
@ -43,3 +46,4 @@ clean:
cd utils/magimail && $(MAKE) cleanfreebsd
cd utils/magiedit && $(MAKE) clean
cd deps/odoors/ && rm -rf libs-`uname -s` objs-`uname -s` exe-`uname -s`
cd utils/ticproc && $(MAKE) clean

View File

@ -8,7 +8,7 @@ B64 = deps/libb64-1.2/src/libb64.a
MICROHTTPD=-lmicrohttpd
ODOORS = deps/odoors/libs-`uname -s`/libODoors.a
all: magicka magimail magiedit
all: magicka magimail magiedit ticproc
${LUA}:
cd deps/lua && $(MAKE) -f Makefile freebsd MAKEFLAGS=
@ -38,6 +38,9 @@ magimail: $(JAMLIB)
magiedit: $(ODOORS)
cd utils/magiedit && $(MAKE)
ticproc:
cd utils/ticproc && $(MAKE)
.PHONY: clean
clean:
@ -49,3 +52,4 @@ clean:
cd utils/magimail && $(MAKE) cleanfreebsd
cd utils/magiedit && $(MAKE) clean
cd deps/odoors/ && rm -rf libs-`uname -s` objs-`uname -s` exe-`uname -s`
cd utils/ticproc && $(MAKE) clean

View File

@ -6,7 +6,7 @@ ZMODEM = deps/Xmodem/libzmodem.a
LUA = deps/lua/liblua.a
ODOORS = deps/odoors/libs-`uname -s`/libODoors.a
all: magicka magimail magiedit
all: magicka magimail magiedit ticproc
${LUA}:
cd deps/lua && $(MAKE) -f Makefile linux MAKEFLAGS=
@ -33,6 +33,9 @@ magimail: $(JAMLIB)
magiedit: $(ODOORS)
cd utils/magiedit && $(MAKE)
ticproc:
cd utils/ticproc && $(MAKE)
.PHONY: clean
clean:
@ -43,3 +46,4 @@ clean:
cd utils/magimail && $(MAKE) cleanlinux
cd utils/magiedit && $(MAKE) clean
cd deps/odoors/ && rm -rf libs-`uname -s` objs-`uname -s` exe-`uname -s`
cd utils/ticproc && $(MAKE) clean

View File

@ -8,7 +8,7 @@ B64 = deps/libb64-1.2/src/libb64.a
MICROHTTPD=-lmicrohttpd
ODOORS = deps/odoors/libs-`uname -s`/libODoors.a
all: magicka magimail magiedit
all: magicka magimail magiedit ticproc
${LUA}:
cd deps/lua && $(MAKE) -f Makefile linux MAKEFLAGS=
@ -38,6 +38,9 @@ magimail: $(JAMLIB)
magiedit: $(ODOORS)
cd utils/magiedit && $(MAKE)
ticproc:
cd utils/ticproc && $(MAKE)
.PHONY: clean
clean:
@ -49,3 +52,4 @@ clean:
cd utils/magimail && $(MAKE) cleanlinux
cd utils/magiedit && $(MAKE) clean
cd deps/odoors/ && rm -rf libs-`uname -s` objs-`uname -s` exe-`uname -s`
cd utils/ticproc && $(MAKE) clean

View File

@ -6,7 +6,7 @@ ZMODEM = deps/Xmodem/libzmodem.a
LUA = deps/lua/liblua.a
ODOORS = deps/odoors/libs-`uname -s`/libODoors.a
all: magicka magimail magiedit
all: magicka magimail magiedit ticproc
${LUA}:
cd deps/lua && $(MAKE) -f Makefile bsd MAKEFLAGS=
@ -33,6 +33,9 @@ magiedit: $(ODOORS)
magimail: $(JAMLIB)
cd utils/magimail && $(MAKE) freebsd
ticproc:
cd utils/ticproc && $(MAKE)
.PHONY: clean
clean:
@ -43,4 +46,4 @@ clean:
cd utils/magimail && $(MAKE) cleanfreebsd
cd utils/magiedit && $(MAKE) clean
cd deps/odoors/ && rm -rf libs-`uname -s` objs-`uname -s` exe-`uname -s`
cd utils/ticproc && $(MAKE) clean

View File

@ -8,7 +8,7 @@ B64 = deps/libb64-1.2/src/libb64.a
MICROHTTPD=-lmicrohttpd
ODOORS = deps/odoors/libs-`uname -s`/libODoors.a
all: magicka magimail magiedit
all: magicka magimail magiedit ticproc
${LUA}:
cd deps/lua && $(MAKE) -f Makefile bsd MAKEFLAGS=
@ -38,6 +38,9 @@ magiedit: $(ODOORS)
magimail: $(JAMLIB)
cd utils/magimail && $(MAKE) freebsd
ticproc:
cd utils/ticproc && $(MAKE)
.PHONY: clean
clean:
@ -49,3 +52,4 @@ clean:
cd utils/magimail && $(MAKE) cleanfreebsd
cd utils/magiedit && $(MAKE) clean
cd deps/odoors/ && rm -rf libs-`uname -s` objs-`uname -s` exe-`uname -s`
cd utils/ticproc && $(MAKE) clean

View File

@ -8,7 +8,7 @@ ODOORS = deps/odoors/libs-`uname -s`/libODoors.a
OBJ = inih/ini.o bbs.o main.o users.o main_menu.o mail_menu.o doors.o bbs_list.o chat_system.o email.o files.o settings.o lua_glue.o strings.o bluewave.o hashmap/hashmap.o
all: magicka magimail magiedit
all: magicka magimail magiedit ticproc
${LUA}:
cd deps/lua && $(MAKE) -f Makefile macosx MAKEFLAGS=
@ -34,6 +34,9 @@ magimail: $(JAMLIB)
magiedit: $(ODOORS)
cd utils/magiedit && $(MAKE)
ticproc:
cd utils/ticproc && $(MAKE)
.PHONY: clean
clean:
@ -44,3 +47,4 @@ clean:
cd utils/magimail && $(MAKE) cleanlinux
cd utils/magiedit && $(MAKE) clean
cd deps/odoors/ && rm -rf libs-`uname -s` objs-`uname -s` exe-`uname -s`
cd utils/ticproc && $(MAKE) clean

View File

@ -8,7 +8,7 @@ B64 = deps/libb64-1.2/src/libb64.a
MICROHTTPD=-lmicrohttpd
ODOORS = deps/odoors/libs-`uname -s`/libODoors.a
all: magicka magimail magiedit
all: magicka magimail magiedit ticproc
${LUA}:
cd deps/lua && $(MAKE) -f Makefile macosx MAKEFLAGS=
@ -38,6 +38,9 @@ magimail: $(JAMLIB)
magiedit: $(ODOORS)
cd utils/magiedit && $(MAKE)
ticproc:
cd utils/ticproc && $(MAKE)
.PHONY: clean
clean:
@ -48,3 +51,4 @@ clean:
cd utils/magimail && $(MAKE) cleanlinux
cd utils/magiedit && $(MAKE) clean
cd deps/odoors/ && rm -rf libs-`uname -s` objs-`uname -s` exe-`uname -s`
cd utils/ticproc && $(MAKE) clean

View File

@ -1,14 +1,29 @@
CC=cc
CFLAGS=-I/usr/local/include
OS := $(shell uname -s)
ifeq ($(OS), FreeBSD)
CC=cc
CFLAGS=-I/usr/local/include
LDFLAGS=-L/usr/local/lib
else
ifeq ($(OS), NetBSD)
CC=cc
CFLAGS=-I/usr/pkg/include
LDFLAGS=-L/usr/pkg/lib
else
CC=gcc
CFLAGS=
LDFLAGS=
endif
DEPS = ticproc.c
OBJ = ticproc.o ../../inih/ini.o crc32.o
OBJ = ticproc.o ../../deps/inih/ini.o crc32.o
%.o: %.c $(DEPS)
$(CC) -c -o $@ $< $(CFLAGS)
ticproc: $(OBJ)
$(CC) -o ticproc -o $@ $^ $(CFLAGS) -L/usr/local/lib -lsqlite3
$(CC) -o ticproc -o $@ $^ $(CFLAGS) $(LDFLAGS) -lsqlite3
.PHONY: clean

View File

@ -6,7 +6,7 @@
#include <dirent.h>
#include <libgen.h>
#include <ctype.h>
#include "../../inih/ini.h"
#include "../../deps/inih/ini.h"
#include "ticproc.h"
#include "crc32.h"