-
Notifications
You must be signed in to change notification settings - Fork 27
/
checkoutpwiz.sh
149 lines (113 loc) · 4.21 KB
/
checkoutpwiz.sh
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
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
#!/bin/bash
#------------------
# http://proteowizard.svn.sourceforge.net/viewvc/proteowizard/trunk/pwiz/libraries/boost_aux/boost/utility/
cd src
if /bin/false ; then
#------------------
rm -rf pwiz
mkdir pwiz
cd pwiz
PWIZREPO=http://svn.code.sf.net/p/proteowizard/code/trunk/pwiz/
svn co --non-recursive $PWIZREPO .
for DIR in data/msdata data/identdata data/proteome data/common utility/chemistry/ utility/misc/ utility/math/ utility/minimxml/ ; do
svn co $PWIZREPO/pwiz/$DIR $DIR
done
cd ..
#------------------
rm -rf boost
BOOSTVER=1_58_0
BOOSTVERDOT=1.58.0
BOOSTURL=https://freefr.dl.sourceforge.net/project/boost/boost/$BOOSTVERDOT/boost_$BOOSTVER.tar.gz
wget -O- "$BOOSTURL" | tar xzvf -
mv boost_$BOOSTVER boost
#------------------
rm -rf boost_aux
mkdir boost_aux
cd boost_aux
PWIZBOOSTREPO=http://svn.code.sf.net/p/proteowizard/code/trunk/pwiz/libraries/boost_aux/boost/
svn co $PWIZBOOSTREPO boost
cd ..
#------------------
fi
#------------------
PWIZ_MAJOR=$(grep "constant PWIZ_MAJOR" pwiz/Jamroot.jam | sed -e 's/constant PWIZ_MAJOR : \([0-9+]\) ;/\1/')
PWIZ_MINOR=$(grep "constant PWIZ_MINOR" pwiz/Jamroot.jam | sed -e 's/constant PWIZ_MINOR : \([0-9+]\) ;/\1/')
#lastchangedrev=$(svn info pwiz/data/msdata | grep "Last Changed Rev:" | cut -d: -f 2)
#lastchangeddate=$(svn info pwiz/data/msdata | grep "Last Changed Date:" | cut -d" " -f 4 | tr "-" " ")
lastchangedrev=666
lastchangeddate="1016-03-22"
revisioninfo=( $lastchangedrev $lastchangeddate 3 4 )
echo ${revisioninfo[*]}
cat >pwiz/data/msdata/Version.cpp <<EOF
// This file was generated by the \"svnrev\" utility
// You should not modify it manually, as it may be re-generated.
//
// $Revision: ${revisioninfo[1]} $
// $Date: ${revisioninfo[2]}-${revisioninfo[3]}-${revisioninfo[4]} $
//
#define PWIZ_SOURCE
#include "Version.hpp"
#include <sstream>
#ifdef PWIZ_USER_VERSION_INFO_H // in case you need to add any info version of your own
#include PWIZ_USER_VERSION_INFO_H // must define PWIZ_USER_VERSION_INFO_H_STR for use below
#endif
namespace pwiz {
namespace msdata {
using std::string;
int Version::Major() {return 0${PWIZ_MAJOR};}
int Version::Minor() {return 0${PWIZ_MINOR};}
int Version::Revision() {return 0${revisioninfo[1]};}
string Version::LastModified() {return "${revisioninfo[2]}-${revisioninfo[3]}-${revisioninfo[4]}";}
string Version::str()
{
std::ostringstream v;
v << Major() << '.' << Minor() << '.' << Revision();
#ifdef PWIZ_USER_VERSION_INFO_H
v << " (" << PWIZ_USER_VERSION_INFO_H_STR << ")";
#endif
return v.str();
}
}
}
EOF
#------------------
PWIZ_MAJOR=$(grep "constant PWIZ_MAJOR" pwiz/Jamroot.jam | sed -e 's/constant PWIZ_MAJOR : \([0-9+]\) ;/\1/')
PWIZ_MINOR=$(grep "constant PWIZ_MINOR" pwiz/Jamroot.jam | sed -e 's/constant PWIZ_MINOR : \([0-9+]\) ;/\1/')
#lastchangedrev=$(svn info pwiz/data/msdata | grep "Last Changed Rev:" | cut -d: -f 2)
#lastchangeddate=$(svn info pwiz/data/msdata | grep "Last Changed Date:" | cut -d" " -f 4 | tr "-" " ")
lastchangedrev=666
lastchangeddate="1016-03-22"
revisioninfo=( $lastchangedrev $lastchangeddate 3 4 )
echo ${revisioninfo[*]}
cat >pwiz/data/identdata/Version.cpp <<EOF
// This file was generated by the \"svnrev\" utility
// You should not modify it manually, as it may be re-generated.
//
// $Revision: ${revisioninfo[1]} $
// $Date: ${revisioninfo[2]}-${revisioninfo[3]}-${revisioninfo[4]} $
//
#define PWIZ_SOURCE
#include "Version.hpp"
#include <sstream>
#ifdef PWIZ_USER_VERSION_INFO_H // in case you need to add any info version of your own
#include PWIZ_USER_VERSION_INFO_H // must define PWIZ_USER_VERSION_INFO_H_STR for use below
#endif
namespace pwiz {
namespace identdata {
using std::string;
int Version::Major() {return 0${PWIZ_MAJOR};}
int Version::Minor() {return 0${PWIZ_MINOR};}
int Version::Revision() {return 0${revisioninfo[1]};}
string Version::LastModified() {return "${revisioninfo[2]}-${revisioninfo[3]}-${revisioninfo[4]}";}
string Version::str()
{
std::ostringstream v;
v << Major() << '.' << Minor() << '.' << Revision();
#ifdef PWIZ_USER_VERSION_INFO_H
v << " (" << PWIZ_USER_VERSION_INFO_H_STR << ")";
#endif
return v.str();
}
}
}
EOF