3 https://github.com/openembedded/openembedded-core/tree/master/meta/recipes-extended/screen/screen
5 diff -u -r ../screen-4.4.0/configure.ac ./configure.ac
6 --- ../screen-4.4.0/configure.ac 2016-06-19 15:41:03.000000000 -0400
7 +++ ./configure.ac 2016-11-07 18:05:24.132420605 -0500
10 AC_USE_SYSTEM_EXTENSIONS
12 -AC_TRY_RUN(main(){exit(0);},,[
13 -if test $CC != cc ; then
14 -AC_NOTE(Your $CC failed - restarting with CC=cc)
18 -exec $0 $configure_args
22 -AC_TRY_RUN(main(){exit(0);},,
25 -AC_NOTE(CC=$CC; CFLAGS=$CFLAGS; LIBS=$LIBS;)
27 -AC_MSG_ERROR(Can't run the compiler - sorry))
32 - int __something_strange_();
33 - __something_strange_(0);
35 -],AC_MSG_ERROR(Your compiler does not set the exit status - sorry))
42 dnl **** special unix variants ****
44 -if test -n "$ISC"; then
45 +if test "$cross_compiling" = no && test -n "$ISC" ; then
46 AC_DEFINE(ISC) LIBS="$LIBS -linet"
53 -if test -f /sysV68 ; then
54 +if test "$cross_compiling" = no && test -f /sysV68 ; then
58 +if test "$cross_compiling" = no ; then
60 if test -f /lib/libmld.a || test -f /usr/lib/libmld.a || test -f /usr/lib/cmplrs/cc/libmld.a; then
69 AC_CHECKING(for Ultrix)
74 -if test -f /usr/lib/libpyr.a ; then
75 +if test "$cross_compiling" = no && test -f /usr/lib/libpyr.a ; then
78 AC_CHECKING(Pyramid OSX)
82 ], AC_NOTE(- your fifos are usable) fifo=1,
83 -AC_NOTE(- your fifos are not usable))
84 +AC_NOTE(- your fifos are not usable),
85 +AC_NOTE(- skipping check because we are cross compiling; assuming fifos are usable) fifo=1)
88 if test -n "$fifo"; then
92 ], AC_NOTE(- your implementation is ok),
93 -AC_NOTE(- you have a broken implementation) AC_DEFINE(BROKEN_PIPE) fifobr=1)
94 +AC_NOTE(- you have a broken implementation) AC_DEFINE(BROKEN_PIPE) fifobr=1,
95 +AC_NOTE(- skipping check because we are cross compiling; assuming fifo implementation is ok))
102 ], AC_NOTE(- your sockets are usable) sock=1,
103 -AC_NOTE(- your sockets are not usable))
105 +AC_NOTE(- your sockets are not usable),
106 +AC_NOTE(- skipping check because we are cross compiling; assuming sockets are usable) sock=1)
109 if test -n "$sock"; then
112 ],AC_NOTE(- you are normal),
113 AC_NOTE(- unix domain sockets are not kept in the filesystem)
114 -AC_DEFINE(SOCK_NOT_IN_FS) socknofs=1)
115 +AC_DEFINE(SOCK_NOT_IN_FS) socknofs=1,
116 +AC_NOTE(- skipping check because we are cross compiling; assuming sockets are normal))
123 ],AC_NOTE(- select is ok),
124 -AC_NOTE(- select can't count) AC_DEFINE(SELECT_BROKEN))
125 +AC_NOTE(- select can't count) AC_DEFINE(SELECT_BROKEN),
126 +AC_NOTE(- skipping check because we are cross compiling; assuming select is ok))
129 dnl **** termcap or terminfo ****
130 @@ -691,24 +674,29 @@
132 exit(strcmp(tgoto("%p1%d", 0, 1), "1") ? 0 : 1);
133 }], AC_NOTE(- you use the termcap database),
134 -AC_NOTE(- you use the terminfo database) AC_DEFINE(TERMINFO))
135 +AC_NOTE(- you use the terminfo database) AC_DEFINE(TERMINFO),
136 +AC_NOTE(- skipping check because we are cross compiling; assuming terminfo database is used) AC_DEFINE(TERMINFO))
138 AC_TRY_LINK(extern short ospeed;,ospeed=5;,,AC_DEFINE(NEED_OSPEED))
141 dnl **** PTY specific things ****
143 +if test "$cross_compiling" = no ; then
144 AC_CHECKING(for /dev/ptc)
145 if test -r /dev/ptc; then
146 AC_DEFINE(HAVE_DEV_PTC)
150 +if test "$cross_compiling" = no ; then
151 AC_CHECKING(for SVR4 ptys)
153 if test -c /dev/ptmx ; then
154 AC_TRY_LINK([],[ptsname(0);grantpt(0);unlockpt(0);],[AC_DEFINE(HAVE_SVR4_PTYS)
159 AC_CHECK_FUNCS(getpt)
162 [AC_CHECK_LIB(util,openpty, [AC_DEFINE(HAVE_OPENPTY)] [LIBS="$LIBS -lutil"])])
165 +if test "$cross_compiling" = no ; then
166 AC_CHECKING(for ptyranges)
167 if test -d /dev/ptym ; then
170 AC_DEFINE_UNQUOTED(PTYRANGE0,"$p0")
171 AC_DEFINE_UNQUOTED(PTYRANGE1,"$p1")
175 dnl **** pty mode/group handling ****
179 AC_NOTE(- can't determine - assume ptys are world accessable)
183 + AC_NOTE(- skipping check because we are cross compiling; assuming ptys are world accessable)
187 @@ -887,14 +878,16 @@
191 +if test "$cross_compiling" = no ; then
192 AC_CHECKING(for libutil(s))
193 test -f /usr/lib/libutils.a && LIBS="$LIBS -lutils"
194 test -f /usr/lib/libutil.a && LIBS="$LIBS -lutil"
197 AC_CHECKING(getloadavg)
198 AC_TRY_LINK(,[getloadavg((double *)0, 0);],
199 AC_DEFINE(LOADAV_GETLOADAVG) load=1,
200 -if test -f /usr/lib/libkvm.a ; then
201 +if test "$cross_compiling" = no && test -f /usr/lib/libkvm.a ; then
204 AC_CHECKING(getloadavg with -lkvm)
209 -if test -z "$load" ; then
210 +if test -z "$load" && test "$cross_compiling" = no ; then
211 AC_CHECKING(for kernelfile)
212 for core in /unix /vmunix /dynix /hp-ux /xelos /dev/ksyms /kernel/unix /kernel/genunix /unicos /mach /netbsd /386bsd /dgux /bsd /stand/vmunix; do
213 if test -f $core || test -c $core; then
214 @@ -1103,7 +1096,7 @@
218 -],,AC_DEFINE(SYSVSIGS))
219 +],,AC_DEFINE(SYSVSIGS),:)
223 @@ -1112,13 +1105,17 @@
226 AC_CHECKING(for crypt and sec libraries)
227 +if test "$cross_compiling" = no ; then
228 test -f /lib/libcrypt_d.a || test -f /usr/lib/libcrypt_d.a && LIBS="$LIBS -lcrypt_d"
233 AC_TRY_LINK(,,,LIBS="$oldlibs")
234 +if test "$cross_compiling" = no ; then
235 test -f /lib/libsec.a || test -f /usr/lib/libsec.a && LIBS="$LIBS -lsec"
236 test -f /lib/libshadow.a || test -f /usr/lib/libshadow.a && LIBS="$LIBS -lshadow"
240 AC_CHECKING(IRIX sun library)
241 @@ -1183,7 +1180,7 @@
242 if (strncmp(buf, "cdedef", 6))
244 exit(0); /* libc version works properly. */
245 -}], AC_DEFINE(USEBCOPY))
246 +}], AC_DEFINE(USEBCOPY),,:)
249 #define bcopy(s,d,l) memmove(d,s,l)
250 @@ -1198,7 +1195,8 @@
251 if (strncmp(buf, "cdedef", 6))
253 exit(0); /* libc version works properly. */
254 -}], AC_DEFINE(USEMEMMOVE))
255 +}], AC_DEFINE(USEMEMMOVE),,
256 + AC_NOTE(- skipping check because we are cross compiling; use memmove) AC_DEFINE(USEMEMMOVE))
260 @@ -1214,7 +1212,7 @@
261 if (strncmp(buf, "cdedef", 6))
263 exit(0); /* libc version works properly. */
264 -}], AC_DEFINE(USEMEMCPY))
265 +}], AC_DEFINE(USEMEMCPY),,:)
267 AC_SYS_LONG_FILE_NAMES
269 @@ -1300,8 +1298,6 @@
270 dnl Ptx bug workaround -- insert -lc after -ltermcap
271 test -n "$seqptx" && LIBS="-ltermcap -lc -lsocket -linet -lnsl -lsec -lseq"
273 -AC_TRY_RUN(main(){exit(0);},,AC_MSG_ERROR(Can't run the compiler - internal error. Sorry.))
276 AC_MSG_CHECKING(for the global screenrc file)
277 AC_ARG_WITH(sys-screenrc, [ --with-sys-screenrc=path to the global screenrc file], [ ETCSCREENRC="${withval}" ])