parent
e102215755
commit
3d03607120
1 changed files with 18 additions and 10 deletions
|
@ -46,23 +46,31 @@ pre_configure() {
|
||||||
if [ "$CROSS_BUILD" ]; then
|
if [ "$CROSS_BUILD" ]; then
|
||||||
CC= CXX= CPP= LD= AR= AS= RANLIB= CFLAGS= CXXFLAGS= LDFLAGS= cmake .
|
CC= CXX= CPP= LD= AR= AS= RANLIB= CFLAGS= CXXFLAGS= LDFLAGS= cmake .
|
||||||
make comp_err comp_sql gen_lex_hash gen_lex_token
|
make comp_err comp_sql gen_lex_hash gen_lex_token
|
||||||
mkdir -p bin.host
|
mkdir -p bin.host/{extra,scripts,sql}
|
||||||
cp extra/comp_err bin.host
|
cp extra/comp_err bin.host/extra
|
||||||
cp scripts/comp_sql bin.host
|
cp scripts/comp_sql bin.host/scripts
|
||||||
cp sql/gen_lex_hash bin.host
|
cp sql/gen_lex_hash bin.host/sql
|
||||||
cp sql/gen_lex_token bin.host
|
cp sql/gen_lex_token bin.host/sql
|
||||||
make clean
|
make clean
|
||||||
|
# Remove the rules for the host binaries to not
|
||||||
|
# have them overwritten with target binaries
|
||||||
rm CMakeCache.txt
|
rm CMakeCache.txt
|
||||||
|
vsed -i ${wrksrc}/scripts/CMakeLists.txt \
|
||||||
|
-e "/ADD_EXECUTABLE(comp_sql/d"
|
||||||
|
vsed -i ${wrksrc}/sql/CMakeLists.txt \
|
||||||
|
-e "/ADD_EXECUTABLE(gen_lex_hash/d" \
|
||||||
|
-e "/ADD_EXECUTABLE(gen_lex_token/d" \
|
||||||
|
-e "/ADD_DEPENDENCIES(gen_lex_token/d"
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
pre_build() {
|
pre_build() {
|
||||||
if [ "$CROSS_BUILD" ]; then
|
if [ "$CROSS_BUILD" ]; then
|
||||||
cp bin.host/comp_err ${wrksrc}/extra
|
mkdir -p ${wrksrc}/build
|
||||||
cp bin.host/comp_sql ${wrksrc}/scripts
|
cp -a ${wrksrc}/bin.host/* ${wrksrc}/build
|
||||||
cp bin.host/gen_lex_hash ${wrksrc}/sql
|
mkdir -p ${wrksrc}/build/libmysqld
|
||||||
cp bin.host/gen_lex_token ${wrksrc}/sql
|
cp ${wrksrc}/bin.host/sql/gen_lex_token ${wrksrc}/build/libmysqld
|
||||||
export PATH=${PATH}:${wrksrc}/extra:${wrksrc}/scripts:${wrksrc}/sql
|
export PATH=${PATH}:${wrksrc}/build/extra:${wrksrc}/build/scripts:${wrksrc}/build/sql
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue