summaryrefslogtreecommitdiffhomepage
path: root/project
diff options
context:
space:
mode:
authormidipix <writeonce@midipix.org>2015-09-24 23:49:09 -0400
committermidipix <writeonce@midipix.org>2015-09-26 11:05:32 -0400
commitfa897aef9891212c388a333d9ac5bb8ccf3f4cb9 (patch)
treea7b528e0e451833f96b2edaa5d5e9de973c28a01 /project
parent0da0f7bab3e248355dcbb185e86235e067b35413 (diff)
downloaddalist-fa897aef9891212c388a333d9ac5bb8ccf3f4cb9.tar.bz2
dalist-fa897aef9891212c388a333d9ac5bb8ccf3f4cb9.tar.xz
makefile replacement: step 2/2: use the midipix build template.
Diffstat (limited to 'project')
-rw-r--r--project/arch.mk0
-rw-r--r--project/common.mk6
-rw-r--r--project/defs.mk31
-rw-r--r--project/depends.mk0
-rw-r--r--project/extras.mk2
-rw-r--r--project/headers.mk9
-rw-r--r--project/overrides.mk0
-rw-r--r--project/tree.mk3
8 files changed, 51 insertions, 0 deletions
diff --git a/project/arch.mk b/project/arch.mk
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/project/arch.mk
diff --git a/project/common.mk b/project/common.mk
new file mode 100644
index 0000000..014d45f
--- /dev/null
+++ b/project/common.mk
@@ -0,0 +1,6 @@
+COMMON_SRCS = \
+ src/dalist.c \
+ src/dalist_debug.c \
+ src/dalist_lib_entry_point.c \
+ src/dalist_memfn.c \
+
diff --git a/project/defs.mk b/project/defs.mk
new file mode 100644
index 0000000..1f352be
--- /dev/null
+++ b/project/defs.mk
@@ -0,0 +1,31 @@
+SHARED_LIB_DEPS =
+SHARED_APP_DEPS =
+STATIC_APP_DEPS =
+
+COMMON_LOBJS = $(COMMON_SRCS:.c=.lo)
+COMMON_OBJS = $(COMMON_SRCS:.c=.o)
+
+ARCH_LOBJS = $(ARCH_SRCS:.c=.lo)
+ARCH_OBJS = $(ARCH_SRCS:.c=.o)
+
+SHARED_OBJS = $(COMMON_LOBJS) $(ARCH_LOBJS)
+STATIC_OBJS = $(COMMON_OBJS) $(ARCH_OBJS)
+
+SHARED_LIB = $(LIBDIR)/$(OS_LIB_PREFIX)$(PACKAGE)$(OS_LIB_SUFFIX)
+STATIC_LIB = $(LIBDIR)/$(OS_LIB_PREFIX)$(PACKAGE)$(OS_ARCHIVE_EXT)
+SHARED_IMPLIB = $(LIBDIR)/$(OS_LIB_PREFIX)$(PACKAGE)$(OS_IMPLIB_EXT)
+
+CFLAGS = $(CFLAGS_DEBUG) $(CFLAGS_CONFIG) $(CFLAGS_SYSROOT) \
+ $(CFLAGS_COMMON) $(CFLAGS_CMDLINE) $(CFLAGS_HOST) \
+ $(CFLAGS_PATH)
+
+CFLAGS_SHARED = $(CFLAGS) $(CFLAGS_PIC) $(CFLAGS_SHARED_ATTR)
+CFLAGS_STATIC = $(CFLAGS) $(CFLAGS_OBJ) $(CFLAGS_STATIC_ATTR)
+
+LDFLAGS_SHARED = $(LDFLAGS_DEBUG) $(LDFLAGS_CONFIG) $(LDFLAGS_SYSROOT) \
+ $(LDFLAGS_COMMON) $(LDFLAGS_CMDLINE) $(LDFLAGS_HOST) \
+ $(LDFLAGS_PATH) $(SHARED_LIB_DEPS) $(LDFLAGS_LAST)
+
+LDFLAGS_STATIC = $(LDFLAGS_DEBUG) $(LDFLAGS_CONFIG) $(LDFLAGS_SYSROOT) \
+ $(LDFLAGS_COMMON) $(LDFLAGS_CMDLINE) $(LDFLAGS_HOST) \
+ $(LDFLAGS_PATH) $(STATIC_APP_DEPS) $(LDFLAGS_LAST)
diff --git a/project/depends.mk b/project/depends.mk
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/project/depends.mk
diff --git a/project/extras.mk b/project/extras.mk
new file mode 100644
index 0000000..bece2fc
--- /dev/null
+++ b/project/extras.mk
@@ -0,0 +1,2 @@
+CFLAGS_SHARED_ATTR += -DDALIST_BUILD
+CFLAGS_STATIC_ATTR += -DDALIST_STATIC
diff --git a/project/headers.mk b/project/headers.mk
new file mode 100644
index 0000000..2131cc7
--- /dev/null
+++ b/project/headers.mk
@@ -0,0 +1,9 @@
+API_HEADERS = \
+ $(PROJECT_DIR)/include/$(PACKAGE)/dalist.h \
+ $(PROJECT_DIR)/include/$(PACKAGE)/dalist_api.h \
+ $(PROJECT_DIR)/include/$(PACKAGE)/dalist_env.h
+
+INTERNAL_HEADERS = \
+ $(PROJECT_DIR)/src/$(PACKAGE)_impl.h
+
+ALL_HEADERS = $(API_HEADERS) $(INTERNAL_HEADERS)
diff --git a/project/overrides.mk b/project/overrides.mk
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/project/overrides.mk
diff --git a/project/tree.mk b/project/tree.mk
new file mode 100644
index 0000000..20f0861
--- /dev/null
+++ b/project/tree.mk
@@ -0,0 +1,3 @@
+tree.tag:
+ mkdir -p src
+ touch tree.tag