|
|
@ -32,15 +32,9 @@ build_proj() { |
|
|
|
cpu="$(nproc --all)" |
|
|
|
|
|
|
|
cd "$SRC" |
|
|
|
if ! [ -d proj ]; then |
|
|
|
git clone ${PROJ_URL} proj |
|
|
|
cd proj |
|
|
|
git checkout ${PROJ_REV} |
|
|
|
git submodule update --init |
|
|
|
./autogen.sh |
|
|
|
else |
|
|
|
cd proj |
|
|
|
fi |
|
|
|
cd proj |
|
|
|
|
|
|
|
./autogen.sh |
|
|
|
./configure --host=${host} --prefix=${prefix} \ |
|
|
|
--disable-documentation \ |
|
|
|
--with-ev="$dep" \ |
|
|
@ -52,29 +46,6 @@ build_proj() { |
|
|
|
make clean |
|
|
|
make -j$cpu LDFLAGS="-all-static -L${dep}/lib" |
|
|
|
make install |
|
|
|
|
|
|
|
# Reference SIP003 plugin (Experimental) |
|
|
|
[[ "${PLUGIN}" != "true" ]] && return 0 |
|
|
|
|
|
|
|
PLUGIN_URL=https://github.com/${PROJ_SITE}/simple-obfs.git |
|
|
|
PLUGIN_REV=master |
|
|
|
|
|
|
|
cd "$SRC" |
|
|
|
if ! [ -d plugin ]; then |
|
|
|
git clone ${PLUGIN_URL} plugin |
|
|
|
cd plugin |
|
|
|
git checkout ${PLUGIN_REV} |
|
|
|
git submodule update --init |
|
|
|
./autogen.sh |
|
|
|
else |
|
|
|
cd plugin |
|
|
|
fi |
|
|
|
./configure --host=${host} --prefix=${prefix} \ |
|
|
|
--disable-documentation \ |
|
|
|
--with-ev="$dep" |
|
|
|
make clean |
|
|
|
make -j$cpu LDFLAGS="-all-static -L${dep}/lib" |
|
|
|
make install |
|
|
|
} |
|
|
|
|
|
|
|
dk_build() { |
|
|
@ -93,20 +64,6 @@ dk_package() { |
|
|
|
cp ${DIST}/i686/bin/ss-${bin}.exe ss-${bin}-x86.exe |
|
|
|
cp ${DIST}/x86_64/bin/ss-${bin}.exe ss-${bin}-x64.exe |
|
|
|
done |
|
|
|
for bin in local server; do |
|
|
|
cp ${DIST}/i686/bin/obfs-${bin}.exe obfs-${bin}-x86.exe || true |
|
|
|
cp ${DIST}/x86_64/bin/obfs-${bin}.exe obfs-${bin}-x64.exe || true |
|
|
|
done |
|
|
|
pushd "$SRC/proj" |
|
|
|
GIT_REV="$(git rev-parse --short HEAD)" |
|
|
|
popd |
|
|
|
echo "SHA1 checksum for build $(date +"%y%m%d")-${GIT_REV}" > checksum |
|
|
|
for f in *.exe; do |
|
|
|
echo " $f:" >> checksum |
|
|
|
echo " $(sha1sum $f | cut -d ' ' -f 1)" >> checksum |
|
|
|
done |
|
|
|
sed -e 's/$/\r/' checksum > checksum.txt |
|
|
|
rm -f checksum |
|
|
|
cd .. |
|
|
|
tar zcf /bin.tgz ss-libev-${PROJ_REV} |
|
|
|
} |