<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="Generator" content="Microsoft Word 15 (filtered medium)">
<style><!--
/* Font Definitions */
@font-face
        {font-family:Wingdings;
        panose-1:5 0 0 0 0 0 0 0 0 0;}
@font-face
        {font-family:"Cambria Math";
        panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
        {font-family:"Lucida Console";
        panose-1:2 11 6 9 4 5 4 2 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:"Times New Roman","serif";}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:purple;
        text-decoration:underline;}
span.EmailStyle17
        {mso-style-type:personal-reply;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
span.apple-converted-space
        {mso-style-name:apple-converted-space;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-family:"Calibri","sans-serif";}
@page WordSection1
        {size:8.5in 11.0in;
        margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
</head>
<body lang="EN-US" link="blue" vlink="purple">
<div class="WordSection1">
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">Jack,<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">I have had this problem before.  For some reason, specifying the compiler(s) for consecutive runs of cmake is no good. 
<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">From http://www.cmake.org/Wiki/CMake_Useful_Variables<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-bottom:1.2pt;line-height:14.3pt;background:white">
<b><span style="font-size:10.0pt;font-family:"Arial","sans-serif";color:black">CMAKE_C_COMPILER <o:p></o:p></span></b></p>
<p class="MsoNormal" style="mso-margin-top-alt:0in;margin-right:0in;margin-bottom:1.2pt;margin-left:.5in;line-height:14.3pt;background:white">
<span style="font-size:10.0pt;font-family:"Arial","sans-serif";color:black">the compiler used for C files. Normally it is detected and set during the CMake run, but you can override it at configuration time. <b>Note!</b> It cannot be changed after the first
 cmake or ccmake run. Although the gui allows to enter an alternative, it will be ignored in the next 'configure' run. Use for <o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">It has to go like this:<o:p></o:p></span></p>
<p class="MsoNormal"><a name="_MailEndCompose">% cd openmp/runtime<o:p></o:p></a></p>
<p class="MsoNormal">% mkdir build<o:p></o:p></p>
<p class="MsoNormal">% cd build<o:p></o:p></p>
<p class="MsoNormal">% cmake -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++ -Darch=32 ..<o:p></o:p></p>
<p class="MsoNormal">...<o:p></o:p></p>
<p class="MsoNormal">% make<o:p></o:p></p>
<p class="MsoNormal">...<o:p></o:p></p>
<p class="MsoNormal">% cmake -Darch=32e ..<o:p></o:p></p>
<p class="MsoNormal">...<o:p></o:p></p>
<p class="MsoNormal">% make<o:p></o:p></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">Or this (adding rm –rf command):<o:p></o:p></span></p>
<p class="MsoNormal">% cd openmp/runtime<o:p></o:p></p>
<p class="MsoNormal">% mkdir build<o:p></o:p></p>
<p class="MsoNormal">% cd build<o:p></o:p></p>
<p class="MsoNormal">% cmake -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++ -Darch=32 ..<o:p></o:p></p>
<p class="MsoNormal">...<o:p></o:p></p>
<p class="MsoNormal">% make<o:p></o:p></p>
<p class="MsoNormal">...<o:p></o:p></p>
<p class="MsoNormal">% rm –rf *<o:p></o:p></p>
<p class="MsoNormal">% cmake -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++  -Darch=32e ..<o:p></o:p></p>
<p class="MsoNormal">...<o:p></o:p></p>
<p class="MsoNormal">% make<o:p></o:p></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">I’m not sure why it messes up so badly when specifying the compiler again.  It appears from the messages below that it thinks the objects from the previous
 IA-32 build are up to date.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">Something else you can try  is this (32e build first, 32 build second):<o:p></o:p></span></p>
<p class="MsoNormal">% cd openmp/runtime<o:p></o:p></p>
<p class="MsoNormal">% mkdir build<o:p></o:p></p>
<p class="MsoNormal">% cd build<o:p></o:p></p>
<p class="MsoNormal">% cmake -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++ -Darch=32e ..<o:p></o:p></p>
<p class="MsoNormal">...<o:p></o:p></p>
<p class="MsoNormal">% make<o:p></o:p></p>
<p class="MsoNormal">...<o:p></o:p></p>
<p class="MsoNormal">% cmake -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++  -Darch=32 ..<o:p></o:p></p>
<p class="MsoNormal">...<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">Your –Darch=32 will be ignored!  And the final configuration will show 32e. 
<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">The moral of the story: Only specify the compiler for the first run of cmake in a given build directory, or clean out the build directory for each cmake run.</span><o:p></o:p></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">Johnny<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><b><span style="font-size:11.0pt;font-family:"Calibri","sans-serif"">From:</span></b><span style="font-size:11.0pt;font-family:"Calibri","sans-serif""> Jack Howarth [mailto:howarth.mailing.lists@gmail.com]
<br>
<b>Sent:</b> Monday, June 9, 2014 2:50 PM<br>
<b>To:</b> Peyton, Jonathan L<br>
<b>Cc:</b> openmp-dev@dcs-maillist2.engr.illinois.edu<br>
<b>Subject:</b> Re: [Openmp-dev] Initial Intel Cmake Build System Patch<o:p></o:p></span></p>
<p class="MsoNormal"><o:p> </o:p></p>
<div>
<p class="MsoNormal">Jonathan,<o:p></o:p></p>
<div>
<p class="MsoNormal">     This doesn't seem to work for me on darwin12…<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal"><o:p> </o:p></p>
</div>
<div>
<p class="MsoNormal">% cd openmp/runtime<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">% mkdir build<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">% cd build<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">% cmake -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++ -Darch=32 ..<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">...<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">% make<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">...<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">% cmake -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++ -Darch=32e ..<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">...<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">% make<o:p></o:p></p>
</div>
<div>
<div>
<p class="MsoNormal">Scanning dependencies of target inc<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">[  0%] Generating ../exports/mac_32e/include_compat/iomp_lib.h<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">[  5%] Built target inc<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">Scanning dependencies of target needed-headers<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">[ 15%] Built target needed-headers<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">Scanning dependencies of target lib<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">[ 15%] Generating kmp_dummy.o<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">[ 21%] Generating external-objects.lst<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">warning: nm: no name list<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">[ 21%] Generating external-symbols.lst<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">[ 21%] Generating iomp.o<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">ld: warning: ld: warning: ld: warning: ignoring file kmp_version.o, file was built for i386 which is not the architecture being linked (x86_64): kmp_version.oignoring file kmp_ftn_extra.o, file was built for i386 which is not the architecture
 being linked (x86_64): kmp_ftn_extra.oignoring file kmp_ftn_cdecl.o, file was built for i386 which is not the architecture being linked (x86_64): kmp_ftn_cdecl.o<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal"><o:p> </o:p></p>
</div>
<div>
<p class="MsoNormal"><o:p> </o:p></p>
</div>
<div>
<p class="MsoNormal">ld: warning: ignoring file kmp_alloc.o, file was built for i386 which is not the architecture being linked (x86_64): kmp_alloc.o<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">ld: warning: ld: warning: ignoring file kmp_atomic.o, file was built for i386 which is not the architecture being linked (x86_64): kmp_atomic.oignoring file kmp_csupport.o, file was built for i386 which is not the architecture being linked
 (x86_64): kmp_csupport.o<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">ld: warning: <o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">ignoring file kmp_debug.o, file was built for i386 which is not the architecture being linked (x86_64): kmp_debug.o<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">ld: warning: ld: warning: ld: warning: ignoring file kmp_itt.o, file was built for i386 which is not the architecture being linked (x86_64): kmp_itt.oignoring file kmp_error.o, file was built for i386 which is not the architecture being
 linked (x86_64): kmp_error.old: warning: ignoring file kmp_environment.o, file was built for i386 which is not the architecture being linked (x86_64): kmp_environment.o<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal"><o:p> </o:p></p>
</div>
<div>
<p class="MsoNormal">ignoring file kmp_global.o, file was built for i386 which is not the architecture being linked (x86_64): kmp_global.o<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">ld: warning: <o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">ignoring file kmp_i18n.o, file was built for i386 which is not the architecture being linked (x86_64): kmp_i18n.old: warning: <o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">ignoring file kmp_io.o, file was built for i386 which is not the architecture being linked (x86_64): kmp_io.old: warning: ld: warning: <o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">ignoring file kmp_settings.o, file was built for i386 which is not the architecture being linked (x86_64): kmp_settings.oignoring file kmp_runtime.o, file was built for i386 which is not the architecture being linked (x86_64): kmp_runtime.o<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">ld: warning: <o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">ignoring file kmp_str.o, file was built for i386 which is not the architecture being linked (x86_64): kmp_str.o<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">ld: warning: ignoring file kmp_tasking.o, file was built for i386 which is not the architecture being linked (x86_64): kmp_tasking.o<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">ld: warning: ignoring file kmp_taskq.o, file was built for i386 which is not the architecture being linked (x86_64): kmp_taskq.o<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">ld: warning: ld: warning: ignoring file kmp_threadprivate.o, file was built for i386 which is not the architecture being linked (x86_64): kmp_threadprivate.oignoring file kmp_utility.o, file was built for i386 which is not the architecture
 being linked (x86_64): kmp_utility.old: warning: <o:p></o:p></p>
</div>
<div>
<p class="MsoNormal"><o:p> </o:p></p>
</div>
<div>
<p class="MsoNormal">ignoring file ittnotify_static.o, file was built for i386 which is not the architecture being linked (x86_64): ittnotify_static.old: warning: ld: warning: ld: warning: ld: warning: <o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">ld: warning: ignoring file z_Linux_util.o, file was built for i386 which is not the architecture being linked (x86_64): z_Linux_util.old: warning: ignoring file kmp_gsupport.o, file was built for i386 which is not the architecture being
 linked (x86_64): kmp_gsupport.old: warning: ignoring file kmp_affinity.o, file was built for i386 which is not the architecture being linked (x86_64): kmp_affinity.oignoring file kmp_dispatch.o, file was built for i386 which is not the architecture being linked
 (x86_64): kmp_dispatch.oignoring file kmp_sched.o, file was built for i386 which is not the architecture being linked (x86_64): kmp_sched.o<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">ignoring file kmp_lock.o, file was built for i386 which is not the architecture being linked (x86_64): kmp_lock.old: warning: <o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">ignoring file kmp_taskdeps.o, file was built for i386 which is not the architecture being linked (x86_64): kmp_taskdeps.o<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal"><o:p> </o:p></p>
</div>
<div>
<p class="MsoNormal"><o:p> </o:p></p>
</div>
<div>
<p class="MsoNormal"><o:p> </o:p></p>
</div>
<div>
<p class="MsoNormal">ignoring file kmp_cancel.o, file was built for i386 which is not the architecture being linked (x86_64): kmp_cancel.old: warning: <o:p></o:p></p>
</div>
<div>
<p class="MsoNormal"><o:p> </o:p></p>
</div>
<div>
<p class="MsoNormal">ignoring file z_Linux_asm.o, file was built for i386 which is not the architecture being linked (x86_64): z_Linux_asm.o<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">[ 26%] Generating unstripped/libiomp5.dylib<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">[ 26%] Generating libiomp5.dylib<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">[ 31%] Generating test-touch-rt/.success<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">Undefined symbols for architecture x86_64:<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">  "_omp_get_max_threads", referenced from:<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">      _main in test-touch-a2b314.o<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">  "_omp_get_num_threads", referenced from:<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">      _main in test-touch-a2b314.o<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">  "_omp_get_wtime", referenced from:<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">      _main in test-touch-a2b314.o<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">ld: symbol(s) not found for architecture x86_64<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">clang: error: linker command failed with exit code 1 (use -v to see invocation)<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">make[2]: *** [test-touch-rt/.success] Error 1<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">make[1]: *** [CMakeFiles/lib.dir/all] Error 2<o:p></o:p></p>
</div>
</div>
<div>
<p class="MsoNormal"><o:p> </o:p></p>
</div>
<div>
<p class="MsoNormal">You need to execute a limited form of make clean in between the two build the would delete the previous object files but not the previously built shared libraries. Does this already exist in the cmake support but is undocumented?<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">                         Jack<o:p></o:p></p>
</div>
</div>
<div>
<p class="MsoNormal" style="margin-bottom:12.0pt"><o:p> </o:p></p>
<div>
<p class="MsoNormal">On Mon, Jun 9, 2014 at 11:14 AM, Peyton, Jonathan L <<a href="mailto:jonathan.l.peyton@intel.com" target="_blank">jonathan.l.peyton@intel.com</a>> wrote:<o:p></o:p></p>
<blockquote style="border:none;border-left:solid #CCCCCC 1.0pt;padding:0in 0in 0in 6.0pt;margin-left:4.8pt;margin-right:0in">
<div>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">Jack,</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"> </span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">Right now, after you build the both the 32 and 32e libraries, you should be able to say “make fat”
 and it will call the lipo command for you.</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">Keep in mind, the system is setup so that cmake will only include the “fat” target when the configuration
 is for 32e, and it will not automatically build the libraries for you if you specify the “fat” target but both 32 and 32e libraries haven’t been built yet, only an error is spit out.  There are no plans to automate it further.</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"> </span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">There is some instruction on it in Build_With_CMake.txt.</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none">
<span style="font-size:10.0pt;font-family:"Lucida Console"">+Mac Fat Libraries</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none">
<span style="font-size:10.0pt;font-family:"Lucida Console"">+=================</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none">
<span style="font-size:10.0pt;font-family:"Lucida Console"">+On OS X machines, it is possible to build universal (or fat) libraries which</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none">
<span style="font-size:10.0pt;font-family:"Lucida Console"">+include both IA-32 architecture and Intel(R) 64 architecture objects in a</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none">
<span style="font-size:10.0pt;font-family:"Lucida Console"">+single archive; just build the 32 and 32e libraries separately:</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none">
<span style="font-size:10.0pt;font-family:"Lucida Console"">+ $ cmake -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++ -Darch=32 ..</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none">
<span style="font-size:10.0pt;font-family:"Lucida Console"">+ $ make</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none">
<span style="font-size:10.0pt;font-family:"Lucida Console"">+ $ cmake -Darch=32e ..</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none">
<span style="font-size:10.0pt;font-family:"Lucida Console"">+ $ make</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none">
<span style="font-size:10.0pt;font-family:"Lucida Console"">+then invoke make again with a special argument as follows:</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none">
<span style="font-size:10.0pt;font-family:"Lucida Console"">+ $ make fat</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none">
<span style="font-size:10.0pt;font-family:"Lucida Console"">+* The fat target is only available for the arch=32e configuration.</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none">
<span style="font-size:10.0pt;font-family:"Lucida Console"">+* The fat libraries will be put in exports/mac_32e/lib while the "thin" libraries</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none">
<span style="font-size:10.0pt;font-family:"Lucida Console"">+  will be in exports/mac_32e/lib.thin and exports/mac_32/lib.thin</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"> </span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">Johnny</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><a name="14681326f692e0dd__MailEndCompose"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"> </span></a><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><b><span style="font-size:11.0pt;font-family:"Calibri","sans-serif"">From:</span></b><span style="font-size:11.0pt;font-family:"Calibri","sans-serif""> Jack Howarth [mailto:<a href="mailto:howarth.mailing.lists@gmail.com" target="_blank">howarth.mailing.lists@gmail.com</a>]
<br>
<b>Sent:</b> Friday, June 6, 2014 8:42 PM<br>
<b>To:</b> Peyton, Jonathan L<br>
<b>Cc:</b> <a href="mailto:openmp-dev@dcs-maillist2.engr.illinois.edu" target="_blank">
openmp-dev@dcs-maillist2.engr.illinois.edu</a><br>
<b>Subject:</b> Re: [Openmp-dev] Initial Intel Cmake Build System Patch</span><o:p></o:p></p>
<div>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"> <o:p></o:p></p>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">Jonathon,<o:p></o:p></p>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">     Thanks. Confirmed to work properly on x86_64-apple-darwin12 with…<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"> <o:p></o:p></p>
</div>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">% cd runtime<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">% mkdir build<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">% cd build<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">% cmake -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++ -Dos=mac -Darch=32 ..<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">% make all common<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">% file libiomp5.dylib<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">libiomp5.dylib: Mach-O dynamically linked shared library i386<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"> <o:p></o:p></p>
</div>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">and<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"> <o:p></o:p></p>
</div>
<div>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">% cd runtime<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">% mkdir build<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">% cd build<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">% cmake -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++ -Dos=mac -Darch=32e ..<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">% make all common<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">% file libiomp5.dylib<o:p></o:p></p>
</div>
</div>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">libiomp5.dylib: Mach-O 64-bit dynamically linked shared library x86_64<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"> <o:p></o:p></p>
</div>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">Are there any plans to tweak this to automate the build of a fat libiomp5.dylib on darwin?<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"> <o:p></o:p></p>
</div>
</div>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;margin-bottom:12.0pt"> <o:p></o:p></p>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">On Fri, Jun 6, 2014 at 7:02 PM, Peyton, Jonathan L <<a href="mailto:jonathan.l.peyton@intel.com" target="_blank">jonathan.l.peyton@intel.com</a>> wrote:<o:p></o:p></p>
<blockquote style="border:none;border-left:solid #CCCCCC 1.0pt;padding:0in 0in 0in 6.0pt;margin-left:4.8pt;margin-top:5.0pt;margin-right:0in;margin-bottom:5.0pt">
<div>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">Hello All,<o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"> <o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">Since everyone wants to see it, this patch is the initial cmake build system we have been developing.  Some quick notes:<o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">1) The top-level CMakeLists.txt you all have been working on is moved to CMakeLists.txt.old (the src/CMakeLists.txt file is untouched)<o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">2) There is a Build_With_CMake.txt tutorial that shows the most important features and how to build libiomp5<o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">3) As a special note, the current
<a href="http://build.pl" target="_blank">build.pl</a> system does five “micro-tests” which test certain features of the newly built libiomp5.so library (basic linking/compilation, library dependencies, etc.)  If you want these to be off in the new CMake system
 just specify it when calling cmake with the flag –Dtests=off<o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"> <o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">Please keep in mind this is the initial system and that it can be trimmed back incrementally to what you need.  Right now, it builds nearly identical libraries as
<a href="http://build.pl" target="_blank">build.pl</a>.  On a related note, I attempted ( as suggested by David ) to port libiomp5 to NetBSD to see what walls I would hit.  I hit some
<span style="font-family:Wingdings">J</span> , but eventually got it working (not included in this initial patch).  So I am going to follow up this initial patch with further improvements (to the build system) to make re-targeting in general even easier.  Some
 of these improvements will also help the <a href="http://build.pl" target="_blank">
build.pl</a> system as well.<o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"> <o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">Just try it.  See what you hate and what you like.  Leave feedback.  I am here on weekdays.<o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"> <o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">Thanks,<o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">Johnny<o:p></o:p></p>
</div>
</div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;margin-bottom:12.0pt"><br>
_______________________________________________<br>
Openmp-dev mailing list<br>
<a href="mailto:Openmp-dev@dcs-maillist2.engr.illinois.edu" target="_blank">Openmp-dev@dcs-maillist2.engr.illinois.edu</a><br>
<a href="http://lists.cs.uiuc.edu/mailman/listinfo/openmp-dev" target="_blank">http://lists.cs.uiuc.edu/mailman/listinfo/openmp-dev</a><o:p></o:p></p>
</blockquote>
</div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"> <o:p></o:p></p>
</div>
</div>
</div>
</div>
</div>
</blockquote>
</div>
<p class="MsoNormal"><o:p> </o:p></p>
</div>
</div>
</body>
</html>