summaryrefslogtreecommitdiffstats
path: root/mmc_updater/src/StlSymbolsLeopard.cpp
diff options
context:
space:
mode:
authorAndrew <forkk@forkk.net>2013-12-09 12:04:05 -0600
committerAndrew <forkk@forkk.net>2013-12-09 12:04:05 -0600
commit7f52bed9e3f559adcbcf3f3c1c7ac2251964db8c (patch)
tree52097b57dc7d18ec4e35ef3a8e554af2d91545e8 /mmc_updater/src/StlSymbolsLeopard.cpp
parent9410dd042ea62224fa3e0eb3b525abbdf0c316ee (diff)
parent220e07aef4a34dca9f31ae0c5bb994e5c594125d (diff)
downloadMultiMC-7f52bed9e3f559adcbcf3f3c1c7ac2251964db8c.tar
MultiMC-7f52bed9e3f559adcbcf3f3c1c7ac2251964db8c.tar.gz
MultiMC-7f52bed9e3f559adcbcf3f3c1c7ac2251964db8c.tar.lz
MultiMC-7f52bed9e3f559adcbcf3f3c1c7ac2251964db8c.tar.xz
MultiMC-7f52bed9e3f559adcbcf3f3c1c7ac2251964db8c.zip
Merge branch 'feature_updater' into develop
Diffstat (limited to 'mmc_updater/src/StlSymbolsLeopard.cpp')
-rw-r--r--mmc_updater/src/StlSymbolsLeopard.cpp75
1 files changed, 75 insertions, 0 deletions
diff --git a/mmc_updater/src/StlSymbolsLeopard.cpp b/mmc_updater/src/StlSymbolsLeopard.cpp
new file mode 100644
index 00000000..d5f58ebf
--- /dev/null
+++ b/mmc_updater/src/StlSymbolsLeopard.cpp
@@ -0,0 +1,75 @@
+// Workarounds for iostream symbols that are referenced when building on OS X 10.7 but missing from
+// OS X 10.5's stdlibc++.dylib.
+//
+// In the <iostream> headers these are declared as extern templates but the symbols are not present under 10.5.
+// This file forces the compiler to instantiate the templates.
+//
+// see http://stackoverflow.com/questions/3484043/os-x-program-runs-on-dev-machine-crashing-horribly-on-others
+
+#include <iostream>
+
+_GLIBCXX_BEGIN_NAMESPACE(std)
+// From ostream_insert.h
+template ostream& __ostream_insert(ostream&, const char*, streamsize);
+
+#ifdef _GLIBCXX_USE_WCHAR_T
+template wostream& __ostream_insert(wostream&, const wchar_t*, streamsize);
+#endif
+
+// From ostream.tcc
+template ostream& ostream::_M_insert(long);
+template ostream& ostream::_M_insert(unsigned long);
+template ostream& ostream::_M_insert(bool);
+#ifdef _GLIBCXX_USE_LONG_LONG
+template ostream& ostream::_M_insert(long long);
+template ostream& ostream::_M_insert(unsigned long long);
+#endif
+template ostream& ostream::_M_insert(double);
+template ostream& ostream::_M_insert(long double);
+template ostream& ostream::_M_insert(const void*);
+
+#ifdef _GLIBCXX_USE_WCHAR_T
+template wostream& wostream::_M_insert(long);
+template wostream& wostream::_M_insert(unsigned long);
+template wostream& wostream::_M_insert(bool);
+#ifdef _GLIBCXX_USE_LONG_LONG
+template wostream& wostream::_M_insert(long long);
+template wostream& wostream::_M_insert(unsigned long long);
+#endif
+template wostream& wostream::_M_insert(double);
+template wostream& wostream::_M_insert(long double);
+template wostream& wostream::_M_insert(const void*);
+#endif
+
+// From istream.tcc
+template istream& istream::_M_extract(unsigned short&);
+template istream& istream::_M_extract(unsigned int&);
+template istream& istream::_M_extract(long&);
+template istream& istream::_M_extract(unsigned long&);
+template istream& istream::_M_extract(bool&);
+#ifdef _GLIBCXX_USE_LONG_LONG
+template istream& istream::_M_extract(long long&);
+template istream& istream::_M_extract(unsigned long long&);
+#endif
+template istream& istream::_M_extract(float&);
+template istream& istream::_M_extract(double&);
+template istream& istream::_M_extract(long double&);
+template istream& istream::_M_extract(void*&);
+
+#ifdef _GLIBCXX_USE_WCHAR_T
+template wistream& wistream::_M_extract(unsigned short&);
+template wistream& wistream::_M_extract(unsigned int&);
+template wistream& wistream::_M_extract(long&);
+template wistream& wistream::_M_extract(unsigned long&);
+template wistream& wistream::_M_extract(bool&);
+#ifdef _GLIBCXX_USE_LONG_LONG
+template wistream& wistream::_M_extract(long long&);
+template wistream& wistream::_M_extract(unsigned long long&);
+#endif
+template wistream& wistream::_M_extract(float&);
+template wistream& wistream::_M_extract(double&);
+template wistream& wistream::_M_extract(long double&);
+template wistream& wistream::_M_extract(void*&);
+#endif
+
+_GLIBCXX_END_NAMESPACE