avogadro: fix build with glibc>=2.25
This commit is contained in:
parent
2213aa5acb
commit
bc4e9d48ef
2 changed files with 21 additions and 0 deletions
18
srcpkgs/avogadro/patches/glibc.patch
Normal file
18
srcpkgs/avogadro/patches/glibc.patch
Normal file
|
@ -0,0 +1,18 @@
|
|||
--- libavogadro/src/extensions/symmetry/libmsym/src/orbital.c.orig
|
||||
+++ libavogadro/src/extensions/symmetry/libmsym/src/orbital.c
|
||||
@@ -67,13 +67,13 @@
|
||||
}
|
||||
case 2 : {
|
||||
//o->v = dpolynomial[m+l];
|
||||
- char *d = (signbit(m) == 1 ? "-" : "+");
|
||||
+ char *d = (signbit(m*1.0) == 1 ? "-" : "+");
|
||||
snprintf(o->name, sizeof(o->name), "%dd%d%s",n,abs(m),d);
|
||||
break;
|
||||
}
|
||||
default : {
|
||||
char t = 'f' - 3 + l;
|
||||
- char *d = (signbit(m) == 1 ? "-" : "+");
|
||||
+ char *d = (signbit(m*1.0) == 1 ? "-" : "+");
|
||||
snprintf(o->name, sizeof(o->name), "%d%c%d%s",n,t,abs(m),d);
|
||||
}
|
||||
}
|
|
@ -14,6 +14,9 @@ homepage="http://avogadro.cc"
|
|||
distfiles="https://github.com/cryos/avogadro/archive/${version}.tar.gz"
|
||||
checksum=6453e36e8ae3e61655cbe062df6d6fa6b2409122c7b5abc0a6f1d410a181640b
|
||||
|
||||
pre_build() {
|
||||
sed -i 's|_BSD_SOURCE|_DEFAULT_SOURCE|g' CMakeLists.txt
|
||||
}
|
||||
post_install() {
|
||||
rm -rf ${DESTDIR}/usr/features
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue