1 #############################################################
3 # lrzsz (provides zmodem)
5 #############################################################
6 # Copyright (C) 2001-2003 by Erik Andersen <andersen@codepoet.org>
7 # Copyright (C) 2002 by Tim Riker <Tim@Rikers.org>
9 # This program is free software; you can redistribute it and/or modify
10 # it under the terms of the GNU Library General Public License as
11 # published by the Free Software Foundation; either version 2 of the
12 # License, or (at your option) any later version.
14 # This program is distributed in the hope that it will be useful, but
15 # WITHOUT ANY WARRANTY; without even the implied warranty of
16 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
17 # Library General Public License for more details.
19 # You should have received a copy of the GNU Library General Public
20 # License along with this program; if not, write to the Free Software
21 # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
24 LRZSZ_SITE:=http://www.ohse.de/uwe/releases
25 LRZSZ_SOURCE:=lrzsz-0.12.20.tar.gz
26 LRZSZ_DIR:=$(BUILD_DIR)/lrzsz-0.12.20
28 $(DL_DIR)/$(LRZSZ_SOURCE):
29 $(WGET) -P $(DL_DIR) $(LRZSZ_SITE)/$(LRZSZ_SOURCE)
31 lrzsz-source: $(DL_DIR)/$(LRZSZ_SOURCE)
33 $(LRZSZ_DIR)/.unpacked: $(DL_DIR)/$(LRZSZ_SOURCE)
34 zcat $(DL_DIR)/$(LRZSZ_SOURCE) | tar -C $(BUILD_DIR) -xvf -
35 touch $(LRZSZ_DIR)/.unpacked
37 $(LRZSZ_DIR)/.configured: $(LRZSZ_DIR)/.unpacked
38 (cd $(LRZSZ_DIR); rm -rf config.cache; \
39 $(TARGET_CONFIGURE_OPTS) \
41 --target=$(GNU_TARGET_NAME) \
42 --host=$(GNU_TARGET_NAME) \
43 --build=$(GNU_HOST_NAME) \
48 --libexecdir=/usr/lib \
50 --datadir=/usr/share \
51 --localstatedir=/tmp \
57 $(SED) "s/-lnsl//;" $(LRZSZ_DIR)/src/Makefile
58 $(SED) "s~\(#define ENABLE_SYSLOG.*\)~/* \1 */~;" $(LRZSZ_DIR)/config.h
59 touch $(LRZSZ_DIR)/.configured
61 $(LRZSZ_DIR)/src/lrz: $(LRZSZ_DIR)/.configured
62 $(MAKE) CROSS_COMPILE="$(TARGET_CROSS)" prefix="$(TARGET_DIR)" -C $(LRZSZ_DIR)
63 $(STRIP) $(LRZSZ_DIR)/src/lrz $(LRZSZ_DIR)/src/lsz
65 $(TARGET_DIR)/usr/bin/rz: $(LRZSZ_DIR)/src/lrz
66 cp $(LRZSZ_DIR)/src/lrz $(TARGET_DIR)/usr/bin/rz
67 cp $(LRZSZ_DIR)/src/lsz $(TARGET_DIR)/usr/bin/sz
69 lrzsz: uclibc $(TARGET_DIR)/usr/bin/rz
72 rm -f $(TARGET_DIR)/usr/bin/rz
73 -$(MAKE) -C $(LRZSZ_DIR) clean