]> git.proxmox.com Git - rustc.git/blob - debian/architecture.mk
Update upstream source from tag 'upstream/1.33.0+dfsg1'
[rustc.git] / debian / architecture.mk
1 # This Makefile snippet defines DEB_*_RUST_TYPE triples based on DEB_*_GNU_TYPE
2
3 include /usr/share/dpkg/architecture.mk
4
5 rust_cpu = $(subst i586,i686,\
6 $(if $(findstring -armhf-,-$(2)-),$(subst arm,armv7,$(1)),\
7 $(if $(findstring -armel-,-$(2)-),$(subst arm,armv5te,$(1)),\
8 $(1))))
9 rust_type_setvar = $(1)_RUST_TYPE ?= $(call rust_cpu,$($(1)_GNU_CPU),$($(1)_ARCH))-unknown-$($(1)_GNU_SYSTEM)
10
11 $(foreach machine,BUILD HOST TARGET,\
12 $(eval $(call rust_type_setvar,DEB_$(machine))))
13
14 # fallback for older dpkg versions
15 ifeq ($(DEB_TARGET_RUST_TYPE),-unknown-)
16 DEB_TARGET_RUST_TYPE = $(DEB_HOST_RUST_TYPE)
17 endif