Skip to content

Conversation

@texierp
Copy link
Contributor

@texierp texierp commented Nov 23, 2019

The librsync code uses some C99 constructs, but old compilers such
as gcc 4.7 don't default to -std=c99. This commit makes sure librsync
is built with -std=gnu99.

Fixes:

src/rabinkarp.h:82:5: error: ‘for’ loop initial declarations are only allowed in C99 or C11 mode
for (size_t i = len; i; i--) {
^
src/rabinkarp.h:82:5: note: use option -std=c99, -std=gnu99, -std=c11 or -std=gnu11 to compile your code

Signed-off-by: Pierre-Jean Texier pjtexier@koncepto.io

The librsync code uses some C99 constructs, but old compilers such
as gcc 4.7 don't default to -std=c99. This commit makes sure librsync
is built with -std=c99.

Fixes:

src/rabinkarp.h:82:5: error: ‘for’ loop initial declarations are only allowed in C99 or C11 mode
     for (size_t i = len; i; i--) {
     ^
src/rabinkarp.h:82:5: note: use option -std=c99, -std=gnu99, -std=c11 or -std=gnu11 to compile your code

Signed-off-by: Pierre-Jean Texier <pjtexier@koncepto.io>
@dbaarda dbaarda merged commit 001c5a3 into librsync:master Nov 25, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants