1 ################################################################################
5 ################################################################################
8 DTC_SOURCE
= dtc-
$(DTC_VERSION
).
tar.xz
9 DTC_SITE
= https
://www.kernel.org
/pub
/software
/utils
/dtc
10 DTC_LICENSE
= GPLv2
+/BSD-2c
11 DTC_LICENSE_FILES
= README.license GPL
12 DTC_INSTALL_STAGING
= YES
13 DTC_DEPENDENCIES
= host-bison host-flex
14 HOST_DTC_DEPENDENCIES
= host-bison host-flex
16 define DTC_POST_INSTALL_TARGET_RM_DTDIFF
17 rm -f
$(TARGET_DIR
)/usr
/bin
/dtdiff
20 ifeq ($(BR2_PACKAGE_DTC_PROGRAMS
),y
)
22 DTC_LICENSE
+= (for the library
), GPLv2
+ (for the executables
)
23 DTC_INSTALL_GOAL
= install
24 ifeq ($(BR2_PACKAGE_BASH
),)
25 DTC_POST_INSTALL_TARGET_HOOKS
+= DTC_POST_INSTALL_TARGET_RM_DTDIFF
28 else # $(BR2_PACKAGE_DTC_PROGRAMS) != y
30 DTC_INSTALL_GOAL
= install-lib
32 endif # $(BR2_PACKAGE_DTC_PROGRAMS) != y
35 $(TARGET_CONFIGURE_OPTS
) $(MAKE
) -C
$(@D
) PREFIX
=/usr
38 # For staging, only the library is needed
39 define DTC_INSTALL_STAGING_CMDS
40 $(MAKE
) -C
$(@D
) DESTDIR
=$(STAGING_DIR
) PREFIX
=/usr install-lib \
44 define DTC_INSTALL_TARGET_CMDS
45 $(MAKE
) -C
$(@D
) DESTDIR
=$(TARGET_DIR
) PREFIX
=/usr
$(DTC_INSTALL_GOAL
)
49 define HOST_DTC_BUILD_CMDS
50 $(HOST_CONFIGURE_OPTS
) $(MAKE
) -C
$(@D
) PREFIX
=$(HOST_DIR
)/usr
53 define HOST_DTC_INSTALL_CMDS
54 $(MAKE
) -C
$(@D
) PREFIX
=$(HOST_DIR
)/usr install-bin
57 $(eval
$(generic-package
))
58 $(eval
$(host-generic-package
))