commit 2005be0101216553d246ef499cfa5c9f46e4ef3b
Author: Jan Palus <[email protected]>
Date:   Wed Jul 22 18:10:48 2020 +0200

    %if "<ver1>" >= "<ver2>" is lexicographical comparison, not version
    
    fixes build with gcc 10 but also makes questionable other such
    comparisons ie against %{_rpmversion}

 llvm.spec | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
---
diff --git a/llvm.spec b/llvm.spec
index 63b1747..08e3ef7 100644
--- a/llvm.spec
+++ b/llvm.spec
@@ -64,7 +64,7 @@ BuildRequires:        cmake >= 3.4.3
 BuildRequires: flex
 BuildRequires: gcc >= 5:3.4
 # gcc4 might be installed, but not current __cc
-%if "%(echo %{cc_version} | cut -d. -f1,2)" < "3.4"
+%if %(rpmvercmp %{cc_version} 3.4 > /dev/null; test $? = 2 && echo 1 || echo 0)
 BuildRequires: __cc >= 3.4
 %endif
 BuildRequires: groff
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/llvm.git/commitdiff/2005be0101216553d246ef499cfa5c9f46e4ef3b

_______________________________________________
pld-cvs-commit mailing list
[email protected]
http://lists.pld-linux.org/mailman/listinfo/pld-cvs-commit

Reply via email to