VirtualBox

source: vbox/trunk/src/VBox/Additions/linux/Makefile.kmk@ 17610

Last change on this file since 17610 was 17407, checked in by vboxsync, 16 years ago

Additions/linux/installer: build and install the Linux drm driver

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 9.0 KB
Line 
1# $Id: Makefile.kmk 17407 2009-03-05 15:09:01Z vboxsync $
2## @file
3# Makefile for the linux guest additions base directory.
4#
5
6#
7# Copyright (C) 2006-2007 Sun Microsystems, Inc.
8#
9# This file is part of VirtualBox Open Source Edition (OSE), as
10# available from http://www.virtualbox.org. This file is free software;
11# you can redistribute it and/or modify it under the terms of the GNU
12# General Public License (GPL) as published by the Free Software
13# Foundation, in version 2 as it comes in the "COPYING" file of the
14# VirtualBox OSE distribution. VirtualBox OSE is distributed in the
15# hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
16#
17# Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa
18# Clara, CA 95054 USA or visit http://www.sun.com if you need
19# additional information or have any questions.
20#
21
22SUB_DEPTH = ../../../..
23include $(KBUILD_PATH)/subheader.kmk
24
25#
26# Include sub-makefiles.
27#
28include $(PATH_SUB_CURRENT)/module/Makefile.kmk
29include $(PATH_SUB_CURRENT)/daemon/Makefile.kmk
30include $(PATH_SUB_CURRENT)/sharedfolders/Makefile.kmk
31include $(PATH_SUB_CURRENT)/drm/Makefile.kmk
32
33#
34# Targets
35#
36ifndef VBOX_OSE
37 PACKING += $(PATH_BIN)/additions/VBoxLinuxAdditions.run
38 OTHER_CLEAN += $(PACKING)
39 # OSE only contains the source code for this
40 VBOX_SELINUX_CMPLD := $(PATH_SUB_CURRENT)/selinux-fedora/vbox_x11.pp
41endif
42
43#
44# Globals
45#
46VBOX_LNX_ADD_INS_OUT_DIR := $(PATH_TARGET)/Additions/Installer/linux
47BLDDIRS += $(VBOX_LNX_ADD_INS_OUT_DIR)
48VBOX_PATH_LINUX_ADDITION_INSTALLER := $(PATH_SUB_CURRENT)/installer
49VBOX_PATH_X11_ADDITION_INSTALLER := $(PATH_ROOT)/src/VBox/Additions/x11/Installer
50
51ifeq ($(KBUILD_TYPE),debug)
52 VBOX_LNX_ADD_BIN_COPY = $(CP) -f
53 VBOX_LNX_ADD_BIN_COPY_SYMBOLS = $(CP) -f
54else
55 VBOX_LNX_ADD_BIN_COPY = objcopy -S -R .comment
56 VBOX_LNX_ADD_BIN_COPY_SYMBOLS = objcopy -g -R .comment
57endif
58
59INSTALLS += GuestDrivers-src
60GuestDrivers-src_INST = bin/additions/src/
61GuestDrivers-src_MODE = a+r,u+w
62GuestDrivers-src_SOURCES = Makefile
63
64include $(KBUILD_PATH)/subfooter.kmk
65
66
67#
68# Build the Linux Guest Additions self extracting installer.
69#
70# Note that $(PATH_SUB_CURRENT) was changed by subfooter.kmk above and
71# any references should be made via variables assigned a know value via := .
72#
73# We need to depend on all source files for the additions and shared
74# folders kernel modules.
75## @todo Replace the wildcard stuff by the correct file lists now that
76# we've got everything included.
77#
78$(PATH_BIN)/additions/VBoxLinuxAdditions.run: \
79 $(INSTARGET_vboxmod-bin) \
80 $(PATH_BIN)/additions/vboxadd-timesync \
81 $(PATH_BIN)/additions/VBoxClient \
82 $(PATH_BIN)/additions/VBoxControl \
83 $(VBOX_PATH_X11_ADDITION_INSTALLER)/VBoxRandR.sh \
84 $(VBOX_PATH_LINUX_ADDITION_INSTALLER)/vboxadd-timesync.sh \
85 $(VBOX_PATH_X11_ADDITION_INSTALLER)/98vboxadd-xclient \
86 $(VBOX_PATH_X11_ADDITION_INSTALLER)/vboxclient.desktop \
87 $(VBOX_PATH_LINUX_ADDITION_INSTALLER)/vboxadd.sh \
88 $(VBOX_PATH_LINUX_ADDITION_INSTALLER)/install.sh \
89 $(PATH_ROOT)/src/VBox/Installer/linux/routines.sh \
90 $(VBOX_PATH_X11_ADDITION_INSTALLER)/vboxvideo.ids \
91 $(VBOX_PATH_X11_ADDITION_INSTALLER)/x11config.pl \
92 $(VBOX_PATH_X11_ADDITION_INSTALLER)/x11config15.pl \
93 $(VBOX_PATH_X11_ADDITION_INSTALLER)/x11config15suse.pl \
94 $(VBOX_PATH_LINUX_ADDITION_INSTALLER)/Makefile.test \
95 $(VBOX_PATH_LINUX_ADDITION_INSTALLER)/test.c \
96 $(PATH_BIN)/additions/vboxmouse_drv.o \
97 $(PATH_BIN)/additions/vboxmouse_drv_70.so \
98 $(PATH_BIN)/additions/vboxmouse_drv_71.so \
99 $(PATH_BIN)/additions/vboxmouse_drv_14.so \
100 $(PATH_BIN)/additions/vboxmouse_drv_15.so \
101 $(PATH_BIN)/additions/vboxmouse_drv_16.so \
102 $(PATH_BIN)/additions/vboxvideo_drv.o \
103 $(PATH_BIN)/additions/vboxvideo_drv_70.so \
104 $(PATH_BIN)/additions/vboxvideo_drv_71.so \
105 $(PATH_BIN)/additions/vboxvideo_drv_13.so \
106 $(PATH_BIN)/additions/vboxvideo_drv_14.so \
107 $(PATH_BIN)/additions/vboxvideo_drv_15.so \
108 $(PATH_BIN)/additions/vboxvideo_drv_16.so \
109 $(PATH_BIN)/additions/mountvboxsf \
110 $(VBOX_SELINUX_CMPLD) \
111 $(wildcard $(PATH_BIN)/additions/src/*) \
112 $(wildcard $(PATH_BIN)/additions/src/*/*) \
113 $(wildcard $(PATH_BIN)/additions/src/*/*/*) \
114 $(wildcard $(PATH_BIN)/additions/src/*/*/*/*) \
115 $(VBOX_VERSION_STAMP)
116 $(call MSG_L1,Creating $@)
117 $(QUIET)$(MKDIR) -p $(VBOX_LNX_ADD_INS_OUT_DIR)
118# Remove target directory first, otherwise the behaviour of cp will not be
119# what we want if it already exists. See the cp manual page for more details.
120 $(QUIET)$(RM) -Rf -- $(VBOX_LNX_ADD_INS_OUT_DIR)/module
121 $(QUIET)cp -af $(PATH_BIN)/additions/src $(VBOX_LNX_ADD_INS_OUT_DIR)/module
122 $(QUIET)$(MKDIR) -p $(VBOX_LNX_ADD_INS_OUT_DIR)/module/test
123 $(QUIET)$(INSTALL) -m 0644 $(VBOX_PATH_LINUX_ADDITION_INSTALLER)/Makefile.test $(VBOX_LNX_ADD_INS_OUT_DIR)/module/test/Makefile
124 $(QUIET)$(INSTALL) -m 0644 $(VBOX_PATH_LINUX_ADDITION_INSTALLER)/test.c $(VBOX_LNX_ADD_INS_OUT_DIR)/module/test/
125 $(QUIET)$(VBOX_LNX_ADD_BIN_COPY) $(PATH_BIN)/additions/vboxadd-timesync $(VBOX_LNX_ADD_INS_OUT_DIR)/vboxadd-timesync
126 $(QUIET)$(VBOX_LNX_ADD_BIN_COPY) $(PATH_BIN)/additions/VBoxClient $(VBOX_LNX_ADD_INS_OUT_DIR)/VBoxClient
127 $(QUIET)$(VBOX_LNX_ADD_BIN_COPY) $(PATH_BIN)/additions/VBoxControl $(VBOX_LNX_ADD_INS_OUT_DIR)/VBoxControl
128 $(QUIET)$(SED) \
129 -e "s;_VERSION_;$(VBOX_VERSION_STRING);g" \
130 -e "s;_BUILD_;$(shell date);g" \
131 -e "s;_OSE_;$(VBOX_OSE);g" \
132 -e "s;_BUILDTYPE_;$(KBUILD_TYPE);g" \
133 -e "s;_ARCH_;$(KBUILD_TARGET_ARCH);g" \
134 --output $(VBOX_LNX_ADD_INS_OUT_DIR)/install_.sh \
135 $(VBOX_PATH_LINUX_ADDITION_INSTALLER)/install.sh
136 $(QUIET)$(INSTALL) -m 0755 $(VBOX_LNX_ADD_INS_OUT_DIR)/install_.sh $(VBOX_LNX_ADD_INS_OUT_DIR)/install.sh
137 $(QUIET)$(RM) $(VBOX_LNX_ADD_INS_OUT_DIR)/install_.sh
138 $(QUIET)$(INSTALL) -m 0755 $(VBOX_PATH_X11_ADDITION_INSTALLER)/VBoxRandR.sh $(VBOX_LNX_ADD_INS_OUT_DIR)
139 $(QUIET)$(INSTALL) -m 0755 $(VBOX_PATH_LINUX_ADDITION_INSTALLER)/vboxadd-timesync.sh $(VBOX_LNX_ADD_INS_OUT_DIR)
140 $(QUIET)$(INSTALL) -m 0755 $(VBOX_PATH_X11_ADDITION_INSTALLER)/98vboxadd-xclient $(VBOX_LNX_ADD_INS_OUT_DIR)
141 $(QUIET)$(INSTALL) -m 0644 $(VBOX_PATH_X11_ADDITION_INSTALLER)/vboxclient.desktop $(VBOX_LNX_ADD_INS_OUT_DIR)
142 $(QUIET)$(INSTALL) -m 0755 $(VBOX_PATH_LINUX_ADDITION_INSTALLER)/vboxadd.sh $(VBOX_LNX_ADD_INS_OUT_DIR)
143 $(QUIET)$(INSTALL) -m 0755 $(PATH_ROOT)/src/VBox/Installer/linux/routines.sh $(VBOX_LNX_ADD_INS_OUT_DIR)
144 $(QUIET)$(INSTALL) -m 0755 $(VBOX_PATH_X11_ADDITION_INSTALLER)/vboxvideo.ids $(VBOX_LNX_ADD_INS_OUT_DIR)
145 $(QUIET)$(INSTALL) -m 0755 $(VBOX_PATH_X11_ADDITION_INSTALLER)/x11config.pl $(VBOX_LNX_ADD_INS_OUT_DIR)
146 $(QUIET)$(INSTALL) -m 0755 $(VBOX_PATH_X11_ADDITION_INSTALLER)/x11config15.pl $(VBOX_LNX_ADD_INS_OUT_DIR)
147 $(QUIET)$(INSTALL) -m 0755 $(VBOX_PATH_X11_ADDITION_INSTALLER)/x11config15suse.pl $(VBOX_LNX_ADD_INS_OUT_DIR)
148 $(QUIET)$(INSTALL) -m 0644 $(VBOX_PATH_LINUX_ADDITION_INSTALLER)/90-vboxguest.fdi $(VBOX_LNX_ADD_INS_OUT_DIR)
149 $(QUIET)$(VBOX_LNX_ADD_BIN_COPY_SYMBOLS) $(PATH_BIN)/additions/vboxmouse_drv.o $(VBOX_LNX_ADD_INS_OUT_DIR)/vboxmouse_drv.o
150 $(QUIET)$(VBOX_LNX_ADD_BIN_COPY) $(PATH_BIN)/additions/vboxmouse_drv_70.so $(VBOX_LNX_ADD_INS_OUT_DIR)/vboxmouse_drv_70.so
151 $(QUIET)$(VBOX_LNX_ADD_BIN_COPY) $(PATH_BIN)/additions/vboxmouse_drv_71.so $(VBOX_LNX_ADD_INS_OUT_DIR)/vboxmouse_drv_71.so
152 $(QUIET)$(VBOX_LNX_ADD_BIN_COPY) $(PATH_BIN)/additions/vboxmouse_drv_14.so $(VBOX_LNX_ADD_INS_OUT_DIR)/vboxmouse_drv_14.so
153 $(QUIET)$(VBOX_LNX_ADD_BIN_COPY) $(PATH_BIN)/additions/vboxmouse_drv_15.so $(VBOX_LNX_ADD_INS_OUT_DIR)/vboxmouse_drv_15.so
154 $(QUIET)$(VBOX_LNX_ADD_BIN_COPY) $(PATH_BIN)/additions/vboxmouse_drv_16.so $(VBOX_LNX_ADD_INS_OUT_DIR)/vboxmouse_drv_16.so
155 $(QUIET)$(VBOX_LNX_ADD_BIN_COPY_SYMBOLS) $(PATH_BIN)/additions/vboxvideo_drv.o $(VBOX_LNX_ADD_INS_OUT_DIR)/vboxvideo_drv.o
156 $(QUIET)$(VBOX_LNX_ADD_BIN_COPY) $(PATH_BIN)/additions/vboxvideo_drv_70.so $(VBOX_LNX_ADD_INS_OUT_DIR)/vboxvideo_drv_70.so
157 $(QUIET)$(VBOX_LNX_ADD_BIN_COPY) $(PATH_BIN)/additions/vboxvideo_drv_71.so $(VBOX_LNX_ADD_INS_OUT_DIR)/vboxvideo_drv_71.so
158 $(QUIET)$(VBOX_LNX_ADD_BIN_COPY) $(PATH_BIN)/additions/vboxvideo_drv_13.so $(VBOX_LNX_ADD_INS_OUT_DIR)/vboxvideo_drv_13.so
159 $(QUIET)$(VBOX_LNX_ADD_BIN_COPY) $(PATH_BIN)/additions/vboxvideo_drv_14.so $(VBOX_LNX_ADD_INS_OUT_DIR)/vboxvideo_drv_14.so
160 $(QUIET)$(VBOX_LNX_ADD_BIN_COPY) $(PATH_BIN)/additions/vboxvideo_drv_15.so $(VBOX_LNX_ADD_INS_OUT_DIR)/vboxvideo_drv_15.so
161 $(QUIET)$(VBOX_LNX_ADD_BIN_COPY) $(PATH_BIN)/additions/vboxvideo_drv_16.so $(VBOX_LNX_ADD_INS_OUT_DIR)/vboxvideo_drv_16.so
162 $(QUIET)$(VBOX_LNX_ADD_BIN_COPY) $(PATH_BIN)/additions/mountvboxsf $(VBOX_LNX_ADD_INS_OUT_DIR)/mount.vboxsf
163ifdef VBOX_SELINUX_CMPLD
164 $(QUIET)$(INSTALL) -m 0755 $(VBOX_SELINUX_CMPLD) $(VBOX_LNX_ADD_INS_OUT_DIR)
165endif
166 $(QUIET)$(VBOX_MAKESELF) $(VBOX_LNX_ADD_INS_OUT_DIR) $@ \
167 "VirtualBox $(VBOX_VERSION_STRING) Guest Additions for Linux installation" /bin/sh ./install.sh "> /dev/null"
168
Note: See TracBrowser for help on using the repository browser.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette