Package: netkit-ftp / 0.17-31

052_no_termcap_linking.diff Patch series | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
Description: Remove explicit termcap linking.
 Present day libreadline includes all needed
 linking with libtinfo, so no explicit linking
 either with libncurses or libtermcap is needed.
Author: Mats Erik Andersson <debian@gisladisker.se>
Forwarded: no
Last-Update: 2012-03-26

diff -Naurp netkit-ftp-0.17.debian/configure netkit-ftp-0.17/configure
--- netkit-ftp-0.17.debian/configure
+++ netkit-ftp-0.17/configure
@@ -187,61 +187,61 @@ rm -f __conftest*
 
 ##################################################
 
-echo -n 'Checking for ncurses... '
-cat <<EOF >__conftest.c
-#include <stdio.h>
-#include <curses.h>
-#ifndef KEY_DOWN
-syntax error. /* not ncurses */
-#endif
-int main() {
-    endwin();
-    return 0;
-}
-
-EOF
-if (
-      $CC $CFLAGS  __conftest.c -lncurses -o __conftest || exit 1
-   ) >/dev/null 2>&1; then
-    echo 'yes'
-    NCURSES=1
-else
-    if (
-          $CC $CFLAGS -I/usr/include/ncurses __conftest.c -lncurses -o __conftest || exit 1
-       ) >/dev/null 2>&1; then
-        echo '-I/usr/include/ncurses'
-        CFLAGS="$CFLAGS -I/usr/include/ncurses"
-        NCURSES=1
-    else
-        echo 'no'
-    fi
-fi
-
-if [ x$NCURSES != x ]; then
-    LIBTERMCAP=-lncurses
-else
-    echo -n 'Checking for traditional termcap... '
-cat <<EOF >__conftest.c
-#include <stdio.h>
-#include <termcap.h>
-int main() {
-    tgetent(NULL, NULL); return 0;
-}
-
-EOF
-    if (
-          $CC $CFLAGS  __conftest.c -ltermcap -o __conftest || exit 1
-       ) >/dev/null 2>&1; then
-        echo '-ltermcap'
-        LIBTERMCAP=-ltermcap
-    else
-        echo 'not found'
-        echo 'This package needs termcap to run.'
-        rm -f __conftest*
-        exit
-    fi
-fi
-rm -f __conftest*
+#echo -n 'Checking for ncurses... '
+#cat <<EOF >__conftest.c
+##include <stdio.h>
+##include <curses.h>
+##ifndef KEY_DOWN
+#syntax error. /* not ncurses */
+##endif
+#int main() {
+#    endwin();
+#    return 0;
+#}
+#
+#EOF
+#if (
+#      $CC $CFLAGS  __conftest.c -lncurses -o __conftest || exit 1
+#   ) >/dev/null 2>&1; then
+#    echo 'yes'
+#    NCURSES=1
+#else
+#    if (
+#          $CC $CFLAGS -I/usr/include/ncurses __conftest.c -lncurses -o __conftest || exit 1
+#       ) >/dev/null 2>&1; then
+#        echo '-I/usr/include/ncurses'
+#        CFLAGS="$CFLAGS -I/usr/include/ncurses"
+#        NCURSES=1
+#    else
+#        echo 'no'
+#    fi
+#fi
+#
+#if [ x$NCURSES != x ]; then
+#    LIBTERMCAP=-lncurses
+#else
+#    echo -n 'Checking for traditional termcap... '
+#cat <<EOF >__conftest.c
+##include <stdio.h>
+##include <termcap.h>
+#int main() {
+#    tgetent(NULL, NULL); return 0;
+#}
+#
+#EOF
+#    if (
+#          $CC $CFLAGS  __conftest.c -ltermcap -o __conftest || exit 1
+#       ) >/dev/null 2>&1; then
+#        echo '-ltermcap'
+#        LIBTERMCAP=-ltermcap
+#    else
+#        echo 'not found'
+#        echo 'This package needs termcap to run.'
+#        rm -f __conftest*
+#        exit
+#    fi
+#fi
+#rm -f __conftest*
 
 ##################################################
 
@@ -278,7 +278,7 @@ int main() { readline("foo"); return 0;
 
 EOF
 if (
-      $CC $CFLAGS  __conftest.c -lreadline $LIBTERMCAP -o __conftest || exit 1
+      $CC $CFLAGS  __conftest.c -lreadline -o __conftest || exit 1
    ) >/dev/null 2>&1; then
         echo 'yes'
         USE_READLINE=1
@@ -436,7 +436,7 @@ echo 'Generating MCONFIG...'
     echo "LDFLAGS=$LDFLAGS" | sed 's/= */=/'
     echo "LIBS=$LIBS" | sed 's/= */=/'
 
-    echo "LIBTERMCAP=$LIBTERMCAP"
+    #echo "LIBTERMCAP=$LIBTERMCAP"
     echo "USE_GLIBC=$USE_GLIBC"
     echo "USE_READLINE=$USE_READLINE"
 ) > MCONFIG
diff -Naurp netkit-ftp-0.17.debian/ftp/Makefile netkit-ftp-0.17/ftp/Makefile
--- netkit-ftp-0.17.debian/ftp/Makefile	2012-03-26 11:50:15.000000000 +0200
+++ netkit-ftp-0.17/ftp/Makefile	2012-03-26 11:53:02.000000000 +0200
@@ -5,7 +5,7 @@ include ../MRULES
 
 ifeq ($(USE_READLINE),1)
 CFLAGS += -D__USE_READLINE__
-LIBS += -lreadline $(LIBTERMCAP)
+LIBS += -lreadline
 endif
 
 ftp: cmds.o cmdtab.o domacro.o ftp.o main.o ruserpass.o