Compare commits
No commits in common. "8535603099c6b0cf43583a44fe9604e1d203ffae" and "2b2aa227102adbe4e3293361e1878adb60fd347a" have entirely different histories.
8535603099
...
2b2aa22710
68
dde-api.spec
Normal file → Executable file
68
dde-api.spec
Normal file → Executable file
@ -1,7 +1,4 @@
|
|||||||
# Run tests in check section
|
|
||||||
# disable for bootstrapping
|
|
||||||
%bcond_with check
|
%bcond_with check
|
||||||
#%global _unpackaged_files_terminate_build 0
|
|
||||||
%global with_debug 1
|
%global with_debug 1
|
||||||
|
|
||||||
%if 0%{?with_debug}
|
%if 0%{?with_debug}
|
||||||
@ -9,8 +6,8 @@
|
|||||||
%endif
|
%endif
|
||||||
|
|
||||||
%global sname deepin-api
|
%global sname deepin-api
|
||||||
|
%global release_name server-industry
|
||||||
|
|
||||||
# out of memory on armv7hl
|
|
||||||
%ifarch %{arm}
|
%ifarch %{arm}
|
||||||
%global _smp_mflags -j1
|
%global _smp_mflags -j1
|
||||||
%endif
|
%endif
|
||||||
@ -18,22 +15,22 @@
|
|||||||
%global goipath pkg.deepin.io/dde/api
|
%global goipath pkg.deepin.io/dde/api
|
||||||
%global forgeurl https://github.com/linuxdeepin/dde-api
|
%global forgeurl https://github.com/linuxdeepin/dde-api
|
||||||
%global tag %{version}
|
%global tag %{version}
|
||||||
|
%gometa
|
||||||
|
|
||||||
Name: dde-api
|
Name: dde-api
|
||||||
Version: 5.4.30
|
Version: 5.1.11.1
|
||||||
Release: 3
|
Release: 4
|
||||||
Summary: Go-lang bingding for dde-daemon
|
Summary: Go-lang bingding for dde-daemon
|
||||||
License: GPLv3+
|
License: GPLv3+
|
||||||
URL: https://github.com/linuxdeepin/dde-api
|
URL: https://shuttle.corp.deepin.com/cache/tasks/19177/unstable-amd64/
|
||||||
Source0: %{name}-%{version}.tar.gz
|
Source0: %{name}_%{version}-%{release_name}.orig.tar.xz
|
||||||
|
Patch1: deepin-api_makefile.patch
|
||||||
|
|
||||||
BuildRequires: git
|
|
||||||
BuildRequires: libcanberra-devel
|
BuildRequires: libcanberra-devel
|
||||||
BuildRequires: deepin-gettext-tools
|
BuildRequires: deepin-gettext-tools
|
||||||
BuildRequires: librsvg2-devel
|
BuildRequires: librsvg2-devel
|
||||||
BuildRequires: sqlite-devel
|
BuildRequires: sqlite-devel
|
||||||
BuildRequires: compiler(go-compiler)
|
BuildRequires: golang
|
||||||
BuildRequires: golang-github-linuxdeepin-go-x11-client-devel
|
|
||||||
BuildRequires: gdk-pixbuf2-xlib-devel
|
BuildRequires: gdk-pixbuf2-xlib-devel
|
||||||
BuildRequires: kf5-kwayland-devel
|
BuildRequires: kf5-kwayland-devel
|
||||||
BuildRequires: poppler-glib
|
BuildRequires: poppler-glib
|
||||||
@ -41,13 +38,6 @@ BuildRequires: poppler-glib-devel
|
|||||||
BuildRequires: alsa-lib-devel
|
BuildRequires: alsa-lib-devel
|
||||||
BuildRequires: alsa-lib
|
BuildRequires: alsa-lib
|
||||||
BuildRequires: pulseaudio-libs-devel
|
BuildRequires: pulseaudio-libs-devel
|
||||||
|
|
||||||
BuildRequires: gocode
|
|
||||||
|
|
||||||
BuildRequires: go-gir-generator
|
|
||||||
BuildRequires: golang-github-linuxdeepin-go-dbus-factory-devel
|
|
||||||
BuildRequires: go-lib-devel
|
|
||||||
BuildRequires: libgudev-devel
|
|
||||||
%{?systemd_requires}
|
%{?systemd_requires}
|
||||||
Requires: deepin-desktop-base
|
Requires: deepin-desktop-base
|
||||||
Requires: rfkill
|
Requires: rfkill
|
||||||
@ -68,7 +58,7 @@ building other packages which use import path with
|
|||||||
%{goipath} prefix.
|
%{goipath} prefix.
|
||||||
|
|
||||||
%prep
|
%prep
|
||||||
%forgeautosetup -p1 -n %{name}-%{version}
|
%forgeautosetup -p1 -n %{name}-%{version}-%{release_name}
|
||||||
|
|
||||||
sed -i 's|/usr/lib|%{_libexecdir}|' misc/*services/*.service \
|
sed -i 's|/usr/lib|%{_libexecdir}|' misc/*services/*.service \
|
||||||
misc/systemd/system/deepin-shutdown-sound.service \
|
misc/systemd/system/deepin-shutdown-sound.service \
|
||||||
@ -80,24 +70,26 @@ sed -i 's|PREFIX}${libdir|LIBDIR|; s|libdir|LIBDIR|' \
|
|||||||
Makefile adjust-grub-theme/main.go
|
Makefile adjust-grub-theme/main.go
|
||||||
|
|
||||||
%build
|
%build
|
||||||
%ifarch loongarch64
|
%gobuildroot
|
||||||
export CGO_ENABLED=1
|
for cmd in $(make binaries); do
|
||||||
export GOOS="linux"
|
GOPATH=/usr/share/gocode:%{_builddir}/%{name}-%{version}-%{release_name}/vendor:$GOPATH
|
||||||
%endif
|
go build -mod=vendor -o _bin/$cmd %{goipath}/$cmd
|
||||||
|
done
|
||||||
export GOPATH=/usr/share/gocode/:$GOPATH
|
|
||||||
%make_build
|
%make_build
|
||||||
|
|
||||||
%install
|
%install
|
||||||
for file in $(find . -iname "*.go" -o -iname "*.c" -o -iname "*.h" -o -iname "*.s"); do
|
rm -rf $(make binaries)
|
||||||
install -d -p %{buildroot}/%{gopath}/src/%{goipath}/$(dirname $file)
|
gofiles=$(find $(make libraries) %{?gofindfilter} -print)
|
||||||
cp -pav $file %{buildroot}/%{gopath}/src/%{goipath}/$file
|
%goinstall $gofiles
|
||||||
echo "%{gopath}/src/%{goipath}/$file" >> devel.file-list
|
|
||||||
done
|
|
||||||
%make_install SYSTEMD_SERVICE_DIR="%{_unitdir}" LIBDIR="%{_libexecdir}"
|
%make_install SYSTEMD_SERVICE_DIR="%{_unitdir}" LIBDIR="%{_libexecdir}"
|
||||||
# HOME directory for user deepin-sound-player
|
# HOME directory for user deepin-sound-player
|
||||||
mkdir -p %{buildroot}%{_sharedstatedir}/deepin-sound-player
|
mkdir -p %{buildroot}%{_sharedstatedir}/deepin-sound-player
|
||||||
|
|
||||||
|
%if %{with check}
|
||||||
|
%check
|
||||||
|
%gochecks
|
||||||
|
%endif
|
||||||
|
|
||||||
%pre
|
%pre
|
||||||
getent group deepin-sound-player >/dev/null || groupadd -r deepin-sound-player
|
getent group deepin-sound-player >/dev/null || groupadd -r deepin-sound-player
|
||||||
getent passwd deepin-sound-player >/dev/null || \
|
getent passwd deepin-sound-player >/dev/null || \
|
||||||
@ -135,29 +127,13 @@ exit 0
|
|||||||
%attr(-, deepin-sound-player, deepin-sound-player) %{_sharedstatedir}/deepin-sound-player
|
%attr(-, deepin-sound-player, deepin-sound-player) %{_sharedstatedir}/deepin-sound-player
|
||||||
|
|
||||||
%files -n %{name}-devel -f devel.file-list
|
%files -n %{name}-devel -f devel.file-list
|
||||||
%{_datadir}/gocode/src/%{goipath}/*
|
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
* Wed Feb 28 2024 liuzhilin <liuzhilin@uniontech.com> - 5.4.30-3
|
|
||||||
- fix source url in spec
|
|
||||||
|
|
||||||
* Tue Nov 21 2023 hanshuang <hanshuang@uniontech.com> - 5.4.30-2
|
|
||||||
- update package
|
|
||||||
|
|
||||||
* Thu Sep 3 2020 weidong <weidong@uniontech.com> - 5.1.11.1-6
|
|
||||||
- fix source url in spec
|
|
||||||
|
|
||||||
* Wed Sep 2 2020 chenbo pan <panchenbo@uniontech.com> - 5.1.11.1-5
|
|
||||||
- remove dde-api-devel
|
|
||||||
|
|
||||||
* Wed Sep 2 2020 chenbo pan <panchenbo@uniontech.com> - 5.1.11.1-4
|
* Wed Sep 2 2020 chenbo pan <panchenbo@uniontech.com> - 5.1.11.1-4
|
||||||
- remove install golang devel
|
- remove install golang devel
|
||||||
|
|
||||||
* Tue Aug 18 2020 chenbo pan <panchenbo@uniontech.com> - 5.1.11.1-3
|
* Tue Aug 18 2020 chenbo pan <panchenbo@uniontech.com> - 5.1.11.1-3
|
||||||
- remove golang devel
|
- remove golang devel
|
||||||
|
|
||||||
* Thu Jul 30 2020 openEuler Buildteam <buildteam@openeuler.org> - 5.1.11.1-2
|
* Thu Jul 30 2020 openEuler Buildteam <buildteam@openeuler.org> - 5.1.11.1-2
|
||||||
- fix spec
|
- fix spec
|
||||||
|
|
||||||
* Thu Jul 30 2020 openEuler Buildteam <buildteam@openeuler.org> - 5.1.11.1-1
|
* Thu Jul 30 2020 openEuler Buildteam <buildteam@openeuler.org> - 5.1.11.1-1
|
||||||
- Package init
|
- Package init
|
||||||
|
|||||||
BIN
dde-api-5.4.30.tar.gz → dde-api_5.1.11.1-server-industry.orig.tar.xz
Normal file → Executable file
BIN
dde-api-5.4.30.tar.gz → dde-api_5.1.11.1-server-industry.orig.tar.xz
Normal file → Executable file
Binary file not shown.
58
deepin-api_makefile.patch
Normal file
58
deepin-api_makefile.patch
Normal file
@ -0,0 +1,58 @@
|
|||||||
|
--- a/Makefile 2020-03-22 23:45:53.000000000 +0800
|
||||||
|
+++ b/Makefile 2020-04-27 20:28:02.391864563 +0800
|
||||||
|
@@ -2,8 +2,8 @@
|
||||||
|
GOBUILD_DIR = gobuild
|
||||||
|
GOPKG_PREFIX = pkg.deepin.io/dde/api
|
||||||
|
GOSITE_DIR = ${PREFIX}/share/gocode
|
||||||
|
-libdir = /lib
|
||||||
|
-SYSTEMD_LIB_DIR = ${libdir}
|
||||||
|
+LIBDIR = /lib
|
||||||
|
+SYSTEMD_LIB_DIR = ${LIBDIR}
|
||||||
|
SYSTEMD_SERVICE_DIR = ${SYSTEMD_LIB_DIR}/systemd/system/
|
||||||
|
GOBUILD = env GOPATH="${CURDIR}/${GOBUILD_DIR}:${GOPATH}" go build -mod=vendor
|
||||||
|
|
||||||
|
@@ -38,7 +38,7 @@
|
||||||
|
image-blur \
|
||||||
|
image-blur-helper
|
||||||
|
|
||||||
|
-all: build-binary build-dev ts-to-policy
|
||||||
|
+all: ts-to-policy
|
||||||
|
|
||||||
|
prepare:
|
||||||
|
@if [ ! -d ${GOBUILD_DIR}/src/${GOPKG_PREFIX} ]; then \
|
||||||
|
@@ -66,12 +66,12 @@
|
||||||
|
build-binary: prepare $(addprefix out/bin/, ${BINARIES})
|
||||||
|
|
||||||
|
install-binary:
|
||||||
|
- mkdir -pv ${DESTDIR}${PREFIX}${libdir}/deepin-api
|
||||||
|
- cp out/bin/* ${DESTDIR}${PREFIX}${libdir}/deepin-api/
|
||||||
|
+ mkdir -pv ${DESTDIR}${LIBDIR}/deepin-api
|
||||||
|
+ cp _bin/* ${DESTDIR}${LIBDIR}/deepin-api/
|
||||||
|
|
||||||
|
mkdir -pv ${DESTDIR}${PREFIX}/bin
|
||||||
|
- cp out/bin/dde-open ${DESTDIR}${PREFIX}/bin
|
||||||
|
- rm ${DESTDIR}${PREFIX}${libdir}/deepin-api/dde-open
|
||||||
|
+ cp _bin/dde-open ${DESTDIR}${PREFIX}/bin
|
||||||
|
+ rm ${DESTDIR}${LIBDIR}/deepin-api/dde-open
|
||||||
|
|
||||||
|
mkdir -pv ${DESTDIR}${PREFIX}/share/dbus-1/system.d
|
||||||
|
cp misc/conf/*.conf ${DESTDIR}${PREFIX}/share/dbus-1/system.d/
|
||||||
|
@@ -106,7 +106,8 @@
|
||||||
|
|
||||||
|
install-dev: ${addprefix install/lib/, ${LIBRARIES}}
|
||||||
|
|
||||||
|
-install: install-binary install-dev
|
||||||
|
+install: install-binary
|
||||||
|
+
|
||||||
|
|
||||||
|
clean:
|
||||||
|
rm -rf out/bin gobuild out
|
||||||
|
@@ -118,3 +119,8 @@
|
||||||
|
|
||||||
|
test: prepare
|
||||||
|
env GOPATH="${CURDIR}/${GOBUILD_DIR}:${GOPATH}" go test -v ./...
|
||||||
|
+binaries:
|
||||||
|
+ @echo ${BINARIES}
|
||||||
|
+
|
||||||
|
+libraries:
|
||||||
|
+ @echo ${LIBRARIES}
|
||||||
Loading…
x
Reference in New Issue
Block a user