e618a5873d2aea02ee2190081ad24ebecd159d3b
[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:=1
12 PKG_VERSION:=1.7.1
13 PKG_SOURCE_URL:=http://xorg.freedesktop.org/releases/individual/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 dri2proto
20
21 PKG_INSTALL:=1
22 PKG_FIXUP:=libtool
23
24 include $(INCLUDE_DIR)/package.mk
25
26 X_CONFIG=generic
27 ifeq ($(CONFIG_TARGET_olpc),y)
28 X_CONFIG=olpc
29 endif
30 ifeq ($(CONFIG_TARGET_s3c24xx),y)
31 X_CONFIG=om_gta02
32 endif
33
34 define Package/xorg/Default
35 SECTION:=xorg-server
36 CATEGORY:=Xorg
37 SUBMENU:=server
38 DEPENDS:=@!avr32
39 URL:=http://xorg.freedesktop.org/
40 endef
41
42 define Package/xserver-xorg
43 $(call Package/xorg/Default)
44 PROVIDES:=xserver
45 TITLE:=Xorg xserver
46 DEPENDS:=+xserver-common \
47 +libpthread \
48 +libxkbfile \
49 +libXfont \
50 +libXau \
51 +libXv \
52 +libfontenc \
53 +pixman \
54 +libopenssl \
55 +libpciaccess \
56 +libdrm \
57 +libgl-mesa \
58 @DISPLAY_SUPPORT
59 endef
60
61 define Package/xserver-xorg-config
62 $(call Package/xorg/Default)
63 TITLE:=Xorg server configuration tools
64 DEPENDS:=xserver-xorg
65 endef
66
67 define Package/xserver-common
68 $(call Package/xorg/Default)
69 TITLE:=meta-package
70 endef
71
72 define Build/Configure
73 $(call Build/Configure/Default, \
74 --disable-dependency-tracking \
75 --disable-debug \
76 --disable-unit-tests \
77 --disable-builddocs \
78 --disable-glx-tls \
79 --disable-composite \
80 --disable-shm \
81 --disable-xres \
82 --disable-record \
83 --enable-xv \
84 --enable-xvmc \
85 --disable-dga \
86 --disable-screensaver \
87 --disable-xdmcp \
88 --disable-xdm-auth-1 \
89 --disable-glx \
90 --enable-dri \
91 --enable-dri2 \
92 --disable-xinerama \
93 --disable-xf86vidmode \
94 --disable-xace \
95 --disable-xselinux \
96 --disable-xsecurity \
97 --disable-xcalibrate \
98 --disable-tslib \
99 --disable-multibuffer \
100 --disable-dbe \
101 --disable-xf86bigfont \
102 --enable-dpms \
103 --disable-config-dbus \
104 --disable-config-hal \
105 --disable-xfree86-utils \
106 --disable-xaa \
107 --enable-vgahw \
108 --disable-vbe \
109 --enable-int10-module \
110 --enable-xorg \
111 --disable-dmx \
112 --disable-xvfb \
113 --disable-xnest \
114 --disable-xquartz \
115 --disable-standalone-xpbproxy \
116 --disable-xwin \
117 --disable-kdrive \
118 --disable-xfake \
119 --disable-xfbdev \
120 --disable-installsetuid \
121 --disable-secure-rpc \
122 --enable-silent-rules \
123 --disable-shave \
124 )
125 endef
126
127 define Package/xserver-common/install
128 $(INSTALL_DIR) $(1)/etc/{init.d,config,X11}
129 $(INSTALL_BIN) \
130 ./files/x.init \
131 $(1)/etc/init.d/x11
132 $(INSTALL_DATA) ./files/tmp/x11.uci \
133 $(1)/etc/config/x11
134 test -f ./files/config.xorg/$(X_CONFIG) && \
135 $(INSTALL_DATA) \
136 ./files/config.xorg/$(X_CONFIG) \
137 $(1)/etc/X11/xorg.conf
138 # test -f ./files/config.uci/$(X_CONFIG) && \
139 # $(INSTALL_DATA) \
140 # ./files/config.uci/$(X_CONFIG) \
141 # $(1)/etc/config/x11
142 endef
143
144 define Package/xserver-xorg/install
145 $(INSTALL_DIR) $(1)/usr/bin
146 $(INSTALL_BIN) \
147 $(PKG_INSTALL_DIR)/usr/bin/Xorg \
148 $(1)/usr/bin/
149
150 $(INSTALL_DIR) $(1)/usr/lib/xorg/modules/{extensions,fonts,linux,multimedia}
151 $(INSTALL_DATA) \
152 $(PKG_INSTALL_DIR)/usr/lib/xorg/modules/*.so \
153 $(1)/usr/lib/xorg/modules/
154
155 $(foreach d,extensions fonts linux multimedia, \
156 $(INSTALL_DATA) \
157 $(PKG_INSTALL_DIR)/usr/lib/xorg/modules/$(d)/*.so \
158 $(1)/usr/lib/xorg/modules/$(d)/; \
159 )
160 endef
161
162 define Build/InstallDev
163 $(INSTALL_DIR) $(1)/usr/share/aclocal/
164 $(INSTALL_DATA) \
165 $(PKG_INSTALL_DIR)/usr/share/aclocal/* \
166 $(1)/usr/share/aclocal/
167
168 $(INSTALL_DIR) $(1)/usr/lib/pkgconfig
169 $(INSTALL_DATA) \
170 $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/* \
171 $(1)/usr/lib/pkgconfig/
172
173 $(if $(CONFIG_PACKAGE_xserver-xorg), \
174 $(INSTALL_DIR) $(1)/usr/include/xorg; \
175 $(INSTALL_DATA) \
176 $(PKG_INSTALL_DIR)/usr/include/xorg/*.h \
177 $(1)/usr/include/xorg/; \
178 )
179 $(INSTALL_DIR) $(1)/mk
180 $(INSTALL_DATA) \
181 ./files/xorg-driver.mk \
182 $(1)/mk/
183 $(SED) 's,@VERSION@,$(PKG_VERSION),' $(1)/mk/xorg-driver.mk
184 endef
185
186 $(eval $(call BuildPackage,xserver-common))
187 $(eval $(call BuildPackage,xserver-xorg))