recipe 3.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123
  1. # Build recipe for dbus (with X11 support).
  2. #
  3. # Copyright (C) 2018, MMPG <mmpg@vp.pl>
  4. # Copyright (c) 2018 Matias Fonzo, <selk@dragora.org>.
  5. #
  6. # Licensed under the Apache License, Version 2.0 (the "License");
  7. # you may not use this file except in compliance with the License.
  8. # You may obtain a copy of the License at
  9. #
  10. # http://www.apache.org/licenses/LICENSE-2.0
  11. #
  12. # Unless required by applicable law or agreed to in writing, software
  13. # distributed under the License is distributed on an "AS IS" BASIS,
  14. # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  15. # See the License for the specific language governing permissions and
  16. # limitations under the License.
  17. program=dbus
  18. version=1.12.12
  19. release=1
  20. # Set 'outdir' for a nice and well-organized output directory
  21. outdir="${outdir}/${arch}/daemons"
  22. pkgname=dbus_x11
  23. # The installation of this package replaces to
  24. replace=dbus
  25. tarname=${program}-${version}.tar.gz
  26. # Remote source(s)
  27. fetch=http://dbus.freedesktop.org/releases/dbus/$tarname
  28. description="
  29. A system daemon and a per user login session daemon (with X11 support).
  30. The message bus is built on top of a general one-to-one message passing
  31. framework, which can be used by any two apps to communicate directly
  32. (without going through the message bus daemon).
  33. "
  34. homepage=http://www.freedesktop.org/wiki/Software/dbus/
  35. license="AFLv2.1 | GPLv2+"
  36. # Source documentation
  37. docs="AUTHORS COPYING ChangeLog NEWS README"
  38. docsdir="${docdir}/${program}-${version}"
  39. build()
  40. {
  41. set -e
  42. unpack "${tardir}/$tarname"
  43. cd "$srcdir"
  44. # Set sane permissions
  45. chmod -R u+w,go-w,a+rX-s .
  46. ./configure \
  47. CFLAGS="$QICFLAGS" CXXFLAGS="$QICXXFLAGS" LDFLAGS="$QILDFLAGS" \
  48. $configure_args \
  49. --libdir=/usr/lib${libSuffix} \
  50. --mandir=$mandir \
  51. --enable-static=no \
  52. --enable-shared=yes \
  53. --enable-debug=no \
  54. --enable-inotify \
  55. --enable-epoll \
  56. --enable-x11-autolaunch \
  57. --disable-systemd \
  58. --disable-selinux \
  59. --with-valgrind \
  60. --with-dbus-user=messagebus \
  61. --with-xml=expat \
  62. --with-console-auth-dir=/var/run/console \
  63. --with-system-pid-file=/var/run/dbus/dbus.pid \
  64. --with-system-socket=/var/run/dbus/system_bus_socket \
  65. --with-session-socket-dir=/tmp \
  66. --with-x \
  67. --build="$(cc -dumpmachine)"
  68. make -j${jobs} V=1
  69. make -j${jobs} DESTDIR="$destdir" install-strip
  70. # Compress and link man pages (if needed)
  71. if test -d "${destdir}/$mandir"
  72. then
  73. (
  74. cd "${destdir}/$mandir"
  75. find . -type f -exec lzip -9 '{}' +
  76. find . -type l | while read -r file
  77. do
  78. ln -sf "$(readlink -- "$file").lz" "${file}.lz"
  79. rm -- "$file"
  80. done
  81. )
  82. fi
  83. # Copy documentation
  84. mkdir -p "${destdir}${docsdir}"
  85. cp -p $docs "${destdir}${docsdir}/"
  86. # Install perp service for dbus
  87. mkdir -p "${destdir}/etc/perp/dbus"
  88. cp -p "${worktree}/archive/dbus/rc.log" \
  89. "${worktree}/archive/dbus/rc.main" \
  90. "${destdir}/etc/perp/dbus/"
  91. chmod 755 "${destdir}"/etc/perp/dbus/rc.*
  92. # Be an active service by default
  93. chmod +t "${destdir}/etc/perp/dbus"
  94. # To handle config file(s)
  95. touch "${destdir}/etc/dbus-1/.graft-config" \
  96. "${destdir}/etc/perp/dbus/.graft-config"
  97. }