Bug #49502 CMake error compiling 5.1 on Windows
Submitted: 7 Dec 2009 11:32 Modified: 12 Mar 2010 14:43
Reporter: Miguel Solorzano Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Server: Compiling Severity:S3 (Non-critical)
Version:5.1 OS:Windows (Vista 64-bit)
Assigned to: Satya B CPU Architecture:Any

[7 Dec 2009 11:32] Miguel Solorzano
Description:
When running:

c:\build\5.1-build>win\build-vs8_x64.bat

the below errors are displayed:

c:\build\5.1-build>win\build-vs8_x64.bat
The system cannot find the file specified.
-- Check for working C compiler: cl
-- Check for working C compiler: cl -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working CXX compiler: cl
-- Check for working CXX compiler: cl -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detected 64-bit platform.
build ARCHIVE as static library
build BLACKHOLE as static library
build CSV as static library
build FEDERATED as static library
build HEAP as static library
build MYISAM as static library
build MYISAMMRG as static library
build EXAMPLE as DLL
build INNOBASE as DLL
CMake Error at storage/mysql_storage_engine.cmake:36 (ADD_LIBRARY):
  add_library cannot create target "ha_innobase" because another target with
  the same name already exists.  The existing target is a shared library
  created in source directory "C:/build/5.1-build/storage/innobase".  See
  documentation for policy CMP0002 for more details.
Call Stack (most recent call first):
  storage/innodb_plugin/CMakeLists.txt:84 (MYSQL_STORAGE_ENGINE)

CMake Error: Attempt to add link library "mysqld" to target "ha_innobase" which is not built by this project.
build INNOBASE as DLL
-- Configuring incomplete, errors occurred!
        1 file(s) copied.

How to repeat:
see description

Suggested fix:
-
[7 Dec 2009 18:02] MySQL Verification Team
Bug http://bugs.mysql.com/bug.php?id=49518 marked as duplicate of this one.
[14 Dec 2009 8:12] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/93844

3268 Satya B	2009-12-14
      Fix for BUG#49502 - CMake error compiling 5.1 on Windows
      
      When applying innodb snapshot 1.0.6 the storage engine name for innodb plugin
      under windows was changed from INNODB_PLUGIN to INNOBASE.
      
      This is a wrong and changing back the name to INNODB_PLUGIN.
     @ storage/innodb_plugin/CMakeLists.txt
        Fix for BUG#49502 - CMake error compiling 5.1 on Windows
        
        Change the storage engine name to INNODB_PLUGIN in CMakeLists.txt
[14 Dec 2009 8:39] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/93848

3766 Satya B	2009-12-14 [merge]
      NULL Merge Fix for BUG#49502 from mysql-5.1-bugteam to mysql-pe
      
      Not applicable in 6.0
[14 Dec 2009 10:09] Satya B
patch queued to mysql-5.1-bugteam and NULL merged to mysql-pe
[19 Dec 2009 8:28] Bugs System
Pushed into 6.0.14-alpha (revid:alik@sun.com-20091219082307-f3i4fn0tm8trb3c0) (version source revid:alik@sun.com-20091216180721-eoa754i79j4ssd3m) (merge vers: 6.0.14-alpha) (pib:15)
[19 Dec 2009 8:32] Bugs System
Pushed into 5.5.1-m2 (revid:alik@sun.com-20091219082021-f34nq4jytwamozz0) (version source revid:alexey.kopytov@sun.com-20091216134707-o96eqw0u2ynvo9gm) (merge vers: 5.5.0-beta) (pib:15)
[19 Dec 2009 8:36] Bugs System
Pushed into mysql-next-mr (revid:alik@sun.com-20091219082213-nhjjgmphote4ntxj) (version source revid:alik@sun.com-20091216180221-a5ps59gajad3pip9) (pib:15)
[5 Jan 2010 11:57] MC Brown
A note has been added to the 5.5.1 and 6.0.15 changelogs: 

When compiling on Windows, an error in the CMake definitions for <literal>InnoDB</literal> would cause the engine to be built incorrectly and the build incorrectly.
[15 Jan 2010 9:02] Bugs System
Pushed into 5.1.43 (revid:joro@sun.com-20100115085139-qkh0i0fpohd9u9p5) (version source revid:satya.bn@sun.com-20091214081226-zqu4044n9h5i0hpa) (merge vers: 5.1.42) (pib:16)
[15 Jan 2010 14:30] MC Brown
Entry added to the 5.1.43 changelog
[12 Mar 2010 14:08] Bugs System
Pushed into 5.1.44-ndb-7.0.14 (revid:jonas@mysql.com-20100312135944-t0z8s1da2orvl66x) (version source revid:jonas@mysql.com-20100312115609-woou0te4a6s4ae9y) (merge vers: 5.1.44-ndb-7.0.14) (pib:16)
[12 Mar 2010 14:24] Bugs System
Pushed into 5.1.44-ndb-6.2.19 (revid:jonas@mysql.com-20100312134846-tuqhd9w3tv4xgl3d) (version source revid:jonas@mysql.com-20100312060623-mx6407w2vx76h3by) (merge vers: 5.1.44-ndb-6.2.19) (pib:16)
[12 Mar 2010 14:38] Bugs System
Pushed into 5.1.44-ndb-6.3.33 (revid:jonas@mysql.com-20100312135724-xcw8vw2lu3mijrhn) (version source revid:jonas@mysql.com-20100312103652-snkltsd197l7q2yg) (merge vers: 5.1.44-ndb-6.3.33) (pib:16)
[12 Mar 2010 14:43] MC Brown
No changelog entry required