1 #############################################################
5 #############################################################
6 SETSERIAL_VERSION
:=2.17
7 SETSERIAL_PATCH_VERSION
:=.orig
8 SETSERIAL_PATCH_FILE
:=setserial_2.17
-45.diff.gz
9 SETSERIAL_SOURCE
:=setserial_
$(SETSERIAL_VERSION
)$(SETSERIAL_PATCH_VERSION
).
tar.gz
10 SETSERIAL_SITE
:=$(BR2_DEBIAN_MIRROR
)/debian
/pool
/main
/s
/setserial
/
11 SETSERIAL_DIR
:=$(BUILD_DIR
)/setserial-
$(SETSERIAL_VERSION
)
12 SETSERIAL_BINARY
:=setserial
13 SETSERIAL_TARGET_BINARY
:=usr
/bin
/setserial
15 $(DL_DIR
)/$(SETSERIAL_SOURCE
):
16 $(call DOWNLOAD
,$(SETSERIAL_SITE
),$(SETSERIAL_SOURCE
))
18 ifneq ($(SETSERIAL_PATCH_FILE
),)
19 SETSERIAL_PATCH
:=$(DL_DIR
)/$(SETSERIAL_PATCH_FILE
)
21 $(call DOWNLOAD
,$(SETSERIAL_SITE
),$(SETSERIAL_PATCH_FILE
))
26 $(SETSERIAL_DIR
)/.unpacked
: $(DL_DIR
)/$(SETSERIAL_SOURCE
) $(SETSERIAL_PATCH
)
27 $(ZCAT
) $(DL_DIR
)/$(SETSERIAL_SOURCE
) |
tar -C
$(BUILD_DIR
) $(TAR_OPTIONS
) -
28 $(CONFIG_UPDATE
) $(SETSERIAL_DIR
)
29 toolchain
/patch-kernel.sh
$(SETSERIAL_DIR
) package
/setserial setserial\
*.patch
30 ifneq ($(SETSERIAL_PATCH_FILE
),)
31 toolchain
/patch-kernel.sh
$(SETSERIAL_DIR
) $(DL_DIR
) $(SETSERIAL_PATCH_FILE
)
32 if
[ -d
$(SETSERIAL_DIR
)/debian
/patches
]; then \
33 toolchain
/patch-kernel.sh
$(SETSERIAL_DIR
) $(SETSERIAL_DIR
)/debian
/patches \
*.patch
; \
36 touch
$(SETSERIAL_DIR
)/gorhack.h
39 ifeq ($(BR2_PREFER_IMA
),y
)
40 SETSERIAL_CFLAGS
=$(CFLAGS_COMBINE
) $(CFLAGS_WHOLE_PROGRAM
)
43 $(SETSERIAL_DIR
)/.configured
: $(SETSERIAL_DIR
)/.unpacked
44 (cd
$(SETSERIAL_DIR
); rm -rf config.cache
; \
45 $(TARGET_CONFIGURE_OPTS
) \
46 $(TARGET_CONFIGURE_ARGS
) \
47 CFLAGS
="$(TARGET_CFLAGS) $(SETSERIAL_CFLAGS)" \
49 --target
=$(GNU_TARGET_NAME
) \
50 --host
=$(GNU_TARGET_NAME
) \
51 --build
=$(GNU_HOST_NAME
) \
57 $(SETSERIAL_DIR
)/$(SETSERIAL_BINARY
): $(SETSERIAL_DIR
)/.configured
58 $(MAKE
) CC
=$(TARGET_CC
) -C
$(SETSERIAL_DIR
)
60 $(TARGET_DIR
)/$(SETSERIAL_TARGET_BINARY
): $(SETSERIAL_DIR
)/$(SETSERIAL_BINARY
)
61 install -c
$(SETSERIAL_DIR
)/$(SETSERIAL_BINARY
) $(TARGET_DIR
)/$(SETSERIAL_TARGET_BINARY
)
62 $(STRIPCMD
) $(STRIP_STRIP_ALL
) $(TARGET_DIR
)/$(SETSERIAL_TARGET_BINARY
)
64 setserial
: uclibc
$(TARGET_DIR
)/$(SETSERIAL_TARGET_BINARY
)
66 setserial-source
: $(DL_DIR
)/$(SETSERIAL_SOURCE
) $(SETSERIAL_PATCH
)
68 setserial-unpacked
: $(SETSERIAL_DIR
)/.unpacked
71 rm -f
$(TARGET_DIR
)/$(SETSERIAL_TARGET_BINARY
)
72 -$(MAKE
) -C
$(SETSERIAL_DIR
) clean
75 rm -rf
$(SETSERIAL_DIR
)
77 #############################################################
79 # Toplevel Makefile options
81 #############################################################
82 ifeq ($(BR2_PACKAGE_SETSERIAL
),y
)