forked from q191201771/lal
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild_linux.sh
executable file
·27 lines (18 loc) · 988 Bytes
/
build_linux.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
#!/usr/bin/env bash
set -x
ROOT_DIR=`pwd`
echo ${ROOT_DIR}/bin
if [ ! -d ${ROOT_DIR}/bin ]; then
mkdir bin
fi
cd ${ROOT_DIR}/app/lal && \
GOOS=linux GOARCH=amd64 go build -ldflags " \
-X 'github.com/q191201771/lal/pkg/util/bininfo.GitCommitID=`git log --pretty=format:'%h' -n 1`' \
-X 'github.com/q191201771/lal/pkg/util/bininfo.BuildTime=`date +'%Y.%m.%d.%H%M%S'`' \
-X 'github.com/q191201771/lal/pkg/util/bininfo.BuildGoVersion=`go version`' \
" -o ${ROOT_DIR}/bin/lal
cd ${ROOT_DIR}/app/flvfile2es && GOOS=linux GOARCH=amd64 go build -o ${ROOT_DIR}/bin/flvfile2es
cd ${ROOT_DIR}/app/flvfile2rtmppush && GOOS=linux GOARCH=amd64 go build -o ${ROOT_DIR}/bin/flvfile2rtmppush
cd ${ROOT_DIR}/app/httpflvpull && GOOS=linux GOARCH=amd64 go build -o ${ROOT_DIR}/bin/httpflvpull
cd ${ROOT_DIR}/app/modflvfile && GOOS=linux GOARCH=amd64 go build -o ${ROOT_DIR}/bin/modflvfile
cd ${ROOT_DIR}/app/rtmppull && GOOS=linux GOARCH=amd64 go build -o ${ROOT_DIR}/bin/rtmppull