all lists on lists.proxmox.com
 help / color / mirror / Atom feed
* [pbs-devel] [PATCH proxmox-backup] build: use MultiArch paths for `make ..`
@ 2025-11-11 15:14 Fabian Grünbichler
  2025-11-12 10:18 ` Robert Obkircher
  0 siblings, 1 reply; 3+ messages in thread
From: Fabian Grünbichler @ 2025-11-11 15:14 UTC (permalink / raw)
  To: pbs-devel

instead of just when building a package, otherwise plain `make; sudo make
install` installs to the wrong paths..

Reported-by: Robert Obkircher <r.obkircher@proxmox.com>
Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
---
 Makefile     | 2 ++
 debian/rules | 8 ++------
 defines.mk   | 2 +-
 3 files changed, 5 insertions(+), 7 deletions(-)

diff --git a/Makefile b/Makefile
index 2012ae5d2..21b4440fc 100644
--- a/Makefile
+++ b/Makefile
@@ -1,5 +1,7 @@
 include /usr/share/dpkg/default.mk
 include /usr/share/rustc/architecture.mk
+
+export DEB_HOST_MULTIARCH
 include defines.mk
 
 PACKAGE := proxmox-backup
diff --git a/debian/rules b/debian/rules
index ab48cce19..4c73c4ebf 100755
--- a/debian/rules
+++ b/debian/rules
@@ -49,17 +49,13 @@ override_dh_auto_configure:
 	dh_auto_configure
 
 override_dh_auto_build:
-	dh_auto_build -- \
-	    PROXY_USER=backup \
-	    LIBDIR=/usr/lib/$(DEB_HOST_MULTIARCH)
+	dh_auto_build -- PROXY_USER=backup
 
 override_dh_missing:
 	dh_missing --fail-missing
 
 override_dh_auto_install:
-	dh_auto_install -- \
-	    PROXY_USER=backup \
-	    LIBDIR=/usr/lib/$(DEB_HOST_MULTIARCH)
+	dh_auto_install -- PROXY_USER=backup
 	mkdir -p debian/proxmox-backup-client-static/usr/bin
 	mv debian/tmp/usr/bin/proxmox-backup-client-static debian/proxmox-backup-client-static/usr/bin/proxmox-backup-client
 	mv debian/tmp/usr/bin/pxar-static debian/proxmox-backup-client-static/usr/bin/pxar
diff --git a/defines.mk b/defines.mk
index cd5b52a2a..7e550d5c2 100644
--- a/defines.mk
+++ b/defines.mk
@@ -1,7 +1,7 @@
 PREFIX = /usr
 BINDIR = $(PREFIX)/bin
 SBINDIR = $(PREFIX)/sbin
-LIBDIR = $(PREFIX)/lib
+LIBDIR = $(PREFIX)/lib/$(DEB_HOST_MULTIARCH)
 LIBEXECDIR = $(LIBDIR)
 DATAROOTDIR = $(PREFIX)/share
 MAN1DIR = $(PREFIX)/share/man/man1
-- 
2.47.3



_______________________________________________
pbs-devel mailing list
pbs-devel@lists.proxmox.com
https://lists.proxmox.com/cgi-bin/mailman/listinfo/pbs-devel

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [pbs-devel] [PATCH proxmox-backup] build: use MultiArch paths for `make ..`
  2025-11-11 15:14 [pbs-devel] [PATCH proxmox-backup] build: use MultiArch paths for `make ..` Fabian Grünbichler
@ 2025-11-12 10:18 ` Robert Obkircher
  2025-11-12 11:17   ` Fabian Grünbichler
  0 siblings, 1 reply; 3+ messages in thread
From: Robert Obkircher @ 2025-11-12 10:18 UTC (permalink / raw)
  To: Fabian Grünbichler, pbs-devel

I've tested this and the binaries are now installed in the right place.

However, if I run "make clean; make" in the etc subdirectory instead of 
the repository root, the substitutions in the .service files are:

ExecStart=/usr/lib//proxmox-backup/proxmox-backup-api

instead of

ExecStart=/usr/lib/x86_64-linux-gnu/proxmox-backup/proxmox-backup-api

Not sure if this is relevant, since they aren't used anyway.

On 11/11/25 16:15, Fabian Grünbichler wrote:
> instead of just when building a package, otherwise plain `make; sudo make
> install` installs to the wrong paths..
>
> Reported-by: Robert Obkircher <r.obkircher@proxmox.com>
> Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
> ---
>   Makefile     | 2 ++
>   debian/rules | 8 ++------
>   defines.mk   | 2 +-
>   3 files changed, 5 insertions(+), 7 deletions(-)
>
> diff --git a/Makefile b/Makefile
> index 2012ae5d2..21b4440fc 100644
> --- a/Makefile
> +++ b/Makefile
> @@ -1,5 +1,7 @@
>   include /usr/share/dpkg/default.mk
>   include /usr/share/rustc/architecture.mk
> +
> +export DEB_HOST_MULTIARCH
>   include defines.mk
>   
>   PACKAGE := proxmox-backup
> diff --git a/debian/rules b/debian/rules
> index ab48cce19..4c73c4ebf 100755
> --- a/debian/rules
> +++ b/debian/rules
> @@ -49,17 +49,13 @@ override_dh_auto_configure:
>   	dh_auto_configure
>   
>   override_dh_auto_build:
> -	dh_auto_build -- \
> -	    PROXY_USER=backup \
> -	    LIBDIR=/usr/lib/$(DEB_HOST_MULTIARCH)
> +	dh_auto_build -- PROXY_USER=backup
>   
>   override_dh_missing:
>   	dh_missing --fail-missing
>   
>   override_dh_auto_install:
> -	dh_auto_install -- \
> -	    PROXY_USER=backup \
> -	    LIBDIR=/usr/lib/$(DEB_HOST_MULTIARCH)
> +	dh_auto_install -- PROXY_USER=backup
>   	mkdir -p debian/proxmox-backup-client-static/usr/bin
>   	mv debian/tmp/usr/bin/proxmox-backup-client-static debian/proxmox-backup-client-static/usr/bin/proxmox-backup-client
>   	mv debian/tmp/usr/bin/pxar-static debian/proxmox-backup-client-static/usr/bin/pxar
> diff --git a/defines.mk b/defines.mk
> index cd5b52a2a..7e550d5c2 100644
> --- a/defines.mk
> +++ b/defines.mk
> @@ -1,7 +1,7 @@
>   PREFIX = /usr
>   BINDIR = $(PREFIX)/bin
>   SBINDIR = $(PREFIX)/sbin
> -LIBDIR = $(PREFIX)/lib
> +LIBDIR = $(PREFIX)/lib/$(DEB_HOST_MULTIARCH)
>   LIBEXECDIR = $(LIBDIR)
>   DATAROOTDIR = $(PREFIX)/share
>   MAN1DIR = $(PREFIX)/share/man/man1


_______________________________________________
pbs-devel mailing list
pbs-devel@lists.proxmox.com
https://lists.proxmox.com/cgi-bin/mailman/listinfo/pbs-devel

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [pbs-devel] [PATCH proxmox-backup] build: use MultiArch paths for `make ..`
  2025-11-12 10:18 ` Robert Obkircher
@ 2025-11-12 11:17   ` Fabian Grünbichler
  0 siblings, 0 replies; 3+ messages in thread
From: Fabian Grünbichler @ 2025-11-12 11:17 UTC (permalink / raw)
  To: pbs-devel, Robert Obkircher

On November 12, 2025 11:18 am, Robert Obkircher wrote:
> I've tested this and the binaries are now installed in the right place.
> 
> However, if I run "make clean; make" in the etc subdirectory instead of 
> the repository root, the substitutions in the .service files are:
> 
> ExecStart=/usr/lib//proxmox-backup/proxmox-backup-api
> 
> instead of
> 
> ExecStart=/usr/lib/x86_64-linux-gnu/proxmox-backup/proxmox-backup-api
> 
> Not sure if this is relevant, since they aren't used anyway.

we could move the include of /usr/share/dpkg/architecture.mk into
defines.mk, it should be cached anyway so shouldn't make anything more
expensive.. then we don't need to export the variable anywhere either

> 
> On 11/11/25 16:15, Fabian Grünbichler wrote:
>> instead of just when building a package, otherwise plain `make; sudo make
>> install` installs to the wrong paths..
>>
>> Reported-by: Robert Obkircher <r.obkircher@proxmox.com>
>> Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
>> ---
>>   Makefile     | 2 ++
>>   debian/rules | 8 ++------
>>   defines.mk   | 2 +-
>>   3 files changed, 5 insertions(+), 7 deletions(-)
>>
>> diff --git a/Makefile b/Makefile
>> index 2012ae5d2..21b4440fc 100644
>> --- a/Makefile
>> +++ b/Makefile
>> @@ -1,5 +1,7 @@
>>   include /usr/share/dpkg/default.mk
>>   include /usr/share/rustc/architecture.mk
>> +
>> +export DEB_HOST_MULTIARCH
>>   include defines.mk
>>   
>>   PACKAGE := proxmox-backup
>> diff --git a/debian/rules b/debian/rules
>> index ab48cce19..4c73c4ebf 100755
>> --- a/debian/rules
>> +++ b/debian/rules
>> @@ -49,17 +49,13 @@ override_dh_auto_configure:
>>   	dh_auto_configure
>>   
>>   override_dh_auto_build:
>> -	dh_auto_build -- \
>> -	    PROXY_USER=backup \
>> -	    LIBDIR=/usr/lib/$(DEB_HOST_MULTIARCH)
>> +	dh_auto_build -- PROXY_USER=backup
>>   
>>   override_dh_missing:
>>   	dh_missing --fail-missing
>>   
>>   override_dh_auto_install:
>> -	dh_auto_install -- \
>> -	    PROXY_USER=backup \
>> -	    LIBDIR=/usr/lib/$(DEB_HOST_MULTIARCH)
>> +	dh_auto_install -- PROXY_USER=backup
>>   	mkdir -p debian/proxmox-backup-client-static/usr/bin
>>   	mv debian/tmp/usr/bin/proxmox-backup-client-static debian/proxmox-backup-client-static/usr/bin/proxmox-backup-client
>>   	mv debian/tmp/usr/bin/pxar-static debian/proxmox-backup-client-static/usr/bin/pxar
>> diff --git a/defines.mk b/defines.mk
>> index cd5b52a2a..7e550d5c2 100644
>> --- a/defines.mk
>> +++ b/defines.mk
>> @@ -1,7 +1,7 @@
>>   PREFIX = /usr
>>   BINDIR = $(PREFIX)/bin
>>   SBINDIR = $(PREFIX)/sbin
>> -LIBDIR = $(PREFIX)/lib
>> +LIBDIR = $(PREFIX)/lib/$(DEB_HOST_MULTIARCH)
>>   LIBEXECDIR = $(LIBDIR)
>>   DATAROOTDIR = $(PREFIX)/share
>>   MAN1DIR = $(PREFIX)/share/man/man1
> 


_______________________________________________
pbs-devel mailing list
pbs-devel@lists.proxmox.com
https://lists.proxmox.com/cgi-bin/mailman/listinfo/pbs-devel

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2025-11-12 11:17 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2025-11-11 15:14 [pbs-devel] [PATCH proxmox-backup] build: use MultiArch paths for `make ..` Fabian Grünbichler
2025-11-12 10:18 ` Robert Obkircher
2025-11-12 11:17   ` Fabian Grünbichler

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.
Service provided by Proxmox Server Solutions GmbH | Privacy | Legal