add the aMule P2P client
[openwrt/svn-archive/archive.git] / XOrg / app / common.mk
1 #
2 # Copyright (C) 2007 OpenWrt.org
3 #
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
6 #
7 # blogic@openwrt.org
8
9 PKG_SOURCE_URL:=http://xorg.freedesktop.org/releases/X11R7.2/src/app
10
11 _CATEGORY:=app
12
13 ifneq ($(PKG_NAME),xinit-X11R7.2)
14 _DEPEND+=xorg-server-X11R7.2-essentials
15 endif
16
17 include ../../common.mk
18
19 ifeq ($(PKG_NAME),xdm-X11R7.2)
20 CONFIGURE_ARGS+=--with-random-device=/dev/urandom
21 endif
22
23 CONFIGURE_ARGS+=LIBS="-Wl,-rpath-link=$(STAGING_DIR)/usr/lib"
24
25 define Build/Compile
26 make -C $(PKG_BUILD_DIR)
27 make -C $(PKG_BUILD_DIR) DESTDIR=$(PKG_INSTALL_DIR) install
28 endef
29
30 define Build/Configure
31 (cd $(PKG_BUILD_DIR)/$(CONFIGURE_PATH); \
32 if [ -x $(CONFIGURE_CMD) ]; then \
33 $(CP) $(SCRIPT_DIR)/config.{guess,sub} $(PKG_BUILD_DIR)/ && \
34 $(CONFIGURE_VARS) \
35 $(CONFIGURE_CMD) \
36 $(CONFIGURE_ARGS_XTRA) \
37 $(CONFIGURE_ARGS) ;\
38 fi \
39 )
40 endef
41
42 define xinit-X11R7.2/install
43 rm -rf $(1)/usr
44 $(INSTALL_DIR) $(1)/usr/bin
45 $(CP) $(PKG_INSTALL_DIR)/usr/bin/xinit $(1)/usr/bin/xinit
46 cd $(1)/usr/bin/; ln -s xinit startx
47 endef
48
49 define Package/$(PKG_NAME)/install
50 $(INSTALL_DIR) $(1)
51 $(CP) $(PKG_INSTALL_DIR)/* $(1)
52 rm -rf $(1)/usr/man/
53 $(call $(PKG_NAME)/install,$(1))
54 endef