# Compiler to use
-CC = g++
-CFLAGS ?= -O2
-#CFLAGS += -g -Wall
-#CFLAGS += -ansi
-#CFLAGS += -pedantic
-#CFLAGS += -std=c++0x
-
-# Comment out CFLAGS line below for compatability mode for 32bit file sizes
+# CXX = g++
+
+
+# Thread-related flags
+# On some compilers -pthreads
+CXXFLAGS_PTHREAD = -pthread
+
+# Comment out CXXFLAGS line below to disable pthread semantics in code
+CXXFLAGS_PTHREAD += -D_POSIX_PTHREAD_SEMANTICS
+
+LDLIBS_PTHREAD = -lpthread
+
+
+# Optimization flags
+CXXFLAGS = -O2
+
+#CXXFLAGS += -g -Wall
+#CXXFLAGS += -ansi
+#CXXFLAGS += -pedantic
+#CXXFLAGS += -std=c++0x
+
+# Comment out CXXFLAGS line below for compatability mode for 32bit file sizes
# (less than 2GB) and systems that have compilers that treat int as 64bit
# natively (ie: modern AIX)
CXXFLAGS += -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64
# External libraries
-LDFLAGS += -lbz2
-LDFLAGS += -lpthread
+LDLIBS = -lbz2
+LDLIBS += $(LDLIBS_PTHREAD)
+
# Where you want pbzip2 installed when you do 'make install'
PREFIX = /usr
Name: pbzip2
-Version: 1.1.6
+Version: 1.1.13
Release: 0
Summary: Parallel implementation of bzip2
URL: http://www.compression.ca/pbzip2/
ln -s pbzip2 %{buildroot}%{_bindir}/pbunzip2
ln -s pbzip2 %{buildroot}%{_bindir}/pbzcat
-%docs_package
+%remove_docs
%files
%manifest %{name}.manifest