Makefile.am 3.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151
  1. if DRI
  2. DRI_SUBDIR = dri
  3. DRI_LIB = dri/libdri.la
  4. endif
  5. if DRI2
  6. DRI2_SUBDIR = dri2
  7. DRI2_LIB = dri2/libdri2.la
  8. endif
  9. if DRI3
  10. DRI3_BUILDDIR = $(top_builddir)/dri3
  11. DRI3_LIB = $(DRI3_BUILDDIR)/libdri3.la
  12. endif
  13. if GLAMOR_EGL
  14. GLAMOR_EGL_SUBDIR = glamor_egl
  15. endif
  16. if XF86UTILS
  17. XF86UTILS_SUBDIR = utils
  18. endif
  19. if VGAHW
  20. VGAHW_SUBDIR = vgahw
  21. endif
  22. if VBE
  23. VBE_SUBDIR = vbe
  24. endif
  25. if INT10MODULE
  26. INT10_SUBDIR = int10
  27. endif
  28. SUBDIRS = common ddc x86emu $(INT10_SUBDIR) os-support parser \
  29. ramdac $(VGAHW_SUBDIR) loader modes $(DRI_SUBDIR) \
  30. $(DRI2_SUBDIR) . $(VBE_SUBDIR) i2c dixmods \
  31. fbdevhw shadowfb exa $(XF86UTILS_SUBDIR) doc man \
  32. $(GLAMOR_EGL_SUBDIR)
  33. DIST_SUBDIRS = common ddc i2c x86emu int10 fbdevhw os-support \
  34. parser ramdac shadowfb vbe vgahw \
  35. loader dixmods dri dri2 exa modes \
  36. utils doc man glamor_egl
  37. bin_PROGRAMS = Xorg
  38. nodist_Xorg_SOURCES = sdksyms.c
  39. AM_CFLAGS = $(DIX_CFLAGS) @XORG_CFLAGS@
  40. AM_CPPFLAGS = $(XORG_INCS) -I$(srcdir)/parser -I$(top_srcdir)/miext/cw \
  41. -I$(srcdir)/ddc -I$(srcdir)/i2c -I$(srcdir)/modes -I$(srcdir)/ramdac \
  42. -I$(srcdir)/dri -I$(srcdir)/dri2 -I$(top_srcdir)/dri3
  43. LOCAL_LIBS = \
  44. $(MAIN_LIB) \
  45. $(XSERVER_LIBS) \
  46. loader/libloader.la \
  47. common/libcommon.la \
  48. os-support/libxorgos.la \
  49. parser/libxf86config_internal.la \
  50. dixmods/libdixmods.la \
  51. modes/libxf86modes.la \
  52. ramdac/libramdac.la \
  53. ddc/libddc.la \
  54. i2c/libi2c.la \
  55. $(XORG_LIBS) \
  56. dixmods/libxorgxkb.la \
  57. $(DRI_LIB) \
  58. $(DRI2_LIB) \
  59. $(DRI3_LIB) \
  60. $(top_builddir)/miext/sync/libsync.la \
  61. $(top_builddir)/mi/libmi.la \
  62. $(top_builddir)/os/libos.la
  63. Xorg_LDADD = \
  64. $(LOCAL_LIBS) \
  65. $(XORG_SYS_LIBS) \
  66. $(XSERVER_SYS_LIBS)
  67. Xorg_DEPENDENCIES = $(LOCAL_LIBS)
  68. Xorg_LDFLAGS = $(LD_EXPORT_SYMBOLS_FLAG)
  69. if SUID_WRAPPER
  70. wrapdir = $(SUID_WRAPPER_DIR)
  71. wrap_PROGRAMS = Xorg.wrap
  72. Xorg_wrap_SOURCES = xorg-wrapper.c
  73. endif
  74. BUILT_SOURCES = xorg.conf.example
  75. DISTCLEANFILES = xorg.conf.example
  76. EXTRA_DIST = xorgconf.cpp
  77. # Without logdir, X will post an error on the terminal and will not start
  78. install-data-local:
  79. $(AM_V_GEN)$(MKDIR_P) $(DESTDIR)$(logdir)
  80. if CYGWIN
  81. $(INSTALL_DATA) libXorg.exe.a $(DESTDIR)$(libdir)/libXorg.exe.a
  82. endif
  83. install-exec-hook:
  84. (cd $(DESTDIR)$(bindir) && rm -f X && $(LN_S) Xorg$(EXEEXT) X)
  85. if INSTALL_SETUID
  86. chown root $(DESTDIR)$(bindir)/Xorg
  87. chmod u+s $(DESTDIR)$(bindir)/Xorg
  88. endif
  89. if SUID_WRAPPER
  90. $(MKDIR_P) $(DESTDIR)$(SUID_WRAPPER_DIR)
  91. mv $(DESTDIR)$(bindir)/Xorg $(DESTDIR)$(SUID_WRAPPER_DIR)/Xorg.bin
  92. ${INSTALL} -m 755 Xorg.sh $(DESTDIR)$(bindir)/Xorg
  93. -chown root $(DESTDIR)$(SUID_WRAPPER_DIR)/Xorg.wrap && chmod u+s $(DESTDIR)$(SUID_WRAPPER_DIR)/Xorg.wrap
  94. endif
  95. uninstall-local:
  96. if CYGWIN
  97. $(AM_V_at)rm -f $(DESTDIR)$(libdir)/libXorg.exe.a
  98. endif
  99. uninstall-hook:
  100. $(AM_V_at)rm -f $(DESTDIR)$(bindir)/X
  101. # Use variables from XORG_MANPAGE_SECTIONS and X Server configuration
  102. # Do not include manpages.am as values are not appropriate for rc files
  103. CONF_SUBSTS = -e 's|__filemansuffix__|$(FILE_MAN_SUFFIX)|g' \
  104. -e 's|MODULEPATH|$(DEFAULT_MODULE_PATH)|g' \
  105. -e 's|DEFAULTFONTPATH|$(COMPILEDDEFAULTFONTPATH)|g'
  106. xorg.conf.example: xorgconf.cpp
  107. $(AM_V_GEN)$(SED) $(CONF_SUBSTS) < $(srcdir)/xorgconf.cpp > $@
  108. relink:
  109. $(AM_V_at)rm -f Xorg$(EXEEXT) && $(MAKE) Xorg$(EXEEXT)
  110. CLEANFILES = sdksyms.c sdksyms.dep Xorg.sh
  111. EXTRA_DIST += sdksyms.sh
  112. sdksyms.dep sdksyms.c: sdksyms.sh
  113. $(AM_V_GEN)CPP='$(CPP)' AWK='$(AWK)' $(SHELL) $(srcdir)/sdksyms.sh $(top_srcdir) $(CFLAGS) $(AM_CFLAGS) $(AM_CPPFLAGS)
  114. SDKSYMS_DEP = sdksyms.dep
  115. -include $(SDKSYMS_DEP)
  116. i2c/libi2c.la:
  117. $(AM_V_at)cd i2c && $(MAKE) libi2c.la
  118. dixmods/libdixmods.la:
  119. $(AM_V_at)cd dixmods && $(MAKE) libdixmods.la
  120. dixmods/libxorgxkb.la:
  121. $(AM_V_at)cd dixmods && $(MAKE) libxorgxkb.la