diff --git a/libedit-20100424-3.0-ncurses.patch b/libedit-20100424-3.0-ncurses.patch deleted file mode 100644 index 1d59054..0000000 --- a/libedit-20100424-3.0-ncurses.patch +++ /dev/null @@ -1,37 +0,0 @@ -Index: configure.ac -=================================================================== ---- configure.ac.orig 2014-07-28 16:16:14.800585267 +0200 -+++ configure.ac 2014-07-28 16:16:17.338585263 +0200 -@@ -52,7 +52,7 @@ AC_CHECK_LIB(tinfo, tgetent,, - [AC_CHECK_LIB(termcap, tgetent,, - [AC_CHECK_LIB(termlib, tgetent,, - [AC_CHECK_LIB(curses, tgetent,, -- [AC_CHECK_LIB(ncurses, tgetent,, -+ [AC_CHECK_LIB(ncursesw, tgetent,, - [AC_MSG_ERROR([libcurses or libncurses are required!])] - )] - )] -Index: src/Makefile.am -=================================================================== ---- src/Makefile.am.orig 2014-07-28 16:16:14.800585267 +0200 -+++ src/Makefile.am 2014-07-28 16:17:25.508585142 +0200 -@@ -66,5 +66,6 @@ nobase_include_HEADERS = histedit.h edit - - nodist_libedit_la_SOURCES = $(BUILT_SOURCES) - --libedit_la_LDFLAGS = -no-undefined -version-info $(LT_VERSION) -+libedit_la_CFLAGS = $(shell ncursesw6-config --cflags) -+libedit_la_LDFLAGS = $(shell ncursesw6-config --libs) -no-undefined -version-info $(LT_VERSION) - -Index: libedit.pc.in -=================================================================== ---- libedit.pc.in.orig 2014-07-28 16:16:14.800585267 +0200 -+++ libedit.pc.in 2014-07-28 16:16:17.338585263 +0200 -@@ -7,6 +7,6 @@ Name: libedit - Description: command line editor library provides generic line editing, history, and tokenization functions. - Version: @VERSION@ - Requires: --Libs: -L${libdir} -ledit @LIBS@ -+Libs: -ledit - Cflags: -I${includedir} -I${includedir}/editline - diff --git a/libedit-20150325-3.1.tar.gz b/libedit-20150325-3.1.tar.gz deleted file mode 100644 index 7da5fc6..0000000 --- a/libedit-20150325-3.1.tar.gz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:c88a5e4af83c5f40dda8455886ac98923a9c33125699742603a88a0253fcc8c5 -size 502792 diff --git a/libedit-20180525-3.1.tar.gz b/libedit-20180525-3.1.tar.gz new file mode 100644 index 0000000..302f609 --- /dev/null +++ b/libedit-20180525-3.1.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c41bea8fd140fb57ba67a98ec1d8ae0b8ffa82f4aba9c35a87e5a9499e653116 +size 521999 diff --git a/libedit-20180525-manpage-conflicts.patch b/libedit-20180525-manpage-conflicts.patch new file mode 100644 index 0000000..9f8bf78 --- /dev/null +++ b/libedit-20180525-manpage-conflicts.patch @@ -0,0 +1,59 @@ +From: 1Antoine1 +Date: 2018-08-06 11:47:22 +0200 +Subject: doc: File conlicts with readline-doc +References: (none) +Upstream: not submitted yet + +Make sure all manpages are prefixed with "el_" in order to avoid +file conflicts with readline-doc. + +--- +diff -up libedit-20180525-3.1/doc/Makefile.am.orig libedit-20180525-3.1/doc/Makefile.am +--- libedit-20180525-3.1/doc/Makefile.am.orig 2018-08-06 11:37:52.160085685 +0200 ++++ libedit-20180525-3.1/doc/Makefile.am 2018-08-06 11:39:04.352082128 +0200 +@@ -20,14 +20,14 @@ EL_MAN_LINKS = \ + el_resize.3 \ + el_set.3 \ + el_source.3 \ +- history.3 \ +- history_end.3 \ +- history_init.3 \ +- tok_end.3 \ +- tok_init.3 \ +- tok_line.3 \ +- tok_reset.3 \ +- tok_str.3 ++ el_history.3 \ ++ el_history_end.3 \ ++ el_history_init.3 \ ++ el_tok_end.3 \ ++ el_tok_init.3 \ ++ el_tok_line.3 \ ++ el_tok_reset.3 \ ++ el_tok_str.3 + + EL_MAN_LINKS += \ + el_wdeletestr.3 \ +@@ -39,14 +39,14 @@ EL_MAN_LINKS += \ + el_wparse.3 \ + el_wpush.3 \ + el_wset.3 \ +- history_w.3 \ +- history_wend.3 \ +- history_winit.3 \ +- tok_wend.3 \ +- tok_winit.3 \ +- tok_wline.3 \ +- tok_wreset.3 \ +- tok_wstr.3 ++ el_history_w.3 \ ++ el_history_wend.3 \ ++ el_history_winit.3 \ ++ el_tok_wend.3 \ ++ el_tok_winit.3 \ ++ el_tok_wline.3 \ ++ el_tok_wreset.3 \ ++ el_tok_wstr.3 + + + install-data-hook: $(EL_MAN_LINKS) diff --git a/libedit-ocloexec.patch b/libedit-ocloexec.patch deleted file mode 100644 index a7882f1..0000000 --- a/libedit-ocloexec.patch +++ /dev/null @@ -1,79 +0,0 @@ -Index: src/readline.c -=================================================================== ---- src/readline.c.orig 2014-07-28 16:17:56.006585088 +0200 -+++ src/readline.c 2014-07-28 16:17:58.431585084 +0200 -@@ -1190,15 +1190,15 @@ history_truncate_file (const char *filen - - if (filename == NULL && (filename = _default_history_file()) == NULL) - return errno; -- if ((fp = fopen(filename, "r+")) == NULL) -+ if ((fp = fopen(filename, "r+e")) == NULL) - return errno; - strcpy(template, _history_tmp_template); -- if ((fd = mkstemp(template)) == -1) { -+ if ((fd = mkostemp(template, O_CLOEXEC)) == -1) { - ret = errno; - goto out1; - } - -- if ((tp = fdopen(fd, "r+")) == NULL) { -+ if ((tp = fdopen(fd, "r+e")) == NULL) { - close(fd); - ret = errno; - goto out2; -Index: src/vi.c -=================================================================== ---- src/vi.c.orig 2014-07-28 16:17:56.006585088 +0200 -+++ src/vi.c 2014-07-28 16:17:58.432585084 +0200 -@@ -37,6 +37,7 @@ - #include - #include - #include -+#include - - #if !defined(lint) && !defined(SCCSID) - #if 0 -@@ -1007,7 +1008,7 @@ vi_histedit(EditLine *el, Int c __attrib - return CC_ERROR; - } - -- fd = mkstemp(tempfile); -+ fd = mkostemp(tempfile, O_CLOEXEC); - if (fd < 0) - return CC_ERROR; - len = (size_t)(el->el_line.lastchar - el->el_line.buffer); -Index: src/el.c -=================================================================== ---- src/el.c.orig 2014-07-28 16:17:56.006585088 +0200 -+++ src/el.c 2014-07-28 16:17:58.432585084 +0200 -@@ -557,7 +557,7 @@ el_source(EditLine *el, const char *fnam - fname = path; - } - if (fp == NULL) -- fp = fopen(fname, "r"); -+ fp = fopen(fname, "re"); - if (fp == NULL) { - el_free(path); - return -1; -Index: src/history.c -=================================================================== ---- src/history.c.orig 2014-07-28 16:17:56.007585088 +0200 -+++ src/history.c 2014-07-28 16:18:38.101585014 +0200 -@@ -743,7 +743,7 @@ history_load(TYPE(History) *h, const cha - static ct_buffer_t conv; - #endif - -- if ((fp = fopen(fname, "r")) == NULL) -+ if ((fp = fopen(fname, "re")) == NULL) - return i; - - if ((line = fgetln(fp, &sz)) == NULL) -@@ -844,7 +844,7 @@ history_save(TYPE(History) *h, const cha - FILE *fp; - int i; - -- if ((fp = fopen(fname, "w")) == NULL) -+ if ((fp = fopen(fname, "we")) == NULL) - return -1; - - i = history_save_fp(h, fp); diff --git a/libedit-visibility.patch b/libedit-visibility.patch deleted file mode 100644 index f87adb8..0000000 --- a/libedit-visibility.patch +++ /dev/null @@ -1,22 +0,0 @@ -Index: libedit-20110802-3.0/src/sys.h -=================================================================== ---- libedit-20110802-3.0.orig/src/sys.h -+++ libedit-20110802-3.0/src/sys.h -@@ -63,7 +63,7 @@ - #endif - - #ifndef public --# define public /* Externally visible functions/variables */ -+# define public __attribute__ ((visibility ("default"))) /* Externally visible functions/variables */ - #endif - - #ifndef private -@@ -71,7 +71,7 @@ - #endif - - #ifndef protected --# define protected /* Redefined from elsewhere to "static" */ -+# define protected __attribute__ ((visibility ("hidden"))) /* Redefined from elsewhere to "static" */ - /* When we want to hide everything */ - #endif - diff --git a/libedit.changes b/libedit.changes index 20bb3da..6e4f405 100644 --- a/libedit.changes +++ b/libedit.changes @@ -1,3 +1,29 @@ +------------------------------------------------------------------- +Wed Aug 8 13:08:56 UTC 2018 - jengelh@inai.de + +- Remove redundant --with-pic (only for static libs). +- Fix RPM groups. + +------------------------------------------------------------------- +Mon Aug 6 09:13:50 UTC 2018 - antoine.belvire@opensuse.org + +- Bump version tag. +- Make sure all manpages are prefixed with "el_" to avoid file + conflicts with readline-doc: + * Add libedit-20180525-manpage-conflicts.patch. + +------------------------------------------------------------------- +Mon Jul 23 06:41:08 UTC 2018 - mpluskal@suse.com + +- Update to version 20180525-3.1: + * Sync with upstream sources +- Drop no longer needed patches: + * libedit-20100424-3.0-ncurses.patch + * libedit-ocloexec.patch + * libedit-visibility.patch +- Trim unused dependencies +- Drop %check section (there are no tests available) + ------------------------------------------------------------------- Wed Mar 28 09:30:51 UTC 2018 - dmueller@suse.com diff --git a/libedit.spec b/libedit.spec index e54c47c..2e3e439 100644 --- a/libedit.spec +++ b/libedit.spec @@ -16,27 +16,26 @@ # -%define pkg_version 20150325-3.1 +%define pkg_version 20180525-3.1 %define soname 0 %define library_name libedit%{soname} Name: libedit -Version: 3.1.snap20150325 +Version: 3.1.snap20180525 Release: 0 Summary: Command Line Editing and History Library License: BSD-3-Clause Group: Development/Libraries/C and C++ -Url: http://www.thrysoee.dk/editline/ +URL: http://www.thrysoee.dk/editline/ Source: http://thrysoee.dk/editline/libedit-%{pkg_version}.tar.gz Source1: README.SUSE Source2: baselibs.conf -Patch2: libedit-20100424-3.0-ncurses.patch -Patch3: libedit-ocloexec.patch -Patch4: libedit-visibility.patch -BuildRequires: gcc-c++ -BuildRequires: libtool -BuildRequires: ncurses-devel +# PATCH-FIX-UPSTREAM libedit-20180525-manpage-conflicts.patch +Patch0: libedit-20180525-manpage-conflicts.patch +#BuildRequires: gcc-c++ +# For patch0 +BuildRequires: automake BuildRequires: pkgconfig -BuildRoot: %{_tmppath}/%{name}-%{version}-build +BuildRequires: pkgconfig(ncurses) %description libedit is a command line editing and history library. It is designed @@ -45,7 +44,7 @@ at a terminal prompt. %package -n %{library_name} Summary: Command Line Editing and History Library -Group: Development/Libraries/C and C++ +Group: System/Libraries Provides: %{name} = %{version}-%{release} Obsoletes: %{name} < %{version} @@ -71,44 +70,34 @@ This package holds the development files for libedit. %prep %setup -q -n %{name}-%{pkg_version} cp %{SOURCE1} . -%patch2 -%patch3 -%patch4 -p1 +%patch0 -p1 %build -autoreconf -fiv %configure \ - --disable-static \ - --with-pic \ - --disable-silent-rules \ - --enable-widec + --disable-static \ + --disable-silent-rules make %{?_smp_mflags} %install -make DESTDIR=%{buildroot} install %{?_smp_mflags} +%make_install find %{buildroot} -type f -name "*.la" -delete -print -%check -make %{?_smp_mflags} check - %post -n %{library_name} -p /sbin/ldconfig - %postun -n %{library_name} -p /sbin/ldconfig %files -n %{library_name} -%defattr(-,root,root,-) %{_libdir}/libedit.so.%{soname} %{_libdir}/libedit.so.%{soname}.* -%{_mandir}/man5/editrc.5%{ext_man} +%{_mandir}/man5/editrc.5%{?ext_man} %license COPYING %doc ChangeLog %files -n libedit-devel -%defattr(-,root,root,-) %{_libdir}/libedit.so %{_includedir}/histedit.h %{_includedir}/editline/ -%{_mandir}/man3/*.3%{ext_man} +%{_mandir}/man3/*.3%{?ext_man} +%{_mandir}/man7/*.7%{?ext_man} %{_libdir}/pkgconfig/libedit.pc %doc examples/*c THANKS README.SUSE