compiling rsync 3.0.6 problem - failed to create rounding.h (366 Views)
Reply
Occasional Visitor
Rich Latham
Posts: 2
Registered: ‎12-29-2009
Message 1 of 6 (366 Views)
Accepted Solution

compiling rsync 3.0.6 problem - failed to create rounding.h

Hi,

I am trying to get rsync working for Tru 64 v5.1B. I've compiled M4 (version 1.4.13) and Autoconf (2.65) but I'm having problems with compiling rsync.

Below is the output from make (I've removed some of the 2>&1 from Makefile so I could see the error).

Anyone got any ideas or leads I could follow to get this working please?

Regards,

Rich

cc: Error: ./rounding.c, line 35: In the declaration of "test_array", the array bound "1-2*(((long int)sizeof(struct test))!=(((lo
ng int)sizeof(union file_extras))*(0+1)+((long int)sizeof(struct file_struct))))" is not a positive integer. (notposint)
static int test_array[1 - 2 * (ACTUAL_SIZE != EXPECTED_SIZE)];
---------------^
ld:
Invalid flag usage: Wno-unused-parameter, -Wx,-option must appear after -_SYSTYPE_SVR4
ld: Usage: ld [options] file [...]
ld:
Invalid flag usage: Wno-unused-parameter, -Wx,-option must appear after -_SYSTYPE_SVR4
ld: Usage: ld [options] file [...]
Failed to create rounding.h!
*** Exit 1
Stop.
#
Please use plain text.
Honored Contributor
Steven Schweda
Posts: 9,079
Registered: ‎02-23-2005
Message 2 of 6 (366 Views)

Re: compiling rsync 3.0.6 problem - failed to create rounding.h

Normally, for a Tru64 question, one might
expect better answers sooner in a Tru64 forum
than in this HP-UX forum.

Knowing nothing, looking only at what's here,
...

cc: Error: [...]

Well, if (ACTUAL_SIZE != EXPECTED_SIZE), then
the array dimension would seem to be -1
("1 - 2 * (1)"), which would seem to justify
the complaint.

> ld:
Invalid flag usage: [...]

Looks to me as if someone's throwing GCC
compiler options at a non-GCC compiler, so it
passes them along to "ld", who doesn't know
what to do with them, either.
Please use plain text.
Honored Contributor
Steven Schweda
Posts: 9,079
Registered: ‎02-23-2005
Message 3 of 6 (366 Views)

Re: compiling rsync 3.0.6 problem - failed to create rounding.h

I seem to have built rsync 3.0.5 on my Tru64
system a while ago.

According to my notes, gcc did better than
cc, but I did make one source change:

urtx# gdiff -u rsync-3.0.5/popt/system.h_orig rsync-3.0.5/popt/system.h
--- rsync-3.0.5/popt/system.h_orig 2006-11-08 20:37:38.000000000 -0600
+++ rsync-3.0.5/popt/system.h 2009-01-04 03:34:51.000000000 -0600
@@ -87,6 +87,8 @@
# endif
#elif defined(__GNUC__) && defined(__STRICT_ANSI__)
#define alloca __builtin_alloca
+#elif defined( HAVE_ALLOCA_H)
+# include
#endif

#ifndef HAVE_STRLCPY


and I leaned a little on the builders to get
past that GCC-only "-W" option:

urtx# CC=cc ./configure

urtx# CFLAGS='-g -DHAVE_CONFIG_H -I./popt ' gmake -e

There may be smarter ways to get the desired
effect, but that's what (I think that) I did.
(You have to love portable code. When you
can find any.) "gmake" is GNU "make". I
don't know if it's needed, but I probably
figured that it had a better chance on a
project with GCC-specific junk hard-coded
into the builders.

It might pay to stick something like a "-O3"
into that CFLAGS stuff, too, now that I think
about it.

I doubt that I did more with it than this:

urtx# rsync --version
rsync version 3.0.5 protocol version 30
Copyright (C) 1996-2008 by Andrew Tridgell, Wayne Davison, and others.
Web site: http://rsync.samba.org/
Capabilities:
64-bit files, 32-bit inums, 32-bit timestamps, 64-bit long ints,
socketpairs, hardlinks, symlinks, no IPv6, batchfiles, inplace,
append, ACLs, no xattrs, no iconv, no symtimes
[...]

but I did get that far. For the record:

urtx# sizer -v
HP Tru64 UNIX V5.1B (Rev. 2650); Fri Mar 20 20:19:48 CDT 2009

urtx# dupatch -track -type patch_level | grep -i 'patch kit '
Patch Kit 5: T64V51BB26AS0005-20050502 OSF540
Patch Kit 6: T64V51BB27AS0006-20061208 OSF540
Patch Kit 7: T64V51BB28AS0007-20090312 OSF540

(Not sure if "Patch Kit 7" was in effect when
I did the rsync work, but it probably matters
little.)
Please use plain text.
Occasional Visitor
Rich Latham
Posts: 2
Registered: ‎12-29-2009
Message 4 of 6 (366 Views)

Re: compiling rsync 3.0.6 problem - failed to create rounding.h

Hi,

I got it fixed just after your first post.

In your first post you mentioned that that it looked like gcc options were being given to the compiler and this was exactly the clue I needed.

I'd seen some other stuff on the web earlier and it fell into place not long after reading your post.

What I did was as follows:

export CC=cc
./configure

and in the Makefile I changed the line

CFLAGS=-g -DHAVE_CONFIG_H -I./popt -Wno-unused-parameter

to

CFLAGS=-g -DHAVE_CONFIG_H -I./popt

After that make;make install worked without bother and I can run rsync --version without error.

Thanks for your help.
Please use plain text.
Honored Contributor
Steven Schweda
Posts: 9,079
Registered: ‎02-23-2005
Message 5 of 6 (366 Views)

Re: compiling rsync 3.0.6 problem - failed to create rounding.h

> I got it fixed just after your first post.

I'm sure glad that you reported that
promptly, so that I wouldn't waste any time
researching the details.

> urtx# CC=cc ./configure

> export CC=cc
> ./configure

One way leaves CC defined to make trouble
later, and one doesn't. Similarly, my
"[g]make" command requires no Makefile
editing.

You might consider reporting this (lameness)
to the (overly GNU-centric) folks who
maintain rsync.


An idle moderator might wish to move this
thread to an appropriate (Tru64-related)
place.
Please use plain text.
Honored Contributor
Steven Schweda
Posts: 9,079
Registered: ‎02-23-2005
Message 6 of 6 (366 Views)

Re: compiling rsync 3.0.6 problem - failed to create rounding.h

I haven't yet tried the latest thing, but
there may be some hope for the future:

https://bugzilla.samba.org/show_bug.cgi?id=7015
Please use plain text.
The opinions expressed above are the personal opinions of the authors, not of HP. By using this site, you accept the Terms of Use and Rules of Participation