File tree Expand file tree Collapse file tree 4 files changed +34
-3
lines changed
Expand file tree Collapse file tree 4 files changed +34
-3
lines changed Original file line number Diff line number Diff line change 128128%endif
129129
130130%if [rpm]
131+ # Used to set rpm_arch to x86_64_v2 on Alma Linux
132+ if test -n " $pp_rpm_arch_override" ; then
133+ pp_rpm_arch=" $pp_rpm_arch_override"
134+ fi
135+
131136 # Add distro info to release
132137 osrelease=`echo " $pp_rpm_distro" | sed -e ' s/^[^0-9]*\([0-9]\{1,3\}\).*/\1/' `
133138 case " $pp_rpm_distro" in
Original file line number Diff line number Diff line change 8484%endif
8585
8686%if [rpm]
87+ # Used to set rpm_arch to x86_64_v2 on Alma Linux
88+ if test -n " $pp_rpm_arch_override " ; then
89+ pp_rpm_arch=" $pp_rpm_arch_override "
90+ fi
91+
8792 # Add distro info to release
8893 osrelease=`echo " $pp_rpm_distro " | sed -e ' s/^[^0-9]*\( [0-9]\{ 1,3\}\) .*/\1 /' `
8994 case " $pp_rpm_distro " in
Original file line number Diff line number Diff line change 149149%endif
150150
151151%if [rpm]
152+ # Used to set rpm_arch to x86_64_v2 on Alma Linux
153+ if test -n " $pp_rpm_arch_override" ; then
154+ pp_rpm_arch=" $pp_rpm_arch_override"
155+ fi
156+
152157 # Add distro info to release
153158 osrelease=`echo " $pp_rpm_distro" | sed -e ' s/^[^0-9]*\([0-9]\{1,3\}\).*/\1/' `
154159 case " $pp_rpm_distro" in
Original file line number Diff line number Diff line change 1717# OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
1818#
1919# Build a binary package using polypkg
20- # Usage: mkpkg [--build-only ] [--configure -only] [--debug ] [--flavor flavor ]
21- # [--platform platform ] [--osversion ver]
20+ # Usage: mkpkg [--arch arch ] [--build -only] [--configure-only ] [--debug ]
21+ # [--flavor flavor ] [--osversion ver] [--platform platform ]
2222#
2323
2424# Make sure IFS is set to space, tab, newline in that order.
2929IFS=" $nl "
3030
3131# Parse arguments
32- usage=" usage: mkpkg [--build-only] [--configure-only] [--debug] [--flavor flavor] [--platform platform ] [--osversion ver ]"
32+ usage=" usage: mkpkg [--arch arch] [-- build-only] [--configure-only] [--debug] [--flavor flavor] [--osversion ver ] [--platform platform ]"
3333debug=0
3434flavor=vanilla
3535crossbuild=false
3636build_packages=true;
3737build_sudo=true;
3838while test $# -gt 0; do
3939 case " $1 " in
40+ --arch=?* )
41+ arch=` echo " $1 " | sed -n ' s/^--arch=\(.*\)/\1/p' `
42+ ;;
43+ --arch)
44+ arch=` echo " $1 " | sed -n ' s/^--arch=\(.*\)/\1/p' `
45+ if [ $# -lt 2 ]; then
46+ echo " $usage " 1>&2
47+ exit 1
48+ fi
49+ arch=" $2 "
50+ shift
51+ ;;
4052 --debug)
4153 set -x
4254 debug=1
@@ -208,6 +220,10 @@ case "$osversion" in
208220 ;;
209221 esac
210222
223+ if [ -n " $arch " ]; then
224+ # Override the default rpm arch for, e.g. x86_64_v2
225+ PPVARS=" ${PPVARS}${PPVARS+$space } pp_rpm_arch_override=$arch "
226+ fi
211227 if [ X" $with_selinux " = X" true" ]; then
212228 configure_opts=" ${configure_opts}${configure_opts+$tab } --with-selinux"
213229 fi
You can’t perform that action at this time.
0 commit comments