debian/0000755000000000000000000000000012252053550007165 5ustar debian/ruby-mysql2.examples0000644000000000000000000000001212111135572013123 0ustar examples/*debian/source/0000755000000000000000000000000012111135572010464 5ustar debian/source/format0000644000000000000000000000001412111135572011672 0ustar 3.0 (quilt) debian/rules0000755000000000000000000000131112245335022010240 0ustar #!/usr/bin/make -f #export DH_VERBOSE=1 # # Uncomment to ignore all test failures (but the tests will run anyway) #export DH_RUBY_IGNORE_TESTS=all # # Uncomment to ignore some test failures (but the tests will run anyway). # Valid values: #export DH_RUBY_IGNORE_TESTS=ruby1.8 ruby1.9.1 require-rubygems # # If you need to specify the .gemspec (eg there is more than one) #export DH_RUBY_GEMSPEC=gem.gemspec %: dh $@ --buildsystem=ruby --with ruby # need to start an mysqld instance to run the tests override_dh_auto_install: cp spec/configuration.yml.example spec/configuration.yml cp spec/my.cnf.example spec/my.cnf chmod +x debian/start_mysqld_and_auto_install.sh debian/start_mysqld_and_auto_install.sh debian/copyright0000644000000000000000000000247712111135572011131 0ustar Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ Upstream-Name: mysql2 Source: https://github.com/brianmario/mysql2 Files: * Copyright: 2012 Brian Lopez License: Expat Files: debian/* Copyright: 2012 Michael Franzl License: Expat License: Expat Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: . The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. . THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. debian/start_mysqld_and_auto_install.sh0000644000000000000000000000234412111135572015651 0ustar #!/bin/sh # # start_mysqld_and_auto_install.sh - starts an instance of mysqld before # auto_installing and running do_mysql's test suite. It is inspired by # debian/test_mysql.sh from libdbi-drivers source package. set -e MYTEMP_DIR=`mktemp -d` ME=`whoami` export MYSQL_UNIX_PORT=${MYTEMP_DIR}/mysql.sock DO_MYSQL_USER=root DO_MYSQL_PASS= DO_MYSQL_DBNAME=test DO_MYSQL_DATABASE=/${DO_MYSQL_DBNAME} mysql_install_db --no-defaults --datadir=${MYTEMP_DIR} --force --skip-name-resolve --user=${DO_MYSQL_USER} /usr/sbin/mysqld --no-defaults --user=${DO_MYSQL_USER} --socket=${MYSQL_UNIX_PORT} --datadir=${MYTEMP_DIR} --skip-networking & echo -n pinging mysqld. attempts=0 while ! /usr/bin/mysqladmin --socket=${MYSQL_UNIX_PORT} ping ; do sleep 3 attempts=$((attempts+1)) if [ ${attempts} -gt 10 ] ; then echo "skipping test, mysql server could not be contacted after 30 seconds" exit 0 fi done #mysql --socket=${MYSQL_UNIX_PORT} --execute "CREATE DATABASE ${DO_MYSQL_DBNAME};" mysql --socket=${MYSQL_UNIX_PORT} --execute "GRANT ALL PRIVILEGES ON ${DO_MYSQL_DBNAME}.* TO '${DO_MYSQL_USER}'@'localhost' IDENTIFIED BY '${DO_MYSQL_PASS}';" dh_auto_install /usr/bin/mysqladmin --socket=${MYSQL_UNIX_PORT} shutdown rm -rf ${MYTEMP_DIR} debian/ruby-tests.rake0000644000000000000000000000023212252030652012145 0ustar require 'rspec/core/rake_task' RSpec::Core::RakeTask.new(:spec) do |spec| spec.pattern = './spec/mysql2/**/*_spec.rb' end task :default => :spec debian/clean0000644000000000000000000000004312245335022010166 0ustar spec/configuration.yml spec/my.cnf debian/ruby-mysql2.docs0000644000000000000000000000001212111135572012235 0ustar README.md debian/control0000644000000000000000000000237112252053525010575 0ustar Source: ruby-mysql2 Section: ruby Priority: optional Maintainer: Debian Ruby Extras Maintainers Uploaders: Michael Franzl , Cédric Boutillier Build-Depends: debhelper (>= 7.0.50~), gem2deb (>= 0.2.13~), libmysqld-dev, mysql-server, ruby-rspec, rake Standards-Version: 3.9.4 Vcs-Git: git://anonscm.debian.org/pkg-ruby-extras/ruby-mysql2.git Vcs-Browser: http://anonscm.debian.org/gitweb?p=pkg-ruby-extras/ruby-mysql2.git;a=summary Homepage: http://github.com/brianmario/mysql2 XS-Ruby-Versions: all Package: ruby-mysql2 Architecture: any XB-Ruby-Versions: ${ruby:Versions} Depends: ${shlibs:Depends}, ${misc:Depends}, ruby | ruby-interpreter, ruby-eventmachine Description: simple, fast MySQL library for Ruby This is an API module that allows Ruby programs to interface with MySQL databases. Usually, it will be pulled in automatically by packages providing Ruby programs which need this capability, you only need to install it directly if you intend to write such programs yourself. You may want to prefer the ruby-mysql2 package over the ruby-mysql package, since benchmarks have shown it to be faster, it is non-blocking and it supports UTF-8 database encoding. debian/changelog0000644000000000000000000000144312252053550011041 0ustar ruby-mysql2 (0.3.14-2) unstable; urgency=medium * Add myself to Uploaders. * Do not run eventmachine tests until it is fixed on freebsd. -- Cédric Boutillier Wed, 11 Dec 2013 10:36:13 +0100 ruby-mysql2 (0.3.14-1) unstable; urgency=low * Team upload * Imported Upstream version 0.3.14 + add support for Ruby 2.0 (Closes: #720227) * Use canonical URI in Vcs-* fields * Copy example configuration in spec/ for use in tests * Refresh remove_rpath_compilation_flag.patch * Do not try to install inexistant CHANGELOG.md -- Cédric Boutillier Tue, 26 Nov 2013 16:16:45 +0100 ruby-mysql2 (0.3.11-1) unstable; urgency=low * Initial release (Closes: #691150) -- Michael Franzl Thu, 01 Nov 2012 12:05:27 +0100 debian/patches/0000755000000000000000000000000012245335022010613 5ustar debian/patches/remove_rubygems_from_examples.patch0000644000000000000000000000134512111135572017772 0ustar Description: Remove rubygems from examples This patch modifies the examples so that they do not use rubygems, and don't modify the LOAD_PATH. The library will be installed in a place where ruby can find it, and the relative path ../lib is not valid anymore. Author: Michael Franzl --- ruby-mysql2-0.3.11.orig/examples/eventmachine.rb +++ ruby-mysql2-0.3.11/examples/eventmachine.rb @@ -1,8 +1,6 @@ # encoding: utf-8 -$LOAD_PATH.unshift 'lib' -require 'rubygems' require 'eventmachine' require 'mysql2/em' --- ruby-mysql2-0.3.11.orig/examples/threaded.rb +++ ruby-mysql2-0.3.11/examples/threaded.rb @@ -1,6 +1,5 @@ # encoding: utf-8 -$LOAD_PATH.unshift 'lib' require 'mysql2' require 'timeout' debian/patches/series0000644000000000000000000000011012111135572012020 0ustar remove_rpath_compilation_flag.patch remove_rubygems_from_examples.patch debian/patches/remove_rpath_compilation_flag.patch0000644000000000000000000000330112245335022017713 0ustar Description: Remove rpath from compilation flags This patch is required to pass the binary-or-shlib-defines-rpath lintian test. To fix this problem, any attempt to add rpath to $LDFLAGS inside of ext/mysql2/extconf.rb is patched out Author: Michael Franzl Last-Update: 2013-11-26 --- a/ext/mysql2/extconf.rb +++ b/ext/mysql2/extconf.rb @@ -98,33 +98,4 @@ $CFLAGS << gcc_flags end -case explicit_rpath = with_config('mysql-rpath') -when true - abort "-----\nOption --with-mysql-rpath must have an argument\n-----" -when false - warn "-----\nOption --with-mysql-rpath has been disabled at your request\n-----" -when String - # The user gave us a value so use it - rpath_flags = " -Wl,-rpath,#{explicit_rpath}" - warn "-----\nSetting mysql rpath to #{explicit_rpath}\n-----" - $LDFLAGS << rpath_flags -else - if libdir = rpath_dir[%r{(-L)?(/[^ ]+)}, 2] - rpath_flags = " -Wl,-rpath,#{libdir}" - if RbConfig::CONFIG["RPATHFLAG"].to_s.empty? && try_link('int main() {return 0;}', rpath_flags) - # Usually Ruby sets RPATHFLAG the right way for each system, but not on OS X. - warn "-----\nSetting rpath to #{libdir}\n-----" - $LDFLAGS << rpath_flags - else - if RbConfig::CONFIG["RPATHFLAG"].to_s.empty? - # If we got here because try_link failed, warn the user - warn "-----\nDon't know how to set rpath on your system, if MySQL libraries are not in path mysql2 may not load\n-----" - end - # Make sure that LIBPATH gets set if we didn't explicitly set the rpath. - warn "-----\nSetting libpath to #{libdir}\n-----" - $LIBPATH << libdir unless $LIBPATH.include?(libdir) - end - end -end - create_makefile('mysql2/mysql2') debian/watch0000644000000000000000000000014112111135572010211 0ustar version=3 http://pkg-ruby-extras.alioth.debian.org/cgi-bin/gemwatch/mysql2 .*/mysql2-(.*).tar.gz debian/compat0000644000000000000000000000000212111135572010362 0ustar 7