2 # Copyright (C) 2006 OpenWrt.org
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
11 CATEGORY
:=Extra packages
15 MAINTAINER
:=OpenWrt Developers Team
<openwrt-devel@openwrt.org
>
16 SOURCE
:=$(patsubst $(TOPDIR
)/%,%,${shell pwd
})
17 ifneq ($(PKG_VERSION
),)
18 ifneq ($(PKG_RELEASE
),)
19 VERSION
:=$(PKG_VERSION
)-$(PKG_RELEASE
)
21 VERSION
:=$(PKG_VERSION
)
24 VERSION
:=$(PKG_RELEASE
)
37 Build
/Patch
:=$(Build
/Patch
/Default
)
38 ifneq ($(strip $(PKG_UNPACK
)),)
39 define Build
/Prepare
/Default
42 $(if
$(QUILT
),touch
$(PKG_BUILD_DIR
)/.quilt_used
)
47 --target
=$(GNU_TARGET_NAME
) \
48 --host
=$(GNU_TARGET_NAME
) \
49 --build
=$(GNU_HOST_NAME
) \
56 --libexecdir
=/usr
/lib \
58 --datadir=/usr
/share \
59 --localstatedir
=/var \
65 $(TARGET_CONFIGURE_OPTS
) \
66 CFLAGS
="$(TARGET_CFLAGS) $(EXTRA_CFLAGS)" \
67 CXXFLAGS
="$(TARGET_CFLAGS) $(EXTRA_CFLAGS)" \
68 CPPFLAGS
="$(TARGET_CPPFLAGS) $(EXTRA_CPPFLAGS)" \
69 LDFLAGS
="$(TARGET_LDFLAGS) $(EXTRA_LDFLAGS)" \
70 PKG_CONFIG_PATH
="$(STAGING_DIR)/usr/lib/pkgconfig" \
71 PKG_CONFIG_LIBDIR
="$(STAGING_DIR)/usr/lib/pkgconfig"
74 CONFIGURE_CMD
= .
/configure
76 define Build
/Configure
/Default
77 (cd
$(PKG_BUILD_DIR
)/$(CONFIGURE_PATH
)/$(strip $(3)); \
78 if
[ -x
$(CONFIGURE_CMD
) ]; then \
79 $(CP
) $(SCRIPT_DIR
)/config.
{guess
,sub
} $(PKG_BUILD_DIR
)/$(3)/ && \
90 CFLAGS
="$(TARGET_CFLAGS) $(EXTRA_CFLAGS) $(TARGET_CPPFLAGS) $(EXTRA_CPPFLAGS)" \
91 CXXFLAGS
="$(TARGET_CFLAGS) $(EXTRA_CFLAGS) $(TARGET_CPPFLAGS) $(EXTRA_CPPFLAGS)" \
92 LDFLAGS
="$(TARGET_LDFLAGS) $(EXTRA_LDFLAGS)"
95 $(TARGET_CONFIGURE_OPTS
) \
96 CROSS
="$(TARGET_CROSS)" \
101 define Build
/Compile
/Default
103 $(MAKE
) -C
$(PKG_BUILD_DIR
)/$(MAKE_PATH
) \