mirror of
https://github.com/xcat2/confluent.git
synced 2024-12-25 20:52:30 +00:00
a4fc64ea56
Since the rpm itself is built in an el7 container, build binary before spec driven build to be compatible.
23 lines
836 B
Plaintext
Executable File
23 lines
836 B
Plaintext
Executable File
VERSION=`git describe|cut -d- -f 1`
|
|
NUMCOMMITS=`git describe|cut -d- -f 2`
|
|
if [ "$NUMCOMMITS" != "$VERSION" ]; then
|
|
VERSION=$VERSION.dev$NUMCOMMITS.g`git describe|cut -d- -f 3`
|
|
fi
|
|
sed -e "s/#VERSION#/$VERSION/" confluent_osdeploy.spec.tmpl > confluent_osdeploy.spec
|
|
cd ..
|
|
tar Jcvf confluent_osdeploy.tar.xz confluent_osdeploy
|
|
mv confluent_osdeploy.tar.xz ~/rpmbuild/SOURCES/
|
|
cd -
|
|
mkdir -p el9bin/opt/confluent/bin
|
|
mkdir -p el9bin/stateless-bin
|
|
podman run --privileged --rm -v $(pwd)/utils:/buildutils -i -t fedorabuilder make -C /buildutils
|
|
cd utils
|
|
mv confluent_imginfo copernicus clortho autocons ../el9bin/opt/confluent/bin
|
|
mv start_root urlmount ../el9bin/stateless-bin/
|
|
make clean
|
|
cd ..
|
|
tar Jcvf confluent_el9bin.tar.xz el9bin/
|
|
mv confluent_el9bin.tar.xz ~/rpmbuild/SOURCES/
|
|
rm -rf el9bin
|
|
rpmbuild -ba confluent_osdeploy.spec
|