|
|
@@ -1,6 +1,6 @@
|
|
|
-#! /bin/sh
|
|
|
+#! /bin/bash
|
|
|
#
|
|
|
-# $Id: //poco/1.3/release/script/mkrelease#10 $
|
|
|
+# $Id: //poco/1.4/release/script/mkrelease#8 $
|
|
|
#
|
|
|
# mkrelease
|
|
|
#
|
|
|
@@ -18,7 +18,14 @@ if [ "$1" = "" ] ; then
|
|
|
exit 1
|
|
|
fi
|
|
|
|
|
|
-comps="Foundation XML Util Net"
|
|
|
+case `uname` in
|
|
|
+ CYGWIN*) cygwin=1
|
|
|
+ ;;
|
|
|
+ *) cygwin=""
|
|
|
+ ;;
|
|
|
+esac
|
|
|
+
|
|
|
+comps="Foundation XML JSON Util Net"
|
|
|
internal=0
|
|
|
specfile=""
|
|
|
version=""
|
|
|
@@ -52,7 +59,7 @@ do
|
|
|
done
|
|
|
|
|
|
if [ "$specfile" != "" ] ; then
|
|
|
- while read c
|
|
|
+ while read c
|
|
|
do
|
|
|
comps="$comps $c"
|
|
|
done <$specfile
|
|
|
@@ -72,21 +79,26 @@ fi
|
|
|
mkdir -p ${target}
|
|
|
mkdir -p ${target}/doc
|
|
|
mkdir -p ${target}/contrib
|
|
|
+mkdir -p ${target}/patches
|
|
|
|
|
|
|
|
|
#
|
|
|
# readme files, etc.
|
|
|
#
|
|
|
echo ${version} "(`date +%Y-%m-%d`)" >${target}/VERSION
|
|
|
-cp ${POCO_BASE}/dist/LICENSE ${target}
|
|
|
-cp ${POCO_BASE}/dist/NEWS ${target}
|
|
|
-cp ${POCO_BASE}/dist/README ${target}
|
|
|
-cp ${POCO_BASE}/dist/CHANGELOG ${target}
|
|
|
-cp ${POCO_BASE}/dist/CONTRIBUTORS ${target}
|
|
|
+cp ${POCO_BASE}/LICENSE ${target}
|
|
|
+cp ${POCO_BASE}/NEWS ${target}
|
|
|
+cp ${POCO_BASE}/README ${target}
|
|
|
+cp ${POCO_BASE}/CHANGELOG ${target}
|
|
|
+cp ${POCO_BASE}/CONTRIBUTORS ${target}
|
|
|
+cp ${POCO_BASE}/DLLVersion.rc ${target}
|
|
|
|
|
|
cp ${POCO_BASE}/doc/Acknowledgements.html ${target}/doc
|
|
|
+cp ${POCO_BASE}/doc/*.page ${target}/doc
|
|
|
|
|
|
cp -R ${POCO_BASE}/contrib/* ${target}/contrib
|
|
|
+cp -R ${POCO_BASE}/patches/* ${target}/patches
|
|
|
+
|
|
|
|
|
|
#
|
|
|
# build system
|
|
|
@@ -95,16 +107,19 @@ mkdir -p ${target}/build/config
|
|
|
mkdir -p ${target}/build/rules
|
|
|
mkdir -p ${target}/build/script
|
|
|
mkdir -p ${target}/build/vms
|
|
|
+mkdir -p ${target}/build/vxconfig
|
|
|
|
|
|
cp ${POCO_BASE}/build/config/* ${target}/build/config
|
|
|
cp ${POCO_BASE}/build/rules/* ${target}/build/rules
|
|
|
+cp ${POCO_BASE}/build/vxconfig/* ${target}/build/vxconfig
|
|
|
cp ${POCO_BASE}/build/script/makedepend.* ${target}/build/script
|
|
|
cp ${POCO_BASE}/build/script/makeldpath ${target}/build/script
|
|
|
cp ${POCO_BASE}/build/script/shlibln ${target}/build/script
|
|
|
cp ${POCO_BASE}/build/script/projname ${target}/build/script
|
|
|
+cp ${POCO_BASE}/build/script/vxprogen ${target}/build/script
|
|
|
cp ${POCO_BASE}/build/vms/* ${target}/build/vms
|
|
|
-cp ${POCO_BASE}/dist/buildwin.cmd ${target}
|
|
|
-cp ${POCO_BASE}/dist/configure ${target}
|
|
|
+cp ${POCO_BASE}/buildwin.cmd ${target}
|
|
|
+cp ${POCO_BASE}/configure ${target}
|
|
|
cp ${POCO_BASE}/buildvms.com ${target}
|
|
|
cp ${POCO_BASE}/libversion ${target}
|
|
|
|
|
|
@@ -131,14 +146,23 @@ cp ${POCO_BASE}/CppUnit/include/CppUnit/* ${target}/CppUnit/include/CppUnit
|
|
|
cp ${POCO_BASE}/CppUnit/src/* ${target}/CppUnit/src
|
|
|
cp ${POCO_BASE}/CppUnit/*.sln ${target}/CppUnit
|
|
|
cp ${POCO_BASE}/CppUnit/*.vcproj ${target}/CppUnit
|
|
|
+cp ${POCO_BASE}/CppUnit/*.vcxproj ${target}/CppUnit
|
|
|
+cp ${POCO_BASE}/CppUnit/*.vcxproj.filters ${target}/CppUnit
|
|
|
+cp ${POCO_BASE}/CppUnit/*.vcxproj.user ${target}/CppUnit
|
|
|
cp ${POCO_BASE}/CppUnit/Makefile ${target}/CppUnit
|
|
|
cp ${POCO_BASE}/CppUnit/*.vmsbuild ${target}/CppUnit
|
|
|
+cp ${POCO_BASE}/CppUnit/*.vxbuild ${target}/CppUnit
|
|
|
+cp ${POCO_BASE}/CppUnit/*.progen ${target}/CppUnit
|
|
|
|
|
|
cp ${POCO_BASE}/CppUnit/WinTestRunner/include/WinTestRunner/* ${target}/CppUnit/WinTestRunner/include/WinTestRunner
|
|
|
cp ${POCO_BASE}/CppUnit/WinTestRunner/src/* ${target}/CppUnit/WinTestRunner/src
|
|
|
cp ${POCO_BASE}/CppUnit/WinTestRunner/res/WinTestRunner.rc ${target}/CppUnit/WinTestRunner/res
|
|
|
cp ${POCO_BASE}/CppUnit/WinTestRunner/res/Resource.h ${target}/CppUnit/WinTestRunner/res
|
|
|
cp ${POCO_BASE}/CppUnit/WinTestRunner/*.vcproj ${target}/CppUnit/WinTestRunner
|
|
|
+cp ${POCO_BASE}/CppUnit/WinTestRunner/*.vcxproj ${target}/CppUnit/WinTestRunner
|
|
|
+cp ${POCO_BASE}/CppUnit/WinTestRunner/*.vcxproj.filters ${target}/CppUnit/WinTestRunner
|
|
|
+cp ${POCO_BASE}/CppUnit/WinTestRunner/*.vcxproj.user ${target}/CppUnit/WinTestRunner
|
|
|
+cp ${POCO_BASE}/CppUnit/WinTestRunner/*.progen ${target}/CppUnit/WinTestRunner
|
|
|
|
|
|
|
|
|
#
|
|
|
@@ -191,8 +215,10 @@ ifndef POCO_BUILD
|
|
|
export POCO_BUILD=$(POCO_BASE)
|
|
|
endif
|
|
|
|
|
|
-.PHONY: all libexecs cppunit tests samples clean distclean install
|
|
|
+.PHONY: poco all libexecs cppunit tests samples clean distclean install
|
|
|
|
|
|
+# TESTS and SAMPLES are set in config.make
|
|
|
+poco: libexecs $(if $(TESTS),tests) $(if $(SAMPLES),samples)
|
|
|
all: libexecs tests samples
|
|
|
|
|
|
INSTALLDIR = $(DESTDIR)$(POCO_PREFIX)
|
|
|
@@ -250,7 +276,7 @@ echo 'samples: $(filter-out $(foreach f,$(OMIT),$f%),$(samples))' >>${target}/Ma
|
|
|
|
|
|
for comp in $comps ;
|
|
|
do
|
|
|
- if [ `grep -c POCO_LICENSING "${POCO_BASE}/${comp}/Makefile"` != 0 ] ; then
|
|
|
+ if [ "`grep -c POCO_LICENSING "${POCO_BASE}/${comp}/Makefile"`" != 0 ] ; then
|
|
|
dependencies=$licensingDep
|
|
|
else
|
|
|
dependencies=""
|
|
|
@@ -258,6 +284,8 @@ do
|
|
|
if [ -f "${POCO_BASE}/${comp}/dependencies" ] ; then
|
|
|
for dep in `cat "${POCO_BASE}/${comp}/dependencies"` ;
|
|
|
do
|
|
|
+ # get rid of surrounding whitespace (trailing \r on Cygwin)
|
|
|
+ read dep <<< "$dep"
|
|
|
dependencies="$dependencies ${dep}-libexec"
|
|
|
done
|
|
|
fi
|
|
|
@@ -280,6 +308,8 @@ ENDOFSCRIPT
|
|
|
if [ -f "${POCO_BASE}/${comp}/samples/dependencies" ] ; then
|
|
|
for dep in `cat "${POCO_BASE}/${comp}/samples/dependencies"` ;
|
|
|
do
|
|
|
+ # get rid of surrounding whitespace (trailing \r on Cygwin)
|
|
|
+ read dep <<< ${dep}
|
|
|
sdependencies="$sdependencies ${dep}-libexec"
|
|
|
done
|
|
|
fi
|
|
|
@@ -311,6 +341,7 @@ ENDOFSCRIPT
|
|
|
done
|
|
|
|
|
|
cat >>${target}/Makefile <<ENDOFSCRIPT
|
|
|
+ \$(MAKE) -C \$(POCO_BASE)/CppUnit clean
|
|
|
|
|
|
distclean:
|
|
|
rm -rf \$(POCO_BUILD)/lib
|
|
|
@@ -321,39 +352,90 @@ ENDOFSCRIPT
|
|
|
|
|
|
|
|
|
#
|
|
|
-# Create Visual Studio 7.1 buils script
|
|
|
+# Create Visual Studio 7.1 build script
|
|
|
#
|
|
|
cat >${target}/build_vs71.cmd <<'ENDOFSCRIPT'
|
|
|
@echo off
|
|
|
-buildwin 71 build shared both yes
|
|
|
+if defined VS71COMNTOOLS (
|
|
|
+call "%VS71COMNTOOLS%\vsvars32.bat")
|
|
|
+buildwin 71 build shared both Win32 samples
|
|
|
ENDOFSCRIPT
|
|
|
|
|
|
|
|
|
#
|
|
|
-# Create Visual Studio 8 buils script
|
|
|
+# Create Visual Studio 8 build script
|
|
|
#
|
|
|
cat >${target}/build_vs80.cmd <<'ENDOFSCRIPT'
|
|
|
@echo off
|
|
|
-buildwin 80 build shared both yes
|
|
|
+if defined VS80COMNTOOLS (
|
|
|
+call "%VS80COMNTOOLS%\vsvars32.bat")
|
|
|
+buildwin 80 build shared both Win32 samples
|
|
|
ENDOFSCRIPT
|
|
|
|
|
|
|
|
|
#
|
|
|
-# Create Visual Studio 9 buils script
|
|
|
+# Create Visual Studio 9 build script
|
|
|
#
|
|
|
cat >${target}/build_vs90.cmd <<'ENDOFSCRIPT'
|
|
|
@echo off
|
|
|
-buildwin 90 build shared both yes
|
|
|
+if defined VS90COMNTOOLS (
|
|
|
+call "%VS90COMNTOOLS%\vsvars32.bat")
|
|
|
+buildwin 90 build shared both Win32 samples
|
|
|
+ENDOFSCRIPT
|
|
|
+
|
|
|
+
|
|
|
+#
|
|
|
+# Create Visual Studio 10 build script
|
|
|
+#
|
|
|
+cat >${target}/build_vs100.cmd <<'ENDOFSCRIPT'
|
|
|
+@echo off
|
|
|
+if defined VS100COMNTOOLS (
|
|
|
+call "%VS100COMNTOOLS%\vsvars32.bat")
|
|
|
+buildwin 100 build shared both Win32 samples
|
|
|
+ENDOFSCRIPT
|
|
|
+
|
|
|
+
|
|
|
+#
|
|
|
+# Create Visual Studio 9 WinCE build script
|
|
|
+#
|
|
|
+cat >${target}/build_CE_vs90.cmd <<'ENDOFSCRIPT'
|
|
|
+@echo off
|
|
|
+buildwin 90 build static_mt both WinCE samples
|
|
|
+ENDOFSCRIPT
|
|
|
+
|
|
|
+
|
|
|
+#
|
|
|
+# Create Visual C++ Express 2008 build script
|
|
|
+#
|
|
|
+cat >${target}/build_vcexpress2008.cmd <<'ENDOFSCRIPT'
|
|
|
+@echo off
|
|
|
+buildwin 90 build shared both Win32 samples vcexpress
|
|
|
+ENDOFSCRIPT
|
|
|
+
|
|
|
+
|
|
|
+#
|
|
|
+# Create Visual C++ Express 2010 build script
|
|
|
+#
|
|
|
+cat >${target}/build_vcexpress2010.cmd <<'ENDOFSCRIPT'
|
|
|
+@echo off
|
|
|
+buildwin 100 build shared both Win32 samples vcexpress
|
|
|
ENDOFSCRIPT
|
|
|
|
|
|
|
|
|
#
|
|
|
# Fix line endings
|
|
|
#
|
|
|
-if [ -x /usr/bin/unix2dos ] ; then
|
|
|
- /usr/bin/unix2dos ${target}/build_vs71.cmd
|
|
|
- /usr/bin/unix2dos ${target}/build_vs80.cmd
|
|
|
- /usr/bin/unix2dos ${target}/build_vs90.cmd
|
|
|
+if [ $cygwin ] ; then
|
|
|
+ if [ -x /usr/bin/unix2dos ] ; then
|
|
|
+ /usr/bin/unix2dos ${target}/build_vs71.cmd
|
|
|
+ /usr/bin/unix2dos ${target}/build_vs80.cmd
|
|
|
+ /usr/bin/unix2dos ${target}/build_vs90.cmd
|
|
|
+ /usr/bin/unix2dos ${target}/build_vs100.cmd
|
|
|
+ /usr/bin/unix2dos ${target}/build_CE_vs90.cmd
|
|
|
+ /usr/bin/unix2dos ${target}/build_vcexpress2008.cmd
|
|
|
+ /usr/bin/unix2dos ${target}/build_vcexpress2010.cmd
|
|
|
+ /usr/bin/unix2dos ${target}/Makefile
|
|
|
+ fi
|
|
|
fi
|
|
|
|
|
|
|