<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Linker errors in __init_cpp_exceptions and __fini_cpp_exceptions in Classic/Legacy CodeWarrior</title>
    <link>https://community.nxp.com/t5/Classic-Legacy-CodeWarrior/Linker-errors-in-init-cpp-exceptions-and-fini-cpp-exceptions/m-p/145525#M1702</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks a lot for the reply.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The initial project is a C project which is running properly without any errors. Now what I am trying to do is to write an application which is in C++.&lt;/P&gt;&lt;P&gt;If I create a seperate C++ project it works fine which means CW is taking the C++ libraries properly and linking them.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Now 2 things are not clear to me:&lt;/P&gt;&lt;P&gt;1. Libraries are stored in&lt;/P&gt;&lt;P&gt;&amp;lt;MWERKS_INSTALL_PATH&amp;gt;\CodeWarrior PowerPC Comm V8.5\PowerPC_EABI_Support\Runtime\Lib﻿\&amp;nbsp;&lt;/P&gt;&lt;P&gt;Which library is used by default, there are so many variants &lt;EM&gt;(Runtime.PPCEABI.A/E/N/NC/S&lt;/EM&gt;) ??&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;2. What is the need of following code in file __init_cpp_exceptions.cpp﻿ ?? Coz the two highlighed lines are giving me the errors.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;#if __MWERKS__ &amp;amp;&amp;amp; __PPC_EABI__&lt;BR /&gt;#pragma section ".ctors$10"&lt;BR /&gt;__declspec(section ".ctors$10")&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;STRONG&gt;extern void * const __init_cpp_exceptions_reference = __init_cpp_exceptions;&lt;/STRONG&gt;&lt;BR /&gt;#if __dest_os != __eppc_vxworks&lt;BR /&gt;#pragma section ".dtors$10"&lt;BR /&gt;__declspec(section ".dtors$10")&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; extern void * const __destroy_global_chain_reference = __destroy_global_chain;&lt;BR /&gt;#pragma section ".dtors$15"&lt;BR /&gt;__declspec(section ".dtors$15")&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;STRONG&gt;extern void * const __fini_cpp_exceptions_reference = __fini_cpp_exceptions;&lt;/STRONG&gt;&lt;BR /&gt;#endif&amp;nbsp;&amp;nbsp;&amp;nbsp; /* __dest_os != __eppc_vxworks */&lt;BR /&gt;#endif&amp;nbsp;&amp;nbsp;&amp;nbsp; /* __MWERKS__ &amp;amp;&amp;amp; __PPC_EABI__ */﻿&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks !!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 05 Jul 2011 21:02:28 GMT</pubDate>
    <dc:creator>cw_Potz</dc:creator>
    <dc:date>2011-07-05T21:02:28Z</dc:date>
    <item>
      <title>Linker errors in __init_cpp_exceptions and __fini_cpp_exceptions</title>
      <link>https://community.nxp.com/t5/Classic-Legacy-CodeWarrior/Linker-errors-in-init-cpp-exceptions-and-fini-cpp-exceptions/m-p/145523#M1700</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello all,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am newbie to CW. I am trying to run a project which is a mix of C and C++.&lt;/P&gt;&lt;P&gt;The project includes a static library which has both C and C++ code. There are no compilation errors but I am getting some strange linking errors:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;Link Error: Undefined : '__init_cpp_exceptions'&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;Referenced from '__init_cpp_exceptions_reference' in Linker Generated File&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;Link Error: Undefined : '__fini_cpp_exceptions'&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;Referenced from '__fini_cpp_exceptions_reference' in Linker Generated File&lt;/EM&gt; &lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am using PowerPC EABI Linker. Version: Code Warrior PowerPC ISA, Release 8.5 Build 50425.&lt;/P&gt;&lt;P&gt;Any ideas ?&lt;/P&gt;&lt;P&gt;TIA&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 30 Jun 2011 19:48:52 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Classic-Legacy-CodeWarrior/Linker-errors-in-init-cpp-exceptions-and-fini-cpp-exceptions/m-p/145523#M1700</guid>
      <dc:creator>cw_Potz</dc:creator>
      <dc:date>2011-06-30T19:48:52Z</dc:date>
    </item>
    <item>
      <title>Re: Linker errors in __init_cpp_exceptions and __fini_cpp_exceptions</title>
      <link>https://community.nxp.com/t5/Classic-Legacy-CodeWarrior/Linker-errors-in-init-cpp-exceptions-and-fini-cpp-exceptions/m-p/145524#M1701</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;It looks like your project is not using the appropriate library for C++.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;When you created your project did you indicate you are goingto program in C++?&lt;/P&gt;&lt;P&gt;Can you create a new project using the wizard and make sure you indicate the appropriate language in there?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;CrasyCat&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 05 Jul 2011 16:20:03 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Classic-Legacy-CodeWarrior/Linker-errors-in-init-cpp-exceptions-and-fini-cpp-exceptions/m-p/145524#M1701</guid>
      <dc:creator>CrasyCat</dc:creator>
      <dc:date>2011-07-05T16:20:03Z</dc:date>
    </item>
    <item>
      <title>Re: Linker errors in __init_cpp_exceptions and __fini_cpp_exceptions</title>
      <link>https://community.nxp.com/t5/Classic-Legacy-CodeWarrior/Linker-errors-in-init-cpp-exceptions-and-fini-cpp-exceptions/m-p/145525#M1702</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks a lot for the reply.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The initial project is a C project which is running properly without any errors. Now what I am trying to do is to write an application which is in C++.&lt;/P&gt;&lt;P&gt;If I create a seperate C++ project it works fine which means CW is taking the C++ libraries properly and linking them.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Now 2 things are not clear to me:&lt;/P&gt;&lt;P&gt;1. Libraries are stored in&lt;/P&gt;&lt;P&gt;&amp;lt;MWERKS_INSTALL_PATH&amp;gt;\CodeWarrior PowerPC Comm V8.5\PowerPC_EABI_Support\Runtime\Lib﻿\&amp;nbsp;&lt;/P&gt;&lt;P&gt;Which library is used by default, there are so many variants &lt;EM&gt;(Runtime.PPCEABI.A/E/N/NC/S&lt;/EM&gt;) ??&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;2. What is the need of following code in file __init_cpp_exceptions.cpp﻿ ?? Coz the two highlighed lines are giving me the errors.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;#if __MWERKS__ &amp;amp;&amp;amp; __PPC_EABI__&lt;BR /&gt;#pragma section ".ctors$10"&lt;BR /&gt;__declspec(section ".ctors$10")&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;STRONG&gt;extern void * const __init_cpp_exceptions_reference = __init_cpp_exceptions;&lt;/STRONG&gt;&lt;BR /&gt;#if __dest_os != __eppc_vxworks&lt;BR /&gt;#pragma section ".dtors$10"&lt;BR /&gt;__declspec(section ".dtors$10")&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; extern void * const __destroy_global_chain_reference = __destroy_global_chain;&lt;BR /&gt;#pragma section ".dtors$15"&lt;BR /&gt;__declspec(section ".dtors$15")&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;STRONG&gt;extern void * const __fini_cpp_exceptions_reference = __fini_cpp_exceptions;&lt;/STRONG&gt;&lt;BR /&gt;#endif&amp;nbsp;&amp;nbsp;&amp;nbsp; /* __dest_os != __eppc_vxworks */&lt;BR /&gt;#endif&amp;nbsp;&amp;nbsp;&amp;nbsp; /* __MWERKS__ &amp;amp;&amp;amp; __PPC_EABI__ */﻿&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks !!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 05 Jul 2011 21:02:28 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Classic-Legacy-CodeWarrior/Linker-errors-in-init-cpp-exceptions-and-fini-cpp-exceptions/m-p/145525#M1702</guid>
      <dc:creator>cw_Potz</dc:creator>
      <dc:date>2011-07-05T21:02:28Z</dc:date>
    </item>
    <item>
      <title>Re: Linker errors in __init_cpp_exceptions and __fini_cpp_exceptions</title>
      <link>https://community.nxp.com/t5/Classic-Legacy-CodeWarrior/Linker-errors-in-init-cpp-exceptions-and-fini-cpp-exceptions/m-p/145526#M1703</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;gt;1. Which library is used by default, there are so many variants &lt;EM&gt;(Runtime.PPCEABI.A/E/N/NC/S&lt;/EM&gt;) ??&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The library you need to link to your application depends on the compiler options you are using.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Check MWERKS_INSTALL_PATH&amp;gt;\Help\PDF\Power Arch Build Tools Reference.pdf. There is a chapter &lt;EM&gt;&lt;STRONG&gt;Library and Support Code&lt;/STRONG&gt;&lt;/EM&gt; and a section Choosing an MSL Library there. This section describes the naming convention used for the library names.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;gt; 2. What is the need of following code in file __init_cpp_exceptions.cpp﻿ ??&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This defines a pointer to the section containing constructors and destructors for global class objects.&lt;/P&gt;&lt;P&gt;Are you getting the messages in the C++ application you created with the wizard?&lt;/P&gt;&lt;P&gt;As far as I remember the symbols __init_cpp_exceptions and __fini_cpp_exceptions are defined in the linker file (.lcf).&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;CrasyCat&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 06 Jul 2011 14:26:34 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Classic-Legacy-CodeWarrior/Linker-errors-in-init-cpp-exceptions-and-fini-cpp-exceptions/m-p/145526#M1703</guid>
      <dc:creator>CrasyCat</dc:creator>
      <dc:date>2011-07-06T14:26:34Z</dc:date>
    </item>
    <item>
      <title>Re: Linker errors in __init_cpp_exceptions and __fini_cpp_exceptions</title>
      <link>https://community.nxp.com/t5/Classic-Legacy-CodeWarrior/Linker-errors-in-init-cpp-exceptions-and-fini-cpp-exceptions/m-p/145527#M1704</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi CrasyCat,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks a lot for your help. Actually with my installation of CW the file ''Power Arch Build Tools Reference.pdf﻿'' was missing. Its quite informative and helpful.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;When I create a new C++ application with the wizard there are no errors or warnings.&lt;/P&gt;&lt;P&gt;And __init_cpp_exceptions and __fini_cpp_exceptions ﻿are functions defined in&amp;nbsp;__init_cpp_exceptions.cpp﻿ file (?) My project has its own linker command file where these 2 symbols are not defined.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 06 Jul 2011 21:27:11 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Classic-Legacy-CodeWarrior/Linker-errors-in-init-cpp-exceptions-and-fini-cpp-exceptions/m-p/145527#M1704</guid>
      <dc:creator>cw_Potz</dc:creator>
      <dc:date>2011-07-06T21:27:11Z</dc:date>
    </item>
    <item>
      <title>Re: Linker errors in __init_cpp_exceptions and __fini_cpp_exceptions</title>
      <link>https://community.nxp.com/t5/Classic-Legacy-CodeWarrior/Linker-errors-in-init-cpp-exceptions-and-fini-cpp-exceptions/m-p/145528#M1705</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;If you are able to build the newly created C++ project, I would recommend you&amp;nbsp;start from there and add the required source files and configuration, instead of trying to re-invent the wheel,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;CrasyCat&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 07 Jul 2011 20:07:03 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Classic-Legacy-CodeWarrior/Linker-errors-in-init-cpp-exceptions-and-fini-cpp-exceptions/m-p/145528#M1705</guid>
      <dc:creator>CrasyCat</dc:creator>
      <dc:date>2011-07-07T20:07:03Z</dc:date>
    </item>
  </channel>
</rss>

