xref: /OK3568_Linux_fs/buildroot/package/ncftp/ncftp.mk (revision 4882a59341e53eb6f0b4789bf948001014eff981)
1*4882a593Smuzhiyun################################################################################
2*4882a593Smuzhiyun#
3*4882a593Smuzhiyun# ncftp
4*4882a593Smuzhiyun#
5*4882a593Smuzhiyun################################################################################
6*4882a593Smuzhiyun
7*4882a593SmuzhiyunNCFTP_VERSION = 3.2.6
8*4882a593Smuzhiyun# use .gz as upstream .xz tarball has changed after the hash was added for
9*4882a593Smuzhiyun# 2017.02. Can be changed back to .xz when version is bumped
10*4882a593SmuzhiyunNCFTP_SOURCE = ncftp-$(NCFTP_VERSION)-src.tar.gz
11*4882a593SmuzhiyunNCFTP_SITE = ftp://ftp.ncftp.com/ncftp
12*4882a593SmuzhiyunNCFTP_TARGET_BINS = ncftp
13*4882a593SmuzhiyunNCFTP_LICENSE = Clarified Artistic License
14*4882a593SmuzhiyunNCFTP_LICENSE_FILES = doc/LICENSE.txt
15*4882a593Smuzhiyun
16*4882a593SmuzhiyunNCFTP_DEPENDENCIES = host-autoconf
17*4882a593SmuzhiyunNCFTP_CONF_OPTS = --disable-ccdv
18*4882a593Smuzhiyun
19*4882a593Smuzhiyun# The bundled configure script is generated by autoconf 2.13 and doesn't
20*4882a593Smuzhiyun# detect cross-compilation correctly. Therefore, we have to regenerate it.
21*4882a593Smuzhiyun# We need to pass -I because of the non-standard m4 directory name, and
22*4882a593Smuzhiyun# none of the other autotools are used, so the below is the easiest.
23*4882a593Smuzhiyundefine NCFTP_RUN_AUTOCONF
24*4882a593Smuzhiyun	(cd $(@D); $(AUTOCONF) -I$(@D)/autoconf_local/)
25*4882a593Smuzhiyunendef
26*4882a593SmuzhiyunNCFTP_PRE_CONFIGURE_HOOKS += NCFTP_RUN_AUTOCONF
27*4882a593Smuzhiyun
28*4882a593Smuzhiyunifeq ($(BR2_PACKAGE_NCFTP_GET),y)
29*4882a593SmuzhiyunNCFTP_TARGET_BINS += ncftpget
30*4882a593Smuzhiyunendif
31*4882a593Smuzhiyun
32*4882a593Smuzhiyunifeq ($(BR2_PACKAGE_NCFTP_PUT),y)
33*4882a593SmuzhiyunNCFTP_TARGET_BINS += ncftpput
34*4882a593Smuzhiyunendif
35*4882a593Smuzhiyun
36*4882a593Smuzhiyunifeq ($(BR2_PACKAGE_NCFTP_LS),y)
37*4882a593SmuzhiyunNCFTP_TARGET_BINS += ncftpls
38*4882a593Smuzhiyunendif
39*4882a593Smuzhiyun
40*4882a593Smuzhiyunifeq ($(BR2_PACKAGE_NCFTP_BATCH),y)
41*4882a593SmuzhiyunNCFTP_TARGET_BINS += ncftpbatch
42*4882a593SmuzhiyunNCFTP_INSTALL_NCFTP_BATCH = \
43*4882a593Smuzhiyun	ln -sf /usr/bin/ncftpbatch $(TARGET_DIR)/usr/bin/ncftpspooler
44*4882a593Smuzhiyunendif
45*4882a593Smuzhiyun
46*4882a593Smuzhiyunifeq ($(BR2_PACKAGE_NCFTP_BOOKMARKS),y)
47*4882a593SmuzhiyunNCFTP_TARGET_BINS += ncftpbookmarks
48*4882a593SmuzhiyunNCFTP_DEPENDENCIES += ncurses
49*4882a593Smuzhiyunendif
50*4882a593Smuzhiyun
51*4882a593Smuzhiyundefine NCFTP_INSTALL_TARGET_CMDS
52*4882a593Smuzhiyun	$(INSTALL) -m 0755 $(addprefix $(NCFTP_DIR)/bin/, $(NCFTP_TARGET_BINS)) $(TARGET_DIR)/usr/bin
53*4882a593Smuzhiyun	$(NCFTP_INSTALL_NCFTP_BATCH)
54*4882a593Smuzhiyunendef
55*4882a593Smuzhiyun
56*4882a593Smuzhiyun$(eval $(autotools-package))
57