mconnect - KDE Connect protocol implementation in Vala/C
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.

181 lines
4.3 KiB

  1. # This program is free software; you can redistribute it and/or modify
  2. # it under the terms of the GNU General Public License version 2 as
  3. # published by the Free Software Foundation.
  4. #
  5. # This program is distributed in the hope that it will be useful,
  6. # but WITHOUT ANY WARRANTY; without even the implied warranty of
  7. # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  8. # GNU General Public License for more details.
  9. #
  10. # You should have received a copy of the GNU General Public License along
  11. # with this program; if not, write to the Free Software Foundation, Inc.,
  12. # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
  13. #
  14. # AUTHORS
  15. # Maciek Borzecki <maciek.borzecki (at] gmail.com>
  16. #
  17. # location of *.desktop file, usually /usr/share/applications
  18. applicationsdir = $(datadir)/applications
  19. applications_DATA = \
  20. mconnect.desktop
  21. mconnectdatadir = $(datadir)/mconnect
  22. mconnectdata_DATA = \
  23. mconnect.conf
  24. bin_PROGRAMS = \
  25. mconnect \
  26. mconnectctl
  27. noinst_PROGRAMS = \
  28. test-mconn-crypt \
  29. test-mconn-crypt-vala
  30. noinst_LTLIBRARIES = \
  31. libmconn-crypt.la
  32. VALAFLAGS = \
  33. --no-color \
  34. -g \
  35. --vapidir=vapi \
  36. --pkg=gio-2.0 \
  37. --pkg=json-glib-1.0 \
  38. --pkg=gee-0.8 \
  39. --pkg=libnotify \
  40. --pkg=posix \
  41. --pkg=gdk-3.0 \
  42. --pkg=atspi-2 \
  43. --vapidir=src/crypt
  44. #-------------------------------------------------------------
  45. mconnect_SOURCES = \
  46. src/mconnect/main.vala \
  47. src/mconnect/discovery.vala \
  48. src/mconnect/packet.vala \
  49. src/mconnect/device.vala \
  50. src/mconnect/discovereddevice.vala \
  51. src/mconnect/device-proxy.vala \
  52. src/mconnect/devicemanager.vala \
  53. src/mconnect/devicemanager-proxy.vala \
  54. src/mconnect/devicechannel.vala \
  55. src/mconnect/core.vala \
  56. src/mconnect/packethandlerinterface.vala \
  57. src/mconnect/packethandlerinterface-proxy.vala \
  58. src/mconnect/packethandlers.vala \
  59. src/mconnect/packethandlers-proxy.vala \
  60. src/mconnect/notification.vala \
  61. src/mconnect/battery.vala \
  62. src/mconnect/battery-proxy.vala \
  63. src/mconnect/telephony.vala \
  64. src/mconnect/mousepad.vala \
  65. src/mconnect/ping.vala \
  66. src/mconnect/ping-proxy.vala \
  67. src/mconnect/config.vala \
  68. src/mconnect/application.vala \
  69. src/mconnect/utils.vala \
  70. src/mconnect/property-proxy.vala
  71. mconnect_LDADD = \
  72. libmconn-crypt.la \
  73. $(MCONNECT_LIBS)
  74. mconnect_CFLAGS = \
  75. $(MCONNECT_CFLAGS) \
  76. -I$(top_srcdir)/src/crypt
  77. mconnect_VALAFLAGS = \
  78. --pkg=mconn-crypt
  79. #-------------------------------------------------------------
  80. libmconn_crypt_la_SOURCES = \
  81. src/crypt/mconn-crypt.c \
  82. src/crypt/mconn-crypt.h
  83. libmconn_crypt_la_CFLAGS = \
  84. $(MCONNECT_CFLAGS)
  85. libmconn_crypt_la_LIBADD = \
  86. $(MCONNECT_LIBS)
  87. #-------------------------------------------------------------
  88. test_mconn_crypt_SOURCES = \
  89. test/mconn-crypt-test.c
  90. test_mconn_crypt_LDADD = \
  91. $(MCONNECT_LIBS) \
  92. libmconn-crypt.la
  93. test_mconn_crypt_CFLAGS = \
  94. $(MCONNECT_CFLAGS) \
  95. -I$(top_srcdir)/src/crypt
  96. #-------------------------------------------------------------
  97. test_mconn_crypt_vala_SOURCES = \
  98. test/mconn-crypt-vala-test.vala
  99. test_mconn_crypt_vala_LDADD = \
  100. $(MCONNECT_LIBS) \
  101. libmconn-crypt.la
  102. test_mconn_crypt_vala_CFLAGS = \
  103. $(MCONNECT_CFLAGS) \
  104. -I$(top_srcdir)/src/crypt
  105. test_mconn_crypt_vala_VALAFLAGS = \
  106. --pkg=mconn-crypt
  107. #-------------------------------------------------------------
  108. mconnectctl_SOURCES = \
  109. src/mconnectctl/main.vala
  110. mconnectctl_LDADD = \
  111. $(MCONNECT_LIBS)
  112. mconnectctl_CFLAGS = \
  113. $(MCONNECT_CFLAGS)
  114. #-------------------------------------------------------------
  115. # configure will expand bindir to ${exec_prefix}/bin, we want the
  116. # whole thing, that's why mconnect.desktop is generated here and not
  117. # in configure
  118. do_desktop_subst = sed -e 's,[@]bindir[@],${bindir},g'
  119. mconnect.desktop: mconnect.desktop.in
  120. $(do_desktop_subst) < $< > $@
  121. #-------------------------------------------------------------
  122. REV ?= HEAD
  123. git-source-dist:
  124. gitsha=`git rev-list $(REV) -1`; \
  125. git archive --prefix=mconnect-$${gitsha}/ $(REV) | \
  126. gzip -c > mconnect-$${gitsha}.tar.gz
  127. #-------------------------------------------------------------
  128. run-gdb: gdb-script install
  129. gdb -x gdb-script
  130. .PHONY: run-gdb
  131. gdb-script: gdb-script.in
  132. sed -e 's,[@]bindir[@],${bindir},g' < $< > $@
  133. #-------------------------------------------------------------
  134. GEN_FROM_VALA = $(filter %.vala,$(mconnect_SOURCES))
  135. BUILT_SOURCES = \
  136. mconnect.desktop \
  137. $(GEN_FROM_VALA:.vala=.c)
  138. CLEANFILES = $(BUILT_SOURCES)