mirror of
https://github.com/alsa-project/alsa-utils
synced 2024-12-22 10:56:30 +01:00
35 lines
641 B
Bash
35 lines
641 B
Bash
#!/bin/bash
|
|
|
|
source=.
|
|
version=`cat $source/../version`
|
|
package=$source/../../alsa-utils-$version.tar.gz
|
|
|
|
if [ ! -r $package ]; then
|
|
echo "Error: wrong package: $package"
|
|
exit 1
|
|
fi
|
|
|
|
make -C .. pack
|
|
|
|
cp -fv $package /usr/src/redhat/SOURCES
|
|
|
|
if [ ! -r $source/buildrpm ]; then
|
|
echo "Error: invalid directory: $source"
|
|
exit 1
|
|
fi
|
|
|
|
if [ ! -d /usr/src/redhat ]; then
|
|
echo "Error: /usr/src/redhat directory not found"
|
|
exit 1
|
|
fi
|
|
|
|
if [ ! -r $source/alsadriver.spec ]; then
|
|
cd $source/..
|
|
./configure
|
|
cd utils
|
|
fi
|
|
|
|
cp -fv $source/alsa-utils.spec /usr/src/redhat/SPECS
|
|
cd /usr/src/redhat/SPECS
|
|
rpm -ba alsa-utils.spec
|
|
cd /usr/src/redhat
|