diff --git a/indent-2.2.10-cdw.diff b/indent-2.2.10-cdw.diff deleted file mode 100644 index 8a8fed9..0000000 --- a/indent-2.2.10-cdw.diff +++ /dev/null @@ -1,85 +0,0 @@ ---- indent-2.2.10/src/indent.c -+++ indent-2.2.10/src/indent.c -@@ -1033,13 +1033,10 @@ - - if (!*sp_sw) - { /* if not if for (;;) */ -- do -- { - if (parse (semicolon) != total_success) - { - *file_exit_value = indent_error; - } -- } while(0); - - *force_nl = true; /* force newline after a end of stmt */ - } -@@ -2818,6 +2815,18 @@ - return file_exit_value; /* RETURN */ - } - -+ if (type_code == sp_paren -+ && parser_state_tos->p_stack[parser_state_tos->tos] == dohead -+ && parser_state_tos->last_token == rbrace) -+ { -+ /* This is closing `while' of `do {stuff;} while' -+ statement (not `do stuff; while' command). In -cdw, we -+ want to suppress newline. */ -+ if (settings.cuddle_do_while) -+ force_nl = false; -+ parser_state_tos->in_closing_br_while = true; -+ } -+ - if ((type_code != comment) && - (type_code != cplus_comment) && - (type_code != newline) && ---- indent-2.2.10/src/indent.h -+++ indent-2.2.10/src/indent.h -@@ -420,6 +420,9 @@ - BOOLEAN in_decl; /*!< set to true when we are in a declaration - * statement. The processing of braces is then - * slightly different */ -+ BOOLEAN in_closing_br_while; /*!< set to true when we are parsing -+ * closing while of do {} while -+ * statement*/ - int in_stmt; /*!< set to 1 while in a stmt */ - int in_parameter_declaration; - int ind_level; /*!< the current indentation level in spaces */ ---- indent-2.2.10/src/parse.c -+++ indent-2.2.10/src/parse.c -@@ -69,6 +69,7 @@ - parser_state_tos->cstk = (int *) xmalloc (INITIAL_STACK_SIZE * sizeof (int)); - parser_state_tos->paren_indents_size = 8; - parser_state_tos->paren_indents = (short *) xmalloc (parser_state_tos->paren_indents_size * sizeof (short)); -+ parser_state_tos->in_closing_br_while = false; - - /* Although these are supposed to grow if we reach the end, - * I can find no place in the code which does this. */ -@@ -428,6 +429,14 @@ - - parser_state_tos->ind_level = parser_state_tos->i_l_follow; - parser_state_tos->il[parser_state_tos->tos] = parser_state_tos->i_l_follow; -+ -+ if (parser_state_tos->in_closing_br_while -+ && settings.cuddle_do_while -+ && !settings.btype_2) -+ { -+ parser_state_tos->ind_level += settings.brace_indent; -+ } -+ parser_state_tos->in_closing_br_while = false; - } - else - { /* it is a while loop */ -@@ -457,6 +466,12 @@ - parser_state_tos->p_stack[parser_state_tos->tos] = elsehead; - /* remember if with else */ - parser_state_tos->search_brace = true; -+ -+ if (settings.cuddle_else -+ && !settings.btype_2) -+ { -+ parser_state_tos->ind_level += settings.brace_indent; -+ } - } - break; - diff --git a/indent-2.2.10-nothing_is_void.diff b/indent-2.2.10-nothing_is_void.diff deleted file mode 100644 index ab866c5..0000000 --- a/indent-2.2.10-nothing_is_void.diff +++ /dev/null @@ -1,11 +0,0 @@ ---- indent-2.2.9/man/texinfo2man.c -+++ indent-2.2.9/man/texinfo2man.c -@@ -162,7 +162,7 @@ - - static char value_updated[64], value_edition[64], value_version[64]; - --process_texi (FILE * in) -+void process_texi (FILE * in) - { - char buf[1024]; - int in_block = 0; diff --git a/indent-2.2.10-warnings.diff b/indent-2.2.10-warnings.diff index 4446cbf..bfef37f 100644 --- a/indent-2.2.10-warnings.diff +++ b/indent-2.2.10-warnings.diff @@ -1,4 +1,6 @@ ---- src/output.c +Index: src/output.c +=================================================================== +--- src/output.c.orig +++ src/output.c @@ -71,7 +71,7 @@ @@ -9,17 +11,3 @@ static BOOLEAN inhibited = 0; static buf_break_st_ty * buf_break_list = NULL; -@@ -749,11 +749,11 @@ - - if (s[0] == '/' && (s[1] == '*' || s[1] == '/')) - { -- fprintf (output, "%.*s", e_lab - s, s); -+ fprintf (output, "%.*s", (int) (e_lab - s), s); - } - else - { -- fprintf (output, "/* %.*s */", e_lab - s, s); -+ fprintf (output, "/* %.*s */", (int) (e_lab - s), s); - } - - /* no need to update cur_col: the very next thing will diff --git a/indent-2.2.10.tar.gz b/indent-2.2.10.tar.gz deleted file mode 100644 index 1104898..0000000 --- a/indent-2.2.10.tar.gz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:8a9b41be5bfcab5d8c1be74204b10ae78789fc3deabea0775fdced8677292639 -size 702667 diff --git a/indent-2.2.10.tar.gz.sig b/indent-2.2.10.tar.gz.sig deleted file mode 100644 index 6184a8b..0000000 --- a/indent-2.2.10.tar.gz.sig +++ /dev/null @@ -1,7 +0,0 @@ ------BEGIN PGP SIGNATURE----- -Version: GnuPG v2.0.9 (GNU/Linux) - -iEYEABECAAYFAkmX5YMACgkQV4UaJNn8jXMKzwCg0mz1BvCS6WGbVJ0C97hjZNsp -SR8An0g84eSAFDkXCyJwoQbiaQwwgrgS -=z0xr ------END PGP SIGNATURE----- diff --git a/indent.changes b/indent.changes index b5af2d3..3615bf0 100644 --- a/indent.changes +++ b/indent.changes @@ -1,3 +1,19 @@ +------------------------------------------------------------------- +Fri Dec 15 12:19:22 UTC 2017 - kstreitova@suse.com + +- update to 2.2.11 + * fixed Debian Bug report logs - #485764, Regression with + --blank-lines-after-declarations in 2.2.10 + * fail instead of removing embedded NULLs in input files + * fixed handling of '...' range 'operator in C++ language + * fixed -nlps option. +- remove indent-2.2.10-nothing_is_void.diff that is no longer + needed +- remove indent-2.2.10-cdw.diff that is useless now +- refresh indent-2.2.10-warnings.diff +- re-enable parallel build +- ship COPYING NEWS README and ChangeLog files + ------------------------------------------------------------------- Thu Mar 23 15:15:13 UTC 2017 - kstreitova@suse.com diff --git a/indent.keyring b/indent.keyring deleted file mode 100644 index f7915bd..0000000 --- a/indent.keyring +++ /dev/null @@ -1,30 +0,0 @@ ------BEGIN PGP PUBLIC KEY BLOCK----- -Version: GnuPG v2 - -mQGiBElSMsARBADZTJJDm8dR12eMorXmagsHQDkXZ88FjSnKVwlmBAf/gPNAaGhc -jxyV07ceTLBFh+rqVO5KTTIgsrxcuoZdA7wJceU1Wsy3czaqrouJAFtwTSlXNPr7 -nT7IOoE3mygmjhmlNgkvO7SyJUzR/Aew8DXcvbw0SO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65ql/WsUJqxTQV1JuwfN9Zne4/QZReewk6+bvwriUglKkn5hl3RUk -pBwXvsHY+QSdk9Y0PPMMfK5fCMz1AHuol7czGlFjprAku+k98cmVbn2YIFnhmfhl -YcyUyWxeQiAC34N/UPBauyXloWHndzd1yjT40KDr/dRThLgbRGQ2aMVeadbG6DIF -kFJbsIaWYrxE5wKKemA4WLmo3FJN7k/XcplKXLTJFbtjexLv7PhYSWBXCeminmC4 -vohJBBgRAgAJBQJJUjLAAhsMAAoJEFeFGiTZ/I1zwmYAnj41kUsewQhRq6V2VpME -gBTEzPkvAKDaegBoUhHKnBmAgqwUFJxvGicB4A== -=e6az ------END PGP PUBLIC KEY BLOCK----- diff --git a/indent.spec b/indent.spec index 75588ad..6dd8024 100644 --- a/indent.spec +++ b/indent.spec @@ -17,25 +17,25 @@ Name: indent -Version: 2.2.10 +Version: 2.2.11 Release: 0 Summary: Indent Formats C Source Code License: GPL-3.0+ Group: Development/Languages/C and C++ Url: http://www.gnu.org/software/indent -Source0: ftp://ftp.gnu.org/gnu/%{name}/%{name}-%{version}.tar.gz -Source1: ftp://ftp.gnu.org/gnu/%{name}/%{name}-%{version}.tar.gz.sig -Source2: %{name}.keyring -Patch0: indent-2.2.10-nothing_is_void.diff +#Source0: ftp://ftp.gnu.org/gnu/%{name}/%{name}-%{version}.tar.gz +#Source1: ftp://ftp.gnu.org/gnu/%{name}/%{name}-%{version}.tar.gz.sig +#Source2: %{name}.keyring +# Version 2.2.11 is not available at ftp.gnu.org as it has been developed outside the GNU project +# see https://lists.gnu.org/archive/html/bug-indent/2015-11/msg00004.html +Source0: http://debian.lagis.at/debian/pool/main/i/indent/indent_%{version}.orig.tar.gz Patch1: indent-2.2.10-warnings.diff Patch2: indent-2.2.10-lcall.diff -Patch3: indent-2.2.10-cdw.diff Patch4: indent-2.2.10-man.diff Patch5: indent-texi2html-5.0.patch BuildRequires: makeinfo BuildRequires: texi2html Requires(pre): %{install_info_prereq} -BuildRoot: %{_tmppath}/%{name}-%{version}-build %description Indent can be used to make code easier to read. It can also convert @@ -45,17 +45,14 @@ incomplete and malformed syntax. %prep %setup -q -%patch0 -p1 %patch1 %patch2 -%patch3 -p1 %patch4 %patch5 -p1 %build %configure -# parallel builds are broken -make -j 1 +make %{?_smp_mflags} %install %make_install @@ -74,9 +71,8 @@ make %{?_smp_mflags} -C regression %install_info_delete --info-dir=%{_infodir} %{_infodir}/%{name}.info.gz %files -f %{name}.lang -%defattr(-, root, root) %{_bindir}/* -%doc doc/indent.html +%doc COPYING NEWS README ChangeLog doc/indent.html %{_infodir}/%{name}.info%{ext_info} %{_mandir}/man1/indent.1%{ext_man} diff --git a/indent_2.2.11.orig.tar.gz b/indent_2.2.11.orig.tar.gz new file mode 100644 index 0000000..998e2a3 --- /dev/null +++ b/indent_2.2.11.orig.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:aaff60ce4d255efb985f0eb78cca4d1ad766c6e051666073050656b6753a0893 +size 778563