1 ###############################################################################
3 # IPFire.org - A linux based firewall #
4 # Copyright (C) 2007, 2008 Michael Tremer & Christian Schmidt #
6 # This program is free software: you can redistribute it and/or modify #
7 # it under the terms of the GNU General Public License as published by #
8 # the Free Software Foundation, either version 3 of the License, or #
9 # (at your option) any later version. #
11 # This program is distributed in the hope that it will be useful, #
12 # but WITHOUT ANY WARRANTY; without even the implied warranty of #
13 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the #
14 # GNU General Public License for more details. #
16 # You should have received a copy of the GNU General Public License #
17 # along with this program. If not, see <http://www.gnu.org/licenses/>. #
19 ###############################################################################
21 ###############################################################################
23 ###############################################################################
25 include $(PKGROOT)/Include
27 PKG_NAME = xorg-x11-server
31 PKG_MAINTAINER = Stefan Schantl <stefan.schantl@ipfire.org>
33 PKG_URL = http://www.x.org
35 PKG_SUMMARY = X.Org X11 X server.
37 PKG_BUILD_DEPS+= audit-devel autoconf automake libcap libX11-devel libXau-devel \
38 libXdmcp-devel libXext-devel libXfixes-devel libXfont-devel libXmu-devel \
39 libXrender-devel libXres-devel libXt-devel libdrm-devel libfontenc-devel \
40 libpciaccess-devel libselinux-devel libtool libudev-devel libxcb-devel \
41 libxkbfile-devel mesa-devel openssl-devel pixman-devel pkg-config \
42 xorg-x11-font-utils-devel xorg-x11-util-macros xorg-x11-proto-devel \
45 PKG_DEPS += mesa pixman udev xkeyboard-config xorg-x11-fonts xorg-x11-font-utils \
48 PKG_PACKAGES += $(PKG_NAME)-devel
50 define PKG_DESCRIPTION
51 X.org X11 is an open source implementation of the X Window System. \
52 It provides the basic low level functionality which full fledged \
53 graphical user interfaces (GUIs) such as GNOME and KDE are designed \
57 PKG_TARBALL = xorg-server-$(PKG_VER).tar.bz2
59 CFLAGS += -Wstrict-overflow -rdynamic
61 QUALITY_AGENT_PERMIT_NOT_FULL_RELRO = yes
63 DIR_APP = $(DIR_SRC)/xorg-server-$(PKG_VER)
65 CONFIGURE_OPTIONS += \
76 --enable-maintainer-mode \
79 --with-default-font-path="catalogue:/etc/X11/fontpath.d,built-ins" \
80 --with-module-dir=/usr/lib/xorg/modules \
81 --with-builderstring="Build ID: $(PKG_NAME) $(PKG_VER)-$(PKG_REL)" \
82 --with-os-name="$(hostname -s) $(uname -r)" \
83 --with-vendor-name="$(DISTRO_NAME) Project" \
84 --with-vendor-web="http://www.ipfire.org" \
85 --with-xkb-output=/var/lib/xkb \
86 --enable-install-libxf86config \
87 --localstatedir=/var \
88 --disable-screensaver \
89 --disable-config-dbus \
90 --disable-config-hal \
93 define STAGE_PREPARE_CMDS
94 cd $(DIR_APP) && autoreconf -vfi
97 # Remove BIND_NOW flag from server modules to provide autoloading of them if needed
98 # by the server itself.
99 define STAGE_CONFIGURE_CMDS
100 cd $(DIR_APP) && sed -i \
101 -e "s/^CFLAGS.*/& -Wl,-z,lazy/" \
102 -e "s/^CCASFLAGS.*/& -Wl,-z,lazy/" \
104 hw/xfree86/dixmods/Makefile \
105 hw/xfree86/dixmods/extmod/Makefile \
106 hw/xfree86/dri/Makefile \
107 hw/xfree86/dri2/Makefile \
108 hw/xfree86/exa/Makefile \
109 hw/xfree86/fbdevhw/Makefile \
110 hw/xfree86/i2c/Makefile \
111 hw/xfree86/int10/Makefile \
112 hw/xfree86/shadowfb/Makefile \
113 hw/xfree86/vbe/Makefile \
114 hw/xfree86/vgahw/Makefile \
115 hw/xfree86/xaa/Makefile
119 cd $(DIR_APP) && make install DESTDIR=$(BUILDROOT) \
120 moduledir=/usr/lib/xorg/modules
122 rm -vf $(BUILDROOT)/usr/lib/xorg/modules/libxf8_16bpp.so
123 rm -vrf $(BUILDROOT)/var/log
125 -mkdir -pv $(BUILDROOT)/etc/X11/xorg.conf.d $(BUILDROOT)/usr/share/xorg
126 cd $(DIR_APP) && install -m 0444 hw/xfree86/common/{vesa,extra}modes \
127 $(BUILDROOT)/usr/share/xorg/
128 cd $(DIR_APP) && install -m 644 $(DIR_SOURCE)/10-quirks.conf \
129 $(BUILDROOT)/usr/share/X11/xorg.conf.d
132 chmod u-s $(BUILDROOT)/usr/bin/Xorg
133 setcap cap_chown,cap_dac_override,cap_sys_rawio,cap_sys_admin+ep \
134 $(BUILDROOT)/usr/bin/Xorg