build-issue on AIX with openssh-7.7p1 - easy correction! included
Michael Felt
michael at felt.demon.nl
Sun Apr 22 00:21:43 AEST 2018
Get the following error:
root at x065:[/data/prj/openbsd/openssh/openssh-7.7p1/openbsd-compat]make
xlc_r -I/opt/include -O2 -qmaxmem=-1 -qarch=pwr5 -q64 -I. -I..
-I../../src/openssh-7.7p1/openbsd-compat
-I../../src/openssh-7.7p1/openbsd-compat/.. -I/opt/include
-DHAVE_CONFIG_H -c ../../src/openssh-7.7p1/openbsd-compat/strndup.c
"../../src/openssh-7.7p1/openbsd-compat/strndup.c", line 42.1: 1506-273
(E) Missing type in declaration of DEF_WEAK.
"../../src/openssh-7.7p1/openbsd-compat/strndup.c", line 42.1: 1506-282
(S) The type of the parameters must be specified in a prototype.
make: 1254-004 The error code from the last command is 1.
Info: strndup.c is a new file in openssh-7.7p1, and the correction is
simple:
Now:
1 /* $OpenBSD: strndup.c,v 1.2 2015/08/31 02:53:57 guenther
Exp $ */
2
3 /*
4 * Copyright (c) 2010 Todd C. Miller <Todd.Miller at courtesan.com>
5 *
6 * Permission to use, copy, modify, and distribute this
software for any
7 * purpose with or without fee is hereby granted, provided that
the above
8 * copyright notice and this permission notice appear in all
copies.
9 *
10 * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS
ALL WARRANTIES
11 * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
12 * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE
LIABLE FOR
13 * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR
ANY DAMAGES
14 * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
WHETHER IN AN
15 * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,
ARISING OUT OF
16 * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
17 */
18
19 #include "config.h"
20 #if !defined(HAVE_STRNDUP) || defined(BROKEN_STRNDUP)
21 #include <sys/types.h>
22
23 #include <stddef.h>
...
Change Line 19 to:
#include "includes.h"
and the build succeeds.
More information about the openssh-unix-dev
mailing list