about summary refs log tree commit diff
path: root/converter/other/jbig/Makefile
diff options
context:
space:
mode:
authorgiraffedata <giraffedata@9d0c8265-081b-0410-96cb-a4ca84ce46f8>2006-08-19 03:12:28 +0000
committergiraffedata <giraffedata@9d0c8265-081b-0410-96cb-a4ca84ce46f8>2006-08-19 03:12:28 +0000
commit1fd361a1ea06e44286c213ca1f814f49306fdc43 (patch)
tree64c8c96cf54d8718847339a403e5e67b922e8c3f /converter/other/jbig/Makefile
downloadnetpbm-mirror-1fd361a1ea06e44286c213ca1f814f49306fdc43.tar.gz
netpbm-mirror-1fd361a1ea06e44286c213ca1f814f49306fdc43.tar.xz
netpbm-mirror-1fd361a1ea06e44286c213ca1f814f49306fdc43.zip
Create Subversion repository
git-svn-id: http://svn.code.sf.net/p/netpbm/code/trunk@1 9d0c8265-081b-0410-96cb-a4ca84ce46f8
Diffstat (limited to 'converter/other/jbig/Makefile')
-rw-r--r--converter/other/jbig/Makefile47
1 files changed, 47 insertions, 0 deletions
diff --git a/converter/other/jbig/Makefile b/converter/other/jbig/Makefile
new file mode 100644
index 00000000..ca98ef29
--- /dev/null
+++ b/converter/other/jbig/Makefile
@@ -0,0 +1,47 @@
+ifeq ($(SRCDIR)x,x)
+  SRCDIR = $(CURDIR)/../../..
+  BUILDDIR = $(SRCDIR)
+endif
+SUBDIR = converter/other/jbig
+VPATH=.:$(SRCDIR)/$(SUBDIR)
+
+include $(BUILDDIR)/Makefile.config
+
+LIBJBIG_OBJECTS = jbig.o jbig_tab.o
+
+INCLUDES =
+ifneq ($(JBIGHDR_DIR),NONE)
+  INCLUDES += -I$(JBIGHDR_DIR)
+endif
+
+ifneq ($(JBIGHDR_DIR),NONE)
+  ifneq ($(JBIGLIB),NONE)
+    BINARIES = jbigtopnm pnmtojbig
+  endif
+endif
+
+SCRIPTS =
+
+ifeq ($(JBIGLIB),$(BUILDDIR)/$(SUBDIR)/libjbig.a)
+  JBIGLIB_DEP = $(JBIGLIB)
+else
+  # It's not our internal version; user's on his own to make sure it's built
+endif
+
+OBJECTS = $(BINARIES:%=%.o) $(LIBJBIG_OBJECTS)
+MERGE_OBJECTS = $(BINARIES:%=%.o2) $(LIBJBIG_OBJECTS)
+
+all: $(BINARIES)
+
+include $(SRCDIR)/Makefile.common
+
+$(BINARIES): %: %.o $(JBIGLIB_DEP) $(NETPBMLIB) $(LIBOPT)
+	$(LD) $(LDFLAGS) -o $@ $< \
+	  $(shell $(LIBOPT) $(NETPBMLIB) $(JBIGLIB)) $(MATHLIB) $(LDLIBS) \
+	  $(RPATH) $(LADD)
+
+
+$(BUILDDIR)/$(SUBDIR)/libjbig.a: $(LIBJBIG_OBJECTS)
+	$(AR) -rc $@ $^
+	$(RANLIB) $@
+