parent
7e249ef264
commit
b57c21da92
11 changed files with 43 additions and 30 deletions
17
.gitignore
vendored
17
.gitignore
vendored
|
@ -1,9 +1,20 @@
|
|||
.DS_Store
|
||||
.idea
|
||||
*.log
|
||||
*~
|
||||
tmp/
|
||||
|
||||
/.ccls-cache/
|
||||
*.in
|
||||
*.m4
|
||||
/autom4te.cache/
|
||||
/build-aux/
|
||||
/config.h
|
||||
*.status
|
||||
/configure
|
||||
.deps/
|
||||
Makefile
|
||||
*.o
|
||||
build/
|
||||
.ccls-cache
|
||||
.cache
|
||||
/src/main
|
||||
/stamp-h1
|
||||
/*.gz
|
||||
|
|
27
Makefile
27
Makefile
|
@ -1,27 +0,0 @@
|
|||
CC=clang
|
||||
SRCDIR=src
|
||||
BUILDDIR=build
|
||||
TARGET=$(BUILDDIR)/main
|
||||
|
||||
INCLUDE_PATHS=-Iinclude
|
||||
LDFLAGS=-lcurses
|
||||
|
||||
SRCS=$(wildcard $(SRCDIR)/*.c)
|
||||
OBJS=$(patsubst $(SRCDIR)/%.c,$(BUILDDIR)/%.o,$(SRCS))
|
||||
|
||||
all: $(TARGET)
|
||||
|
||||
$(BUILDDIR)/%.o: $(SRCDIR)/%.c
|
||||
mkdir -p $(BUILDDIR)
|
||||
$(CC) -c $(CFLAGS) $(INCLUDE_PATHS) $^ -o $@
|
||||
|
||||
$(BUILDDIR)/main.o: main.c
|
||||
mkdir -p $(BUILDDIR)
|
||||
$(CC) -c $(CFLAGS) $(INCLUDE_PATHS) $^ -o $@
|
||||
|
||||
$(TARGET): $(OBJS) $(BUILDDIR)/main.o
|
||||
mkdir -p $(BUILDDIR)
|
||||
$(CC) -o $@ $(LDFLAGS) $^
|
||||
|
||||
clean:
|
||||
rm -rf $(BUILDDIR)
|
1
Makefile.am
Normal file
1
Makefile.am
Normal file
|
@ -0,0 +1 @@
|
|||
SUBDIRS = src
|
15
configure.ac
Normal file
15
configure.ac
Normal file
|
@ -0,0 +1,15 @@
|
|||
AC_PREREQ([2.65])
|
||||
AC_INIT([roguelike], [0.1], [jacob.a.s.janzen@gmail.com])
|
||||
AC_CONFIG_SRCDIR([src/main.c])
|
||||
AC_CONFIG_AUX_DIR([build-aux])
|
||||
|
||||
AC_PROG_CC
|
||||
AC_CHECK_LIB([curses], [initscr])
|
||||
AC_CHECK_HEADERS([curses.h])
|
||||
|
||||
AM_INIT_AUTOMAKE([foreign -Wall -Werror])
|
||||
|
||||
AC_CONFIG_HEADERS([config.h])
|
||||
AC_CONFIG_FILES([Makefile src/Makefile])
|
||||
|
||||
AC_OUTPUT
|
13
src/Makefile.am
Normal file
13
src/Makefile.am
Normal file
|
@ -0,0 +1,13 @@
|
|||
bin_PROGRAMS = main
|
||||
|
||||
main_SOURCES = \
|
||||
cavegen.c \
|
||||
cavegen.h \
|
||||
display.c \
|
||||
display.h \
|
||||
ht.c \
|
||||
ht.h \
|
||||
common.h \
|
||||
entity.h \
|
||||
main.c
|
||||
|
Loading…
Add table
Reference in a new issue