Posts Tagged ‘build mariadb’

Building MySQL and MariaDB on Windows using Visual Studio 2012 Express versus Visual Studio 2010 Express

Friday, April 5th, 2013

I mentioned in a recent post (and another recent, related post) I was going to try Visual Studio 2012 Express (as opposed to VS 2010 Express) for building MySQL 5.6 and MariaDB 10.0. on Windows.

I followed the exact same steps, but MySQL 5.6.10 would not build without fatal errors in 2012 (whereas it worked fine with VS 2010). Unfortunately, the fail errors were not too descriptive, so not quite sure what to do yet to fix it. Here is a brief snippet for those interested:

...
Done Building Project "C:\...\bld\sql\udf_example.vcxproj" (default targets).
Done Building Project "C:\...\bld\ALL_BUILD.vcxproj" (default targets) -- FAILED.
Done Building Project "c:\...\bld\package.vcxproj" (default targets) -- FAILED.
...
Build FAILED.
...

"c:\mysql\mysql-5.6.10\bld\package.vcxproj" (default target) (1) ->
"C:\mysql\mysql-5.6.10\bld\ALL_BUILD.vcxproj" (default target) (2) ->
"C:\mysql\mysql-5.6.10\bld\plugin\audit_null\audit_null.vcxproj" (default target) (18) ->
"C:\mysql\mysql-5.6.10\bld\sql\mysqld.vcxproj" (default target) (19) ->
(Link target) ->
  mysqld.exp : error LNK2001: unresolved external symbol
  _xmm@7fffffffffffffff7fffffffffffffff [C:\mysql\mysql-5.6.10\bld\sql\mysqld.vcxproj]
  C:\mysql\mysql-5.6.10\bld\sql\RelWithDebInfo\mysqld.exe : fatal error LNK1120:
  1 unresolved externals [C:\mysql\mysql-5.6.10\bld\sql\mysqld.vcxproj]

    6 Warning(s)
    2 Error(s)

Time Elapsed 00:01:06.67

On the plus side, MariaDB 10.0.1 compiled just fine with both Visual Studio 2012 Express and Visual Studio 2010 Express! So I was really happy about that. :)

I thought I could just keep both VSs installed, but they don’t seem to want to play nice, even when specifying the following for the MySQL 5.6 build (perhaps that’s just me though):

cmake .. -G "Visual Studio 10"

So, if you are building your own on Windows, then you may want to keep the above in mind (my tests have been on Windows 7 64-bit, fwiw).

I’ll continue to test, and post anything useful if there’s something worth mentioning.

 

Related Build Links:

 

How to Build MariaDB 10.0 on Windows from Source Code

Tuesday, March 26th, 2013

I just wanted to share my steps for building MariaDB 10.0 on Windows (10.0.1 in this case):

cd maria-10.0.1
mkdir bld
cd bld
cmake .. -G "Visual Studio 10"
cmake --build . --config relwithdebinfo --target package

That’s it! The zip file is created right there in bld/.

Hope this helps. :)

 

How to Build MariaDB 5.5 on Windows from Source Code

Friday, May 25th, 2012

I built MariaDB 5.5.24 on Windows yesterday from source, so I just wanted to share my steps.

Here is the short version:

bzr branch lp:maria/5.5 maria-5.5
cd maria-5.5
mkdir bld
cd bld
cmake .. -G "Visual Studio 10"
cmake --build . --config relwithdebinfo --target package

Done! Nice, neat zip file is created right there.

Here is the longer version with outputs for those interested:

C:\mariadb-5.5>bzr branch lp:maria/5.5 maria-5.5
Connected (version 2.0, client Twisted)
Authentication (publickey) successful!
Secsh channel 1 opened.
Branched 3418 revision(s).

C:\mariadb-5.5>cd maria-5.5

C:\mariadb-5.5\maria-5.5>mkdir bld

C:\mariadb-5.5\maria-5.5>cd bld

C:\mariadb-5.5\maria-5.5\bld>cmake .. -G "Visual Studio 10"
-- Check for working C compiler using: Visual Studio 10
-- Check for working C compiler using: Visual Studio 10 -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working CXX compiler using: Visual Studio 10
-- Check for working CXX compiler using: Visual Studio 10 -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- MariaDB 5.5.24
-- Check size of void *
-- Check size of void * - done
-- Packaging as: mariadb-5.5.24-win32
-- Looking for include files CMAKE_HAVE_PTHREAD_H
-- Looking for include files CMAKE_HAVE_PTHREAD_H - not found.
-- Found Threads: TRUE
-- Looking for pthread_attr_getguardsize
-- Looking for pthread_attr_getguardsize - not found
-- Check size of time_t
-- Check size of time_t - done
-- Could NOT find Boost
-- Cannot find wix 3, installer project will not be generated
-- Looking for MFC
-- Looking for MFC - not found
-- Configuring done
-- Generating done
-- Build files have been written to: C:/mariadb-5.5/maria-5.5/bld

C:\mariadb-5.5\maria-5.5\bld>cmake --build . --config relwithdebinfo --target package
.......
lots of output
.......
C:\mariadb-5.5\maria-5.5\bld\...
C:\mariadb-5.5\maria-5.5\bld\...
C:\mariadb-5.5\maria-5.5\bld\...

    46 Warning(s)
    0 Error(s)

Time Elapsed 00:23:18.16

Success \o/

Package is named: mariadb-5.5.24-win32.zip

Full location:

C:\mariadb-5.5\maria-5.5\bld\mariadb-5.5.24-win32.zip

C:\Users\Chris>mysql -uroot -pmysql -P3313 -e"select version()"
+----------------+
| version()      |
+----------------+
| 5.5.24-MariaDB |
+----------------+

With XtraDB+ (i.e., InnoDB plugin is not enabled), it starts fine, and uses InnoDB version 1.1.8-24.1.

If you try to enable the original InnoDB plugin, note the library is now named ha_innodb.dll (or ha_innodb.so) instead of ha_innodb_plugin.dll (or ha_innodb_plugin.so), which is what it was named in MySQL/MariaDB 5.1. I discuss this topic in more detail here, if you’re interested.

Hope this helps.

Further resources:

Full Details on CMake here:

http://forge.mysql.com/wiki/CMake

For details on building on Linux, please see here:

http://kb.askmonty.org/en/source-building-mariadb-on-centos/
..
 

Maintaining (and Building) your MySQL Source Tree on Windows

Tuesday, January 24th, 2012

I just have one last post to round out my series on building MySQL and MariaDB on Windows.

Before, I showed how to obtain the latest source tree and build it. In this one, I simply want to show how easy it is to continue off of that.

So it’s been a week or so, and now you want the latest fixes:

  1. cd C:\mysql-5.5\mysql-5.5
  2. bzr pull
  3. cmake . -DBUILD_CONFIG=mysql_release
  4. VS: File -> Open -> Solution -> MySql.sln
  5. VS: Build -> Build Solution
  6. VS: Right-click “PACKAGE” -> Build (in “Solution Explorer” View)

Simple as that. :)

Your “no-install” package will be located at:

C:\mysql-5.5\mysql-5.5\mysql-5.5.21-win32.zip

Full Outputs for Reference:

C:\Users\Chris>cd C:\mysql-5.5\mysql-5.5
C:\mysql-5.5\mysql-5.5>bzr pull
Using saved parent location: bzr+ssh://bazaar.launchpad.net/%2Bbranch/mysql-server/5.5/
Connected (version 2.0, client Twisted)
Authentication (publickey) successful!
Secsh channel 1 opened.
+N  mysql-test/suite/innodb/r/innodb_bug12400341.result
+N  mysql-test/suite/innodb/t/innodb_bug12400341-master.opt
+N  mysql-test/suite/innodb/t/innodb_bug12400341.test
+N  mysql-test/suite/sys_vars/r/innodb_change_buffering_debug_basic.result
+N  mysql-test/suite/sys_vars/r/innodb_trx_rseg_n_slots_debug_basic.result
+N  mysql-test/suite/sys_vars/t/innodb_change_buffering_debug_basic.test
+N  mysql-test/suite/sys_vars/t/innodb_trx_rseg_n_slots_debug_basic.test
 M  CMakeLists.txt
 M  client/mysqldump.c
 M  cmd-line-utils/libedit/chartype.h
 M  cmd-line-utils/libedit/eln.c
 M  cmd-line-utils/libedit/readline.c
 M  mysql-test/collections/default.experimental
 M  mysql-test/extra/rpl_tests/rpl_extra_col_master.test
 M  mysql-test/include/show_slave_status.inc
 M  mysql-test/include/wait_for_slave_io_error.inc
 M  mysql-test/r/func_time.result
 M  mysql-test/r/key_cache.result
 M  mysql-test/r/mysqlcheck.result
 M  mysql-test/r/mysqldump.result
 M  mysql-test/r/partition_key_cache.result
 M  mysql-test/suite/binlog/r/binlog_stm_unsafe_warning.result
 M  mysql-test/suite/binlog/t/binlog_stm_unsafe_warning.test
 M  mysql-test/suite/rpl/r/rpl_log_pos.result
 M  mysql-test/suite/rpl/r/rpl_manual_change_index_file.result
 M  mysql-test/suite/rpl/r/rpl_packet.result
 M  mysql-test/suite/rpl/t/rpl_log_pos.test
 M  mysql-test/suite/rpl/t/rpl_manual_change_index_file.test
 M  mysql-test/suite/rpl/t/rpl_packet.test
 M  mysql-test/suite/sys_vars/r/all_vars.result
 M  mysql-test/suite/sys_vars/t/all_vars.test
 M  mysql-test/suite/sys_vars/t/disabled.def
 M  mysql-test/t/func_time.test
 M  mysql-test/t/key_cache.test
 M  mysql-test/t/mysqlcheck.test
 M  mysql-test/t/mysqldump.test
 M  mysql-test/t/partition_key_cache.test
 M  sql/item.cc
 M  sql/sql_admin.cc
 M  storage/innobase/buf/buf0buf.c
 M  storage/innobase/handler/ha_innodb.cc
 M  storage/innobase/ibuf/ibuf0ibuf.c
 M  storage/innobase/include/trx0rseg.ic
 M  storage/innobase/include/trx0sys.h
 M  storage/innobase/row/row0mysql.c
 M  storage/innobase/trx/trx0sys.c
 M  storage/myisam/mi_preload.c
All changes applied successfully.
Now on revision 3691.
C:\mysql-5.5\mysql-5.5>cmake . -DBUILD_CONFIG=mysql_release
-- MySQL 5.5.21
-- Configuring done
-- Generating done
-- Build files have been written to: C:/mysql-5.5/mysql-5.5

5. VS: Build -> Build Solution

1>------ Build started: Project: ZERO_CHECK, Configuration: Debug Win32 ------
1>Checking Build System
...
========== Build: 97 succeeded, 0 failed, 1 up-to-date, 10 skipped ==========

6. VS: Right-click “PACKAGE” -> Build

1>------ Build started: Project: INFO_BIN, Configuration: Debug Win32 ------
2>------ Build started: Project: INFO_SRC, Configuration: Debug Win32 ------
1>Build log was saved at "file://c:\mysql-5.5\mysql-5.5\INFO_BIN.dir\Debug\BuildLog.htm"
1>INFO_BIN - 0 error(s), 0 warning(s)
2>Build log was saved at "file://c:\mysql-5.5\mysql-5.5\INFO_SRC.dir\Debug\BuildLog.htm"
2>INFO_SRC - 0 error(s), 0 warning(s)
3>------ Build started: Project: PACKAGE, Configuration: Debug Win32 ------
3>
3>Performing Post-Build Event...
3>CPack: Create package using ZIP
3>CPack: Install projects
3>CPack: - Install project: MySQL
3>CPack: Compress package
3>CPack: Finalize package
3>CPack: Package C:/mysql-5.5/mysql-5.5/mysql-5.5.21-win32.zip generated.
3>Build log was saved at "file://c:\mysql-5.5\mysql-5.5\PACKAGE.dir\Debug\BuildLog.htm"
3>PACKAGE - 0 error(s), 0 warning(s)
========== Build: 3 succeeded, 0 failed, 96 up-to-date, 0 skipped ==========

 
 

..

 
 


Period Panties by Period Panteez Menstrual Underwear Menstruation PMS Panty