-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
69 lines (55 loc) · 2.28 KB
/
Makefile
File metadata and controls
69 lines (55 loc) · 2.28 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
# SPDX-License-Identifier: GPL-2.0-or-later
# Copyright (C) 2025 Tomas Paukrt
# list of main targets
all: armv7 aarch64
# settings for target architecture ARMv7-A (32-bit, soft-float)
armv7: armv7-all
armv7-%: TARGET_ARCH = arm
armv7-%: TARGET_MACH = arm-none-linux-gnueabi
armv7-%: TARGET_NAME = armv7-none-linux-gnueabi
armv7-%: TARGET_OPTS = --with-arch=armv7-a --with-fpu=vfpv3-d16 --with-float=softfp
# settings for target architecture ARMv7-A (32-bit, hard-float)
armv7hf: armv7hf-all
armv7hf-%: TARGET_ARCH = arm
armv7hf-%: TARGET_MACH = arm-none-linux-gnueabihf
armv7hf-%: TARGET_NAME = armv7-none-linux-gnueabihf
armv7hf-%: TARGET_OPTS = --with-arch=armv7-a --with-fpu=vfpv3-d16 --with-float=hard
# settings for target architecture ARMv8-A (64-bit)
aarch64: aarch64-all
aarch64-%: TARGET_ARCH = arm64
aarch64-%: TARGET_MACH = aarch64-none-linux-gnu
aarch64-%: TARGET_NAME = aarch64-none-linux-gnu
aarch64-%: TARGET_OPTS = --with-arch=armv8-a
# versions of source packages
VER_BINUTILS = 2.45
VER_GCC = 15.2.0
VER_GLIBC = 2.42
VER_LINUX = 5.15.1
# names of source packages
PKG_BINUTILS = binutils-$(VER_BINUTILS).tar.xz
PKG_GCC = gcc-$(VER_GCC).tar.xz
PKG_GLIBC = glibc-$(VER_GLIBC).tar.xz
PKG_KERNEL = linux-$(VER_LINUX).tar.xz
# locations of source packages
URL_BINUTILS = https://ftp.gnu.org/gnu/binutils
URL_GCC = https://ftp.gnu.org/gnu/gcc
URL_GLIBC = https://ftp.gnu.org/gnu/glibc
URL_KERNEL = https://www.kernel.org/pub/linux/kernel
# maintainer of DEB/RPM packages
MAINTAINER = Tomas Paukrt <tomaspaukrt@email.cz>
# release number of DEB/RPM packages
RELEASE_NUMBER = 1
# name of target toolchain
TOOLCHAIN_NAME = gcc-$(TARGET_NAME)
# installation path of target toolchain
TOOLCHAIN_PATH = /opt/toolchains/$(TOOLCHAIN_NAME)
# working directories
DIR_BUILD = $(abspath $(dir $(lastword $(MAKEFILE_LIST))))/build
DIR_DEB_ROOT = $(DIR_BUILD)/deb
DIR_RPM_ROOT = $(DIR_BUILD)/rpm
DIR_PACKAGES = packages
# auxiliary files
FILE_DEB_CTRL = $(DIR_DEB_ROOT)/DEBIAN/control
FILE_RPM_SPEC = $(DIR_RPM_ROOT)/../rpm.spec
# build rules
include Rules.mk