OpenSDE Packages Database (without history before r20070)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

67 lines
2.7 KiB

  1. # --- SDE-COPYRIGHT-NOTE-BEGIN ---
  2. # This copyright note is auto-generated by ./scripts/Create-CopyPatch.
  3. #
  4. # Filename: package/.../mysql/mysql-5.5.17-embedded-library-shared-1.patch
  5. # Copyright (C) 2012 The OpenSDE Project
  6. #
  7. # More information can be found in the files COPYING and README.
  8. #
  9. # This patch file is dual-licensed. It is available under the license the
  10. # patched project is licensed under, as long as it is an OpenSource license
  11. # as defined at http://www.opensource.org/ (e.g. BSD, X11) or under the terms
  12. # of the GNU General Public License as published by the Free Software
  13. # Foundation; either version 2 of the License, or (at your option) any later
  14. # version.
  15. # --- SDE-COPYRIGHT-NOTE-END ---
  16. Submitted By: Ragnar Thomsen (rthomsen at linuxfromscratch dot org)
  17. Date: 2012-03-21
  18. Initial Package Version: 5.5.17
  19. Origin: Gentoo Git
  20. Description: Fixes mysql to build a shared version of the embedded server library (libmysqld.so) used by amarok2
  21. === modified file 'cmake/libutils.cmake'
  22. --- a/cmake/libutils.cmake 2010-01-26 12:47:34 +0000
  23. +++ b/cmake/libutils.cmake 2010-03-04 21:19:38 +0000
  24. @@ -268,6 +268,16 @@ MACRO(MERGE_LIBRARIES)
  25. MYSQL_INSTALL_TARGETS(${TARGET} DESTINATION "${INSTALL_LIBDIR}" ${COMP})
  26. ENDIF()
  27. SET_TARGET_PROPERTIES(${TARGET} PROPERTIES LINK_INTERFACE_LIBRARIES "")
  28. +
  29. + IF(ARG_SHARED AND LINK_FLAG_NO_UNDEFINED)
  30. + # Do not allow undefined symbols in shared libraries
  31. + GET_TARGET_PROPERTY(TARGET_LINK_FLAGS ${TARGET} LINK_FLAGS)
  32. + IF(NOT TARGET_LINK_FLAGS)
  33. + SET(TARGET_LINK_FLAGS)
  34. + ENDIF()
  35. + SET_TARGET_PROPERTIES(${TARGET} PROPERTIES LINK_FLAGS
  36. + "${TARGET_LINK_FLAGS} ${LINK_FLAG_NO_UNDEFINED}")
  37. + ENDIF()
  38. ENDMACRO()
  39. FUNCTION(GET_DEPENDEND_OS_LIBS target result)
  40. === modified file 'libmysqld/CMakeLists.txt'
  41. --- a/libmysqld/CMakeLists.txt 2010-02-20 19:40:03 +0000
  42. +++ b/libmysqld/CMakeLists.txt 2010-03-04 21:19:38 +0000
  43. @@ -138,7 +138,17 @@ IF(MSVC)
  44. ${CMAKE_STATIC_LIBRARY_PREFIX}mysqld-debug)
  45. ENDIF()
  46. -IF(MSVC AND NOT DISABLE_SHARED)
  47. - MERGE_LIBRARIES(libmysqld SHARED ${LIBS} EXPORTS ${CLIENT_API_FUNCTIONS}
  48. - COMPONENT Embedded)
  49. +IF(NOT DISABLE_SHARED)
  50. + MERGE_LIBRARIES(libmysqld SHARED mysqlserver EXPORTS ${CLIENT_API_FUNCTIONS})
  51. + IF(UNIX)
  52. + # Name the shared library, handle versioning (provides same api as client library
  53. + # hence the same version)
  54. + SET_TARGET_PROPERTIES(libmysqld PROPERTIES
  55. + OUTPUT_NAME mysqld
  56. + VERSION "${SHARED_LIB_MAJOR_VERSION}.0.0"
  57. + SOVERSION "${SHARED_LIB_MAJOR_VERSION}")
  58. + # Clean direct output flags, as 2 targets have the same base name (libmysqld)
  59. + SET_TARGET_PROPERTIES(libmysqld PROPERTIES CLEAN_DIRECT_OUTPUT 1)
  60. + SET_TARGET_PROPERTIES(mysqlserver PROPERTIES CLEAN_DIRECT_OUTPUT 1)
  61. + ENDIF()
  62. ENDIF()