Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

add a stub Makefile for BSD make

  • Loading branch information...
commit 66b5628807a601eb5c89f9ef79f8ad219a95f679 1 parent a3c5720
@yamt authored
Showing with 40 additions and 31 deletions.
  1. +33 −0 c_src/GNUmakefile
  2. +7 −31 c_src/Makefile
View
33 c_src/GNUmakefile
@@ -0,0 +1,33 @@
+LINUX=$(shell uname | grep -E "(Linux|NetBSD)" | wc -l | xargs echo)
+DEPS=../deps
+
+ifeq ($(LINUX),1)
+ZMQ_FLAGS=--with-pic
+else
+ZMQ_FLAGS=
+endif
+
+ifndef ZEROMQ_VERSION
+ZEROMQ_VERSION=v2.1.11
+endif
+
+all: $(DEPS)/zeromq2/src/.libs/libzmq.a
+
+clean:
+ if test -e $(DEPS)/zeromq2/Makefile; then \
+ cd $(DEPS)/zeromq2; make clean; \
+ else \
+ true; \
+ fi
+
+distclean:
+ @rm -rf $(DEPS)
+
+$(DEPS)/zeromq2:
+ @mkdir $(DEPS)
+ @git clone git://github.com/zeromq/zeromq2-x.git $(DEPS)/zeromq2
+ @echo $(ZEROMQ_VERSION)
+ @cd $(DEPS)/zeromq2 && git checkout $(ZEROMQ_VERSION)
+
+$(DEPS)/zeromq2/src/.libs/libzmq.a: $(DEPS)/zeromq2
+ @cd $(DEPS)/zeromq2 && ./autogen.sh && ./configure $(ZMQ_FLAGS) && make
View
38 c_src/Makefile
@@ -1,33 +1,9 @@
-LINUX=$(shell uname | grep Linux | wc -l | xargs echo)
-DEPS=../deps
+# a stub makefile for BSD make.
+# just redirect to GNU make, which is commonly available as "gmake".
-ifeq ($(LINUX),1)
-ZMQ_FLAGS=--with-pic
-else
-ZMQ_FLAGS=
-endif
+TARGETS=all clean distclean
-ifndef ZEROMQ_VERSION
-ZEROMQ_VERSION=v2.1.11
-endif
-
-all: $(DEPS)/zeromq2/src/.libs/libzmq.a
-
-clean:
- if test -e $(DEPS)/zeromq2/Makefile; then \
- cd $(DEPS)/zeromq2; make clean; \
- else \
- true; \
- fi
-
-distclean:
- @rm -rf $(DEPS)
-
-$(DEPS)/zeromq2:
- @mkdir $(DEPS)
- @git clone git://github.com/zeromq/zeromq2-x.git $(DEPS)/zeromq2
- @echo $(ZEROMQ_VERSION)
- @cd $(DEPS)/zeromq2 && git checkout $(ZEROMQ_VERSION)
-
-$(DEPS)/zeromq2/src/.libs/libzmq.a: $(DEPS)/zeromq2
- @cd $(DEPS)/zeromq2 && ./autogen.sh && ./configure $(ZMQ_FLAGS) && make
+.for T in ${TARGETS}
+${T}:
+ @gmake ${T}
+.endfor
Please sign in to comment.
Something went wrong with that request. Please try again.