blob: 401b0341b349c9e45f4f061592ac4d19fbbf68cd [file] [log] [blame]
Justin Yun24c29f12017-06-16 18:11:35 +09001# Copyright (C) 2017 The Android Open Source Project
2#
3# Bionic loader config file.
4#
5
6# Don't change the order here. The first pattern that matches with the
7# absolution path of an executable is selected.
8dir.system = /system/bin/
9dir.system = /system/xbin/
10dir.vendor = /vendor/bin/
11dir.vendor = /data/nativetest/vendor
12dir.vendor = /data/nativetest64/vendor
13dir.vendor = /data/benchmarktest/vendor
14dir.vendor = /data/benchmarktest64/vendor
15dir.system = /data/nativetest
16dir.system = /data/nativetest64
17dir.system = /data/benchmarktest
18dir.system = /data/benchmarktest64
19
20[system]
21additional.namespaces = sphal,vndk,rs
22
23###############################################################################
24# "default" namespace
25#
Jiyong Park55f05d72017-08-28 14:42:49 +090026# Framework-side code runs in this namespace. Libs from /vendor partition
Justin Yun24c29f12017-06-16 18:11:35 +090027# can't be loaded in this namespace.
28###############################################################################
Jiyong Park55f05d72017-08-28 14:42:49 +090029namespace.default.isolated = true
30# TODO(b/63553457): remove /vendor/lib from the search path. For now, this is
31# required since the classloader namespace for vendor apks should have access
32# vendor libraries in the directory. These search paths are copied to the search
33# paths of the classloader namespace.
Justin Yun24c29f12017-06-16 18:11:35 +090034namespace.default.search.paths = /system/${LIB}:/vendor/${LIB}
Jiyong Park55f05d72017-08-28 14:42:49 +090035# /vendor/app, /vendor/framework were added since libart should be able to dlopen
36# the odex files from the directory.
37namespace.default.permitted.paths = /system/${LIB}/drm:/system/${LIB}/hw:/system/framework:/system/app:/system/priv-app:/vendor/app:/vendor/framework:/oem/app:/data:/mnt/expand
Justin Yun24c29f12017-06-16 18:11:35 +090038
39namespace.default.asan.search.paths = /data/asan/system/${LIB}:/system/${LIB}:/data/asan/vendor/${LIB}:/vendor/${LIB}
Jiyong Park55f05d72017-08-28 14:42:49 +090040namespace.default.asan.permitted.paths = /data:/system/${LIB}/drm:/system/${LIB}/hw:/system/framework:/system/app:/system/priv-app:/vendor/app:/vendor/framework:/oem/app:/mnt/expand
Justin Yun24c29f12017-06-16 18:11:35 +090041
42###############################################################################
43# "sphal" namespace
44#
45# SP-HAL(Sameprocess-HAL)s are the only vendor libraries that are allowed to be
46# loaded inside system processes. libEGL_<chipset>.so, libGLESv2_<chipset>.so,
47# android.hardware.graphics.mapper@2.0-impl.so, etc are SP-HALs.
48#
49# This namespace is exclusivly for SP-HALs. When the framework tries to dynami-
50# cally load SP-HALs, android_dlopen_ext() is used to explicitly specifying
51# that they should be searched and loaded from this namespace.
52#
53# Note that there is no link from the default namespace to this namespace.
54###############################################################################
55namespace.sphal.isolated = true
56namespace.sphal.visible = true
57namespace.sphal.search.paths = /vendor/${LIB}/egl:/vendor/${LIB}/hw:/vendor/${LIB}
58namespace.sphal.permitted.paths = /vendor/${LIB}:/system/${LIB}/vndk-sp/hw
59
60namespace.sphal.asan.search.paths = /data/asan/vendor/${LIB}/egl:/vendor/${LIB}/egl:/data/asan/vendor/${LIB}/hw:/vendor/${LIB}/hw:/data/asan/vendor/${LIB}:/vendor/${LIB}
61namespace.sphal.asan.permitted.paths = /data/asan/vendor/${LIB}:/vendor/${LIB}
62
63# Once in this namespace, access to libraries in /system/lib is restricted. Only
64# libs listed here can be used.
65namespace.sphal.links = default,vndk,rs
66
67# WARNING: only NDK libs can be listed here.
Jiyong Park36798462017-08-04 19:08:06 +090068namespace.sphal.link.default.shared_libs = %LLNDK_LIBRARIES%
Justin Yun24c29f12017-06-16 18:11:35 +090069
70# WARNING: only VNDK-SP libs can be listed here. DO NOT EDIT this line.
Jiyong Park36798462017-08-04 19:08:06 +090071namespace.sphal.link.vndk.shared_libs = %VNDK_SAMEPROCESS_LIBRARIES%
Justin Yun24c29f12017-06-16 18:11:35 +090072
73# Renderscript gets separate namespace
74namespace.sphal.link.rs.shared_libs = libRS_internal.so
75
76###############################################################################
77# "rs" namespace
78#
79# This namespace is exclusively for Renderscript internal libraries.
80# This namespace has slightly looser restriction than the vndk namespace because
81# of the genuine characteristics of Renderscript; /data is in the permitted path
82# to load the compiled *.so file and libmediandk.so can be used here.
83###############################################################################
84namespace.rs.isolated = true
85namespace.rs.visible = true
86namespace.rs.search.paths = /vendor/${LIB}/vndk-sp:/system/${LIB}/vndk-sp:/vendor/${LIB}
87namespace.rs.permitted.paths = /vendor/${LIB}:/data
88
89namespace.rs.asan.search.paths = /data/asan/vendor/${LIB}/vndk-sp:/vendor/${LIB}/vndk-sp:/data/asan/system/${LIB}/vndk-sp:/system/${LIB}/vndk-sp:/data/asan/vendor/${LIB}:/vendor/${LIB}
90namespace.rs.asan.permitted.paths = /data/asan/vendor/${LIB}:/vendor/${LIB}:/data
91
92namespace.rs.links = default,vndk
Jiyong Park36798462017-08-04 19:08:06 +090093namespace.rs.link.default.shared_libs = %LLNDK_LIBRARIES%
94namespace.rs.link.vndk.shared_libs = %VNDK_SAMEPROCESS_LIBRARIES%
Justin Yun24c29f12017-06-16 18:11:35 +090095
96###############################################################################
97# "vndk" namespace
98#
99# This namespace is exclusively for vndk-sp libs.
100###############################################################################
101namespace.vndk.isolated = true
102namespace.vndk.search.paths = /vendor/${LIB}/vndk-sp:/system/${LIB}/vndk-sp
103namespace.vndk.permitted.paths = /vendor/${LIB}/hw:/vendor/${LIB}/egl
104
105namespace.vndk.asan.search.paths = /data/asan/vendor/${LIB}/vndk-sp:/vendor/${LIB}/vndk-sp:/data/asan/system/${LIB}/vndk-sp:/system/${LIB}/vndk-sp
106namespace.vndk.asan.permitted.paths = /data/asan/vendor/${LIB}/hw:/vendor/${LIB}/hw:/data/asan/vendor/${LIB}/egl:/vendor/${LIB}/egl
107
108# When these NDK libs are required inside this namespace, then it is redirected
109# to the default namespace. This is possible since their ABI is stable across
110# Android releases.
111namespace.vndk.links = default
Jiyong Park36798462017-08-04 19:08:06 +0900112namespace.vndk.link.default.shared_libs = %LLNDK_LIBRARIES%
Justin Yun24c29f12017-06-16 18:11:35 +0900113
114###############################################################################
115# Namespace config for vendor processes. In O, no restriction is enforced for
116# them. However, in O-MR1, access to /system/${LIB} will not be allowed to
117# the default namespace. 'system' namespace will be added to give limited
118# (LL-NDK only) access.
119###############################################################################
120[vendor]
121additional.namespaces = system
122
123###############################################################################
124# "default" namespace
125#
126# Vendor-side code runs in this namespace.
127###############################################################################
128namespace.default.isolated = true
129namespace.default.visible = true
130
Justin Yun3094de92017-08-25 12:30:44 +0900131namespace.default.search.paths = /vendor/${LIB}/hw:/vendor/${LIB}/egl:/vendor/${LIB}:/vendor/${LIB}/vndk:/system/${LIB}/vndk:/vendor/${LIB}/vndk-sp:/system/${LIB}/vndk-sp
Justin Yun24c29f12017-06-16 18:11:35 +0900132namespace.default.permitted.paths = /vendor:/system/${LIB}/vndk:/system/${LIB}/vndk-sp
133
Justin Yun3094de92017-08-25 12:30:44 +0900134namespace.default.asan.search.paths = /data/asan/vendor/${LIB}/hw:/vendor/${LIB}/hw:/data/asan/vendor/${LIB}/egl:/vendor/${LIB}/egl:/data/asan/vendor/${LIB}:/vendor/${LIB}:/data/asan/vendor/${LIB}/vndk:/vendor/${LIB}/vndk:/data/asan/system/${LIB}/vndk:/system/${LIB}/vndk:/data/asan/vendor/${LIB}/vndk-sp:/vendor/${LIB}/vndk-sp:/data/asan/system/${LIB}/vndk-sp:/system/${LIB}/vndk-sp
Justin Yun24c29f12017-06-16 18:11:35 +0900135namespace.default.asan.permitted.paths = /data/asan/vendor:/vendor:/data/asan/system/${LIB}/vndk:/system/${LIB}/vndk:/data/asan/system/${LIB}/vndk-sp:/system/${LIB}/vndk-sp
136
137namespace.default.links = system
Jiyong Park36798462017-08-04 19:08:06 +0900138namespace.default.link.system.shared_libs = %LLNDK_LIBRARIES%:libmedia.so:libandroid_runtime.so
Justin Yun24c29f12017-06-16 18:11:35 +0900139# libmedia.so must be removed after we have fix for lib-dplmedia.so (b/64427765)
140# libandroid_runtime.so must be removed after we have a fix for qseeproxydaemon (b/64820887)
141
142###############################################################################
143# "system" namespace
144#
145# This is for vendor process to use LL-NDK in system partition.
146###############################################################################
147namespace.system.isolated = false
148namespace.system.search.paths = /system/${LIB}
149namespace.system.permitted.paths = /system/${LIB}
150
151namespace.system.asan.search.paths = /data/asan/system/${LIB}:/system/${LIB}
152namespace.system.asan.permitted.paths = /data/asan/system/${LIB}:/system/${LIB}