vlc | branch: master | Hugo Beauzée-Luyssen <[email protected]> | Thu May 19 
17:04:34 2016 +0200| [217fa33303bbf05290391be267e8a16ae50a2fee] | committer: 
Hugo Beauzée-Luyssen

contribs: ssh: Workaround gcc 4.9 bug

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64284
Build failed with "scp.c:126:1: internal compiler error: Segmentation
fault" when using -O2

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=217fa33303bbf05290391be267e8a16ae50a2fee
---

 contrib/src/ssh2/rules.mak |    8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/contrib/src/ssh2/rules.mak b/contrib/src/ssh2/rules.mak
index ac44846..ac71c98 100644
--- a/contrib/src/ssh2/rules.mak
+++ b/contrib/src/ssh2/rules.mak
@@ -10,6 +10,12 @@ ifeq ($(call need_pkg,"libssh2"),)
 PKGS_FOUND += ssh2
 endif
 
+ifndef HAVE_WIN32
+ifeq ($(shell echo `${CC} -dumpversion | cut -f1-2 -d.` == 4.9 | bc ),1)
+       BROKEN_GCC_CFLAGS:="CFLAGS=-O1"
+endif
+endif
+
 $(TARBALLS)/libssh2-$(LIBSSH2_VERSION).tar.gz:
        $(call download,$(LIBSSH2_URL))
 
@@ -29,6 +35,6 @@ DEPS_ssh2 = gcrypt $(DEPS_gcrypt)
 
 .ssh2: ssh2
        $(RECONF)
-       cd $< && $(HOSTVARS) ./configure $(HOSTCONF) --disable-examples-build 
--with-libgcrypt --without-openssl
+       cd $< && $(HOSTVARS) ./configure $(BROKEN_GCC_CFLAGS) $(HOSTCONF) 
--disable-examples-build --with-libgcrypt --without-openssl
        cd $< && $(MAKE) install
        touch $@

_______________________________________________
vlc-commits mailing list
[email protected]
https://mailman.videolan.org/listinfo/vlc-commits

Reply via email to