File: linux-release.sh

package info (click to toggle)
kst 2.0.8-6
  • links: PTS, VCS
  • area: main
  • in suites: sid, trixie
  • size: 30,748 kB
  • sloc: cpp: 97,086; ansic: 13,364; python: 2,970; sh: 761; yacc: 184; lex: 143; makefile: 141; javascript: 122; perl: 30; xml: 30
file content (44 lines) | stat: -rwxr-xr-x 1,088 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
#!/bin/sh

# Usage
#   linux-release <version string> optional: <existing sourceforge dir>  <sourceforge username> <skip-build>
# e.g:
#   build  only     : linux-release.sh 2.0.3-beta2 
#   build and upload: linux-release.sh 2.0.3-beta2 "Kst\\ 2.0.3" username
#   upload only     : linux-release.sh 2.0.3-beta2 "Kst\\ 2.0.3" username skip
#   
set -x

kst_install_prefix=kst-$1

machine_type=`uname -m`
binarytar=${kst_install_prefix}-binary-${machine_type}.tar


if [ -z ${4} ]
then
	cmake ../kst -Dkst_release=1 -Dkst_merge_files=1 -Dkst_version_string=$1 -Dkst_install_prefix=$kst_install_prefix -Dkst_3rdparty_build=1 -Dkst_deploy=1
	cd 3rdparty
	make -j8
	cd ..
	make -j8
	make 
	make install/strip
	strip ${kst_install_prefix}/lib
	strip ${kst_install_prefix}/lib/kst2/plugins/*
	
    rm	${binarytar}.gz
    tar cf ${binarytar} ${kst_install_prefix}
    gzip -9 ${binarytar}
    make package_source
fi


if [ ! -z ${3} ]
then
	# spaces in $2 "Kst\\ 2.0.3"
	scp \
	${binarytar}.gz \
	${kst_install_prefix}.tar.gz \
	${3},kst@frs.sourceforge.net:"/home/frs/project/k/ks/kst/${2}"
fi