compton.scm 5.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155
  1. ;;; GNU Guix --- Functional package management for GNU
  2. ;;; Copyright © 2017 José Miguel Sánchez García <jmi2k@openmailbox.org>
  3. ;;; Copyright © 2018 Tobias Geerinckx-Rice <me@tobias.gr>
  4. ;;; Copyright © 2019 Alexandru-Sergiu Marton <brown121407@member.fsf.org>
  5. ;;; Copyright © 2019 Brett Gilio <brettg@gnu.org>
  6. ;;; Copyright © 2022 Jai Vetrivelan <jaivetrivelan@gmail.com>
  7. ;;;
  8. ;;; This file is part of GNU Guix.
  9. ;;;
  10. ;;; GNU Guix is free software; you can redistribute it and/or modify it
  11. ;;; under the terms of the GNU General Public License as published by
  12. ;;; the Free Software Foundation; either version 3 of the License, or (at
  13. ;;; your option) any later version.
  14. ;;;
  15. ;;; GNU Guix is distributed in the hope that it will be useful, but
  16. ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
  17. ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  18. ;;; GNU General Public License for more details.
  19. ;;;
  20. ;;; You should have received a copy of the GNU General Public License
  21. ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
  22. (define-module (gnu packages compton)
  23. #:use-module ((guix licenses) #:prefix license:)
  24. #:use-module (guix packages)
  25. #:use-module (guix git-download)
  26. #:use-module (guix build-system gnu)
  27. #:use-module (guix build-system meson)
  28. #:use-module (gnu packages datastructures)
  29. #:use-module (gnu packages docbook)
  30. #:use-module (gnu packages documentation)
  31. #:use-module (gnu packages freedesktop)
  32. #:use-module (gnu packages gl)
  33. #:use-module (gnu packages glib)
  34. #:use-module (gnu packages libevent)
  35. #:use-module (gnu packages pcre)
  36. #:use-module (gnu packages pkg-config)
  37. #:use-module (gnu packages python)
  38. #:use-module (gnu packages textutils)
  39. #:use-module (gnu packages xdisorg)
  40. #:use-module (gnu packages xml)
  41. #:use-module (gnu packages xorg))
  42. (define-public compton
  43. (let ((upstream-version "0.1_beta2"))
  44. (package
  45. (name "compton")
  46. (version (string-filter (char-set-complement (char-set #\_))
  47. upstream-version))
  48. (source
  49. (origin
  50. (method git-fetch)
  51. (uri (git-reference
  52. (url "https://github.com/chjj/compton")
  53. (commit (string-append "v" upstream-version))))
  54. (sha256
  55. (base32
  56. "0v65viilhnd2xgvmdpzc1srxszcg8kj1vhi5gy9292j48w0s2fx1"))
  57. (file-name (git-file-name name version))))
  58. (build-system gnu-build-system)
  59. (inputs
  60. (list dbus
  61. libconfig
  62. libx11
  63. libxcomposite
  64. libxdamage
  65. libxext
  66. libxfixes
  67. libxinerama
  68. libxrandr
  69. libxrender
  70. mesa
  71. xprop
  72. xwininfo))
  73. (native-inputs
  74. (list asciidoc libdrm pkg-config python xorgproto))
  75. (arguments
  76. `(#:make-flags (list
  77. "CC=gcc"
  78. "NO_REGEX_PCRE=1" ; pcre makes build fail
  79. (string-append "PREFIX=" (assoc-ref %outputs "out")))
  80. #:tests? #f ; no tests
  81. #:phases
  82. (modify-phases %standard-phases
  83. (delete 'configure))))
  84. (home-page "https://github.com/chjj/compton")
  85. (synopsis "Compositor for X11")
  86. (description
  87. "Compton is a compositor for the Xorg display server and a for of
  88. xcompmgr-dana, which implements some changes like:
  89. @itemize
  90. @item OpenGL backend (@command{--backend glx}), in addition to the old X Render
  91. backend.
  92. @item Inactive window transparency (@command{-i}) and dimming
  93. (@command{--inactive-dim}).
  94. @item Menu transparency (@command{-m}, thanks to Dana).
  95. @item Shadows are now enabled for argb windows, e.g terminals with transparency
  96. @item Removed serverside shadows (and simple compositing) to clean the code,
  97. the only option that remains is clientside shadows.
  98. @item Configuration files (see the man page for more details).
  99. @item Colored shadows (@command{--shadow-[red/green/blue]}).
  100. @item A new fade system.
  101. @item VSync support (not always working).
  102. @item Blur of background of transparent windows, window color inversion (bad in
  103. performance).
  104. @item Some more options...
  105. @end itemize\n")
  106. (license license:expat))))
  107. (define-public picom
  108. (package
  109. (name "picom")
  110. (version "9.1")
  111. (source
  112. (origin
  113. (method git-fetch)
  114. (uri (git-reference
  115. (url "https://github.com/yshui/picom")
  116. (commit (string-append "v" version))))
  117. (sha256
  118. (base32
  119. "0q7j6kh9k7i201cwhnfc3bmp0hqrx7ngk3v4qsp8k0qfy1n3ma8n"))
  120. (file-name (string-append "picom-" version))))
  121. (build-system meson-build-system)
  122. (inputs
  123. (list dbus
  124. libconfig
  125. libx11
  126. libxext
  127. libev
  128. mesa
  129. xprop
  130. xcb-util-renderutil
  131. xcb-util-image
  132. pixman
  133. uthash
  134. libxdg-basedir
  135. pcre))
  136. (native-inputs
  137. (list asciidoc pkg-config xorgproto))
  138. (arguments
  139. `(#:build-type "release"
  140. #:configure-flags '("-Dwith_docs=true")))
  141. (home-page "https://github.com/yshui/picom")
  142. (synopsis "Compositor for X11, forked from Compton")
  143. (description
  144. "Picom is a standalone compositor for Xorg, suitable for use
  145. with window managers that do not provide compositing.
  146. Picom is a fork of compton, which is a fork of xcompmgr-dana,
  147. which in turn is a fork of xcompmgr.")
  148. (license (list license:expat ; The original compton license.
  149. license:mpl2.0)))) ; License used by new picom files.