C++ linker warning because of virtual destructor / clang
<p>I'm getting a linker warning caused by virtual destructors. My environment is the KEIL compiler v6.5 (clang).  </p>

<pre class="lang-none prettyprint-override"><code>Warning: L6439W: Multiply defined Global Symbol __clang_call_terminate defined in invalid_group(new.cpp.o) rejected in favor of Symbol defined in .text.__clang_call_terminate(cxa_handlers.cpp.o).
</code></pre>

<p>I get this warning as soon as I add the virtual destructor to an interface. For example:</p>

<pre><code>class IInterface {
  virtual ~IInterface(){}

  virtual void doSomething() const = 0;
}
</code></pre>

<p>As soon as I implement one single derived class of this interface I get the above mentioned warning. As soon as I remove the virtual destructor, the warning vanishes.</p>

<p>I tried really many things to find out what's the reason, but didn't succeed...</p>

<p>Does someone know how to fix this warning?</p>

<p>Thank you!</p>

<p>Edit: A complete example throwing this warning:</p>

<pre><code>class IInterface {
  public:
  virtual ~IInterface();

  virtual void doSomething() = 0;
};

IInterface::~IInterface() {

}

class SomeClass : public IInterface {
  public:
  virtual void doSomething();
};

void SomeClass::doSomething() {

}

int main() {

}
</code></pre>