unofficial mirror of bug-guix@gnu.org 
 help / color / mirror / code / Atom feed
blob eec6f889539ed67d5a2e15169dd02484586ddaf6 881 bytes (raw)
name: gnu/packages/patches/gcc-7-cross-mingw.patch 	 # note: path name is non-authoritative(*)

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
 
This fixes

../../../../gcc-7.4.0/libstdc++-v3/libsupc++/new_opa.cc: In function ‘void* __gnu_cxx::aligned_alloc(std::size_t, std::size_t)’:
../../../../gcc-7.4.0/libstdc++-v3/libsupc++/new_opa.cc:78:10: error: ‘memalign’ was not declared in this scope
   return memalign (al, sz);
          ^~~~~~~~
../../../../gcc-7.4.0/libstdc++-v3/libsupc++/new_opa.cc:78:10: note: suggested alternative: ‘max_align_t’
   return memalign (al, sz);
          ^~~~~~~~
          max_align_t

diff --git a/libstdc++-v3/libsupc++/new_opa.cc b/libstdc++-v3/libsupc++/new_opa.cc
index 94e79cadb0e..084900e0daf 100644
--- a/libstdc++-v3/libsupc++/new_opa.cc
+++ b/libstdc++-v3/libsupc++/new_opa.cc
@@ -39,6 +39,8 @@ extern "C" void *memalign(std::size_t boundary, std::size_t size);
 # endif
 #endif
 
+#define memalign _aligned_malloc
+
 using std::new_handler;
 using std::bad_alloc;
 

debug log:

solving eec6f88953 ...
found eec6f88953 in https://git.savannah.gnu.org/cgit/guix.git

(*) Git path names are given by the tree(s) the blob belongs to.
    Blobs themselves have no identifier aside from the hash of its contents.^

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).