clean up a bit and use plain xorg.conf-files as long as the uci x11 parser is not...
[openwrt/svn-archive/archive.git] / Xorg / xorg / xserver / xorg-server / Makefile
1 #
2 # Copyright (C) 2006-2009 OpenWrt.org
3 #
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
6 #
7
8 include $(TOPDIR)/rules.mk
9
10 PKG_NAME:=xorg-server
11 PKG_RELEASE:=2
12 PKG_VERSION:=1.5.1
13 PKG_SOURCE_URL:=http://xorg.freedesktop.org/releases/X11R7.4/src/xserver/
14 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
15 PKG_BUILD_DIR=$(BUILD_DIR)/Xorg/xserver/$(PKG_NAME)-$(PKG_VERSION)/
16 PKG_BUILD_DEPENDS:=randrproto renderproto fixesproto damageproto xcmiscproto \
17 xextproto xproto scrnsaverproto bigreqsproto resourceproto \
18 fontsproto inputproto kbproto videoproto resourceproto \
19 compositeproto xf86dgaproto xtrans xf86driproto
20
21 PKG_INSTALL:=1
22
23 include $(INCLUDE_DIR)/package.mk
24
25 X_CONFIG=generic
26 ifeq ($(CONFIG_TARGET_olpc),y)
27 X_CONFIG=olpc
28 endif
29 ifeq ($(CONFIG_TARGET_s3c24xx),y)
30 X_CONFIG=om_gta02
31 endif
32
33 define Package/xorg/Default
34 SECTION:=xorg-server
35 CATEGORY:=Xorg
36 SUBMENU:=server
37 DEPENDS:=@!avr32
38 URL:=http://xorg.freedesktop.org/
39 endef
40
41 define Package/xserver-xorg
42 $(call Package/xorg/Default)
43 PROVIDES:=xserver
44 TITLE:=Xorg xserver
45 DEPENDS:=+xserver-common \
46 +libpthread \
47 +libxkbfile \
48 +libXfont \
49 +libXau \
50 +libXv \
51 +libfontenc \
52 +pixman \
53 +libopenssl \
54 +libpciaccess \
55 +libdrm \
56 +libgl-mesa \
57 @DISPLAY_SUPPORT
58 endef
59
60 define Package/xserver-xorg-config
61 $(call Package/xorg/Default)
62 TITLE:=Xorg server configuration tools
63 DEPENDS:=xserver-xorg
64 endef
65
66 define Package/xserver-common
67 $(call Package/xorg/Default)
68 TITLE:=meta-package
69 endef
70
71 define Build/Configure
72 $(call Build/Configure/Default, \
73 --enable-xorg \
74 --enable-dri \
75 --disable-kdrive \
76 --disable-cfb \
77 --disable-afb \
78 --disable-mfb \
79 --disable-aiglx \
80 --disable-glx-tls \
81 --disable-dga \
82 --disable-xdmcp \
83 --disable-xdm-auth-1 \
84 --disable-config-hal \
85 --disable-xf86misc \
86 --disable-xf86vidmode \
87 --disable-xf86bigfont \
88 --disable-xorgcfg \
89 --disable-xkb \
90 --disable-xnest \
91 --disable-xquartz \
92 --disable-xwin \
93 --disable-x11app \
94 --disable-xsdl \
95 --disable-xfake \
96 --disable-install-setuid \
97 --disable-kbd_mode \
98 --disable-xvfb \
99 --disable-xprint \
100 --disable-xtrap \
101 --disable-dmx \
102 --disable-glx \
103 --disable-xinerama \
104 --disable-xfree86-utils \
105 --disable-cup \
106 --disable-xevie \
107 --disable-evi \
108 --disable-screensaver \
109 --enable-builtin-fonts \
110 )
111 endef
112
113 define Package/xserver-common/install
114 $(INSTALL_DIR) $(1)/etc/{init.d,config,X11}
115 $(INSTALL_BIN) \
116 ./files/x.init \
117 $(1)/etc/init.d/x11
118 $(INSTALL_DATA) ./files/tmp/x11.uci \
119 $(1)/etc/config/x11
120 test -f ./files/config.xorg/$(X_CONFIG) && \
121 $(INSTALL_DATA) \
122 ./files/config.xorg/$(X_CONFIG) \
123 $(1)/etc/X11/xorg.conf
124 # test -f ./files/config.uci/$(X_CONFIG) && \
125 # $(INSTALL_DATA) \
126 # ./files/config.uci/$(X_CONFIG) \
127 # $(1)/etc/config/x11
128 endef
129
130 define Package/xserver-xorg/install
131 $(INSTALL_DIR) $(1)/usr/bin
132 $(INSTALL_BIN) \
133 $(PKG_INSTALL_DIR)/usr/bin/Xorg \
134 $(1)/usr/bin/
135
136 $(INSTALL_DIR) $(1)/usr/lib/xorg/modules/{extensions,fonts,linux,multimedia}
137 $(INSTALL_DATA) \
138 $(PKG_INSTALL_DIR)/usr/lib/xorg/modules/*.so \
139 $(1)/usr/lib/xorg/modules/
140
141 $(foreach d,extensions fonts linux multimedia, \
142 $(INSTALL_DATA) \
143 $(PKG_INSTALL_DIR)/usr/lib/xorg/modules/$(d)/*.so \
144 $(1)/usr/lib/xorg/modules/$(d)/; \
145 )
146 endef
147
148 define Build/InstallDev
149 $(INSTALL_DIR) $(1)/usr/share/aclocal/
150 $(INSTALL_DATA) \
151 $(PKG_INSTALL_DIR)/usr/share/aclocal/* \
152 $(1)/usr/share/aclocal/
153
154 $(INSTALL_DIR) $(1)/usr/lib/pkgconfig
155 $(INSTALL_DATA) \
156 $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/* \
157 $(1)/usr/lib/pkgconfig/
158 $(if $(CONFIG_PACKAGE_xserver-xorg), \
159 $(INSTALL_DIR) $(1)/usr/include/xorg; \
160 $(INSTALL_DATA) \
161 $(PKG_INSTALL_DIR)/usr/include/xorg/*.h \
162 $(1)/usr/include/xorg/; \
163 )
164 endef
165
166 $(eval $(call BuildPackage,xserver-common))
167 $(eval $(call BuildPackage,xserver-xorg))