comparison make/devkit/createPandocBundle.sh @ 53954:0c637249d934

8214780: Create pandoc package for Windows Reviewed-by: erikj
author ihse
date Mon, 10 Dec 2018 09:37:18 +0100
parents 2e52aa822c57
children
comparison
equal deleted inserted replaced
1:fcba479e0884 2:a0b8a54e04cb
39 PANDOC_PLATFORM=linux 39 PANDOC_PLATFORM=linux
40 PANDOC_SUFFIX=tar.gz 40 PANDOC_SUFFIX=tar.gz
41 elif [[ $TARGET_PLATFORM == macosx_x64 ]] ; then 41 elif [[ $TARGET_PLATFORM == macosx_x64 ]] ; then
42 PANDOC_PLATFORM=macOS 42 PANDOC_PLATFORM=macOS
43 PANDOC_SUFFIX=zip 43 PANDOC_SUFFIX=zip
44 elif [[ $TARGET_PLATFORM == windows_x64 ]] ; then
45 PANDOC_PLATFORM=windows-x86_64
46 PANDOC_SUFFIX=zip
44 else 47 else
45 echo "Unknown platform" 48 echo "Unknown platform"
46 exit 1 49 exit 1
47 fi 50 fi
48 BUNDLE_NAME=pandoc-$TARGET_PLATFORM-$PANDOC_VERSION+$PACKAGE_VERSION.tar.gz 51 BUNDLE_NAME=pandoc-$TARGET_PLATFORM-$PANDOC_VERSION+$PACKAGE_VERSION.tar.gz
57 tar xzf ../pandoc-$PANDOC_VERSION-$PANDOC_PLATFORM.$PANDOC_SUFFIX 60 tar xzf ../pandoc-$PANDOC_VERSION-$PANDOC_PLATFORM.$PANDOC_SUFFIX
58 fi 61 fi
59 cd .. 62 cd ..
60 63
61 mkdir pandoc 64 mkdir pandoc
62 cp tmp/pandoc-$PANDOC_VERSION/bin/pandoc pandoc 65 if [[ $TARGET_PLATFORM == windows_x64 ]] ; then
66 cp tmp/pandoc-$PANDOC_VERSION-$PANDOC_PLATFORM/pandoc.exe pandoc
67 chmod +x pandoc/pandoc.exe
68 else
69 cp tmp/pandoc-$PANDOC_VERSION/bin/pandoc pandoc
70 fi
63 71
64 tar -cvzf ../$BUNDLE_NAME pandoc 72 tar -cvzf ../$BUNDLE_NAME pandoc
65 cp ../$BUNDLE_NAME "$ORIG_DIR" 73 cp ../$BUNDLE_NAME "$ORIG_DIR"