Uniformize package Makefile, move ipkg related files to ./ipkg and patches to ./patches
[openwrt.git] / obsolete-buildroot / make / bash.mk
1 #############################################################
2 #
3 # bash
4 #
5 #############################################################
6 BASH_SOURCE:=bash-2.05b.tar.gz
7 BASH_SITE:=ftp://ftp.gnu.org/gnu/bash
8 BASH_CAT:=zcat
9 BASH_DIR:=$(BUILD_DIR)/bash-2.05b
10 BASH_BINARY:=bash
11 BASH_TARGET_BINARY:=bin/bash
12
13 $(DL_DIR)/$(BASH_SOURCE):
14 $(WGET) -P $(DL_DIR) $(BASH_SITE)/$(BASH_SOURCE)
15
16 bash-source: $(DL_DIR)/$(BASH_SOURCE)
17
18 $(BASH_DIR)/.unpacked: $(DL_DIR)/$(BASH_SOURCE)
19 $(BASH_CAT) $(DL_DIR)/$(BASH_SOURCE) | tar -C $(BUILD_DIR) -xvf -
20 # This is broken when -lintl is added to LIBS
21 $(SED) 's,LIBS_FOR_BUILD =.*,LIBS_FOR_BUILD =,g' \
22 $(BASH_DIR)/builtins/Makefile.in
23 touch $(BASH_DIR)/.unpacked
24
25 $(BASH_DIR)/.configured: $(BASH_DIR)/.unpacked
26 (cd $(BASH_DIR); rm -rf config.cache; \
27 $(TARGET_CONFIGURE_OPTS) CC_FOR_BUILD=$(HOSTCC) \
28 CFLAGS="$(TARGET_CFLAGS)" \
29 ac_cv_func_setvbuf_reversed=no \
30 bash_cv_have_mbstate_t=yes \
31 ./configure \
32 --target=$(GNU_TARGET_NAME) \
33 --host=$(GNU_TARGET_NAME) \
34 --build=$(GNU_HOST_NAME) \
35 --prefix=/usr \
36 --exec-prefix=/usr \
37 --bindir=/usr/bin \
38 --sbindir=/usr/sbin \
39 --libexecdir=/usr/lib \
40 --sysconfdir=/etc \
41 --datadir=/usr/share \
42 --localstatedir=/var \
43 --mandir=/usr/man \
44 --infodir=/usr/info \
45 $(DISABLE_NLS) \
46 $(DISABLE_LARGEFILE) \
47 --with-curses \
48 --enable-alias \
49 );
50 touch $(BASH_DIR)/.configured
51
52 $(BASH_DIR)/$(BASH_BINARY): $(BASH_DIR)/.configured
53 $(MAKE) CC=$(TARGET_CC) CC_FOR_BUILD=$(HOSTCC) -C $(BASH_DIR)
54
55 $(TARGET_DIR)/$(BASH_TARGET_BINARY): $(BASH_DIR)/$(BASH_BINARY)
56 $(MAKE) DESTDIR=$(TARGET_DIR) CC=$(TARGET_CC) -C $(BASH_DIR) install
57 rm -f $(TARGET_DIR)/bin/bash*
58 mv $(TARGET_DIR)/usr/bin/bash* $(TARGET_DIR)/bin/
59 (cd $(TARGET_DIR)/bin; ln -fs bash sh)
60 rm -rf $(TARGET_DIR)/share/locale $(TARGET_DIR)/usr/info \
61 $(TARGET_DIR)/usr/man $(TARGET_DIR)/usr/share/doc
62
63 bash: ncurses uclibc $(TARGET_DIR)/$(BASH_TARGET_BINARY)
64
65 bash-clean:
66 $(MAKE) DESTDIR=$(TARGET_DIR) CC=$(TARGET_CC) -C $(BASH_DIR) uninstall
67 -$(MAKE) -C $(BASH_DIR) clean
68
69 bash-dirclean:
70 rm -rf $(BASH_DIR)
71
This page took 0.052969 seconds and 5 git commands to generate.