summaryrefslogtreecommitdiffstats
path: root/Utilities/cmlibarchive/examples/minitar/Makefile
diff options
context:
space:
mode:
authorBill Hoffman <bill.hoffman@kitware.com>2009-10-30 17:10:56 (GMT)
committerBill Hoffman <bill.hoffman@kitware.com>2009-10-30 17:10:56 (GMT)
commitfb51d98562a26b6dcde7d3597938a0b707b6b881 (patch)
treeb42fbfb6b27b7a9e2d5068601f61d80e7033dc79 /Utilities/cmlibarchive/examples/minitar/Makefile
parent0615218bdf3e240e44e539f9eed6c1cf9fbff2d4 (diff)
downloadCMake-fb51d98562a26b6dcde7d3597938a0b707b6b881.zip
CMake-fb51d98562a26b6dcde7d3597938a0b707b6b881.tar.gz
CMake-fb51d98562a26b6dcde7d3597938a0b707b6b881.tar.bz2
Switch to using libarchive from libtar for cpack and cmake -E tar
This allows for a built in bzip and zip capability, so external tools will not be needed for these packagers. The cmake -E tar xf should be able to handle all compression types now as well.
Diffstat (limited to 'Utilities/cmlibarchive/examples/minitar/Makefile')
-rw-r--r--Utilities/cmlibarchive/examples/minitar/Makefile34
1 files changed, 34 insertions, 0 deletions
diff --git a/Utilities/cmlibarchive/examples/minitar/Makefile b/Utilities/cmlibarchive/examples/minitar/Makefile
new file mode 100644
index 0000000..4f8e708
--- /dev/null
+++ b/Utilities/cmlibarchive/examples/minitar/Makefile
@@ -0,0 +1,34 @@
+
+#
+# Adjust the following to control which options minitar gets
+# built with. See comments in minitar.c for details.
+#
+CFLAGS= \
+ -DNO_BZIP2_CREATE \
+ -DNO_BZIP2_EXTRACT \
+ -DNO_COMPRESS_EXTRACT \
+ -DNO_CPIO_EXTRACT \
+ -DNO_CREATE \
+ -DNO_GZIP_CREATE \
+ -DNO_GZIP_EXTRACT \
+ -DNO_LOOKUP
+
+# Omit 'tree.o' if you're not including create support
+#OBJS= minitar.o tree.o
+OBJS= minitar.o
+
+all: minitar
+
+minitar: $(OBJS)
+ cc -o minitar -static $(OBJS) -larchive -lz -lbz2
+ strip minitar
+ ls -l minitar
+
+minitar.o: minitar.c
+
+tree.o: tree.c
+
+clean::
+ rm -f *.o
+ rm -f minitar
+ rm -f *~