diff --git a/0001-add-settings.patch b/0001-add-settings.patch new file mode 100644 index 0000000000000000000000000000000000000000..a09bfaa4599e7b908aac73cefbdff2de10a45fa7 --- /dev/null +++ b/0001-add-settings.patch @@ -0,0 +1,44 @@ +From 81bfa0fb035176127c82b186c9eddbd47e9de76c Mon Sep 17 00:00:00 2001 +From: miao_kaibo +Date: Thu, 7 Jan 2021 09:48:09 +0800 +Subject: [PATCH] add settings + +--- + build | 3 +++ + settings.xml | 10 ++++++++++ + 2 files changed, 13 insertions(+) + create mode 100644 settings.xml + +diff --git a/build b/build +index 9b2d0f2..5f7bb19 100755 +--- a/build ++++ b/build +@@ -1357,6 +1357,9 @@ for RECIPEFILE in "${RECIPEFILES[@]}" ; do + if test -f $BUILD_ROOT/etc/gshadow ; then + sed -i -e "s@^root::@root:*:@" $BUILD_ROOT/etc/gshadow + fi ++ mkdir -p $BUILD_ROOT/home/abuild/.m2 ++ chown $ABUILD_UID:$ABUILD_GID $BUILD_ROOT/home/abuild/.m2 ++ cp $BUILD_DIR/settings.xml $BUILD_ROOT/home/abuild/.m2/ + BUILD_USER_ABUILD_USED=true + else + # building as root +diff --git a/settings.xml b/settings.xml +new file mode 100644 +index 0000000..99a806f +--- /dev/null ++++ b/settings.xml +@@ -0,0 +1,10 @@ ++ ++ ++ ++ huaweicloud ++ huaweicloud ++ * ++ https://mirrors.huaweicloud.com/repository/maven/ ++ ++ ++ +-- +2.27.0 + diff --git a/obs-build.spec b/obs-build.spec index a7d7a52dd7df951dd449a0336a8554bc3bbb2b6b..1423d7fbc5d68196c50d75ab5daa51f96ca51b22 100644 --- a/obs-build.spec +++ b/obs-build.spec @@ -1,11 +1,12 @@ Name: build Version: 20191114 -Release: 324.4 +Release: 324.5 Summary: A tool to build binary packages License: GPL-2.0-only OR GPL-3.0-only Url: https://github.com/openSUSE/obs-build Source: obs-build-%{version}.tar.gz Patch0000: 0001-modify-for-obs-build.patch +Patch0001: 0001-add-settings.patch BuildArch: noarch Requires: bash binutils perl tar psmisc build-mkbaselibs BuildRequires: bash binutils perl psmisc tar @@ -47,6 +48,7 @@ This package contains some man help packages for %{name}. %install %make_install +%{__install} -m644 settings.xml %{buildroot}/usr/lib/build %check for file in build build-* @@ -99,6 +101,9 @@ sed -i 's,build-mkbaselibs,,' configs/*.conf %{_mandir}/man1/buildvc.1* %changelog +* Thu Jan 07 2021 openEuler miao_kaibo - 20191114-324.5 +- Add settings.xml for jar + * Mon Jul 27 2020 openEuler Jeffery.Gao - 20191114-324.4 - Modify for obs-build access URL