dev-install: manually install package.provided into the custom profile

We want this file when we have a base image and we've run `dev_install`.
If we have a dev/test image, we don't need this as we'll have the full
/var/db/pkg environment.  So have dev-install manually install this into
the custom profile in /usr/local/etc/profile.

BUG=chromium:920140
TEST=precq passes
CQ-DEPEND=CL:1494234

Change-Id: Ic59b9584e97d5f6054e27bf38895fbfc9b3dc25a
Reviewed-on: https://chromium-review.googlesource.com/1494274
Commit-Ready: Mike Frysinger <vapier@chromium.org>
Tested-by: Mike Frysinger <vapier@chromium.org>
Reviewed-by: Ned Nguyen <nednguyen@google.com>
diff --git a/dev-install/dev_install b/dev-install/dev_install
index 3fb033f..a78dbdf 100755
--- a/dev-install/dev_install
+++ b/dev-install/dev_install
@@ -142,6 +142,13 @@
   # ourselves locally, so dereference all the symlinks for our local copy.
   cp -rfL "${P_CONFIG_CROS}/make.profile" "${P_CONFIG_DEVELOPER}/make.profile"
 
+  # Install the package.provided entries for the rootfs.
+  mkdir -p -m 0755 "${P_CONFIG_DEVELOPER}/make.profile/package.provided"
+  local f
+  for f in /usr/share/dev-install/rootfs.provided/*; do
+    ln -sf "${f}" "${P_CONFIG_DEVELOPER}/make.profile/package.provided/"
+  done
+
   # Create the directories defined in the portage config files. Permissions are
   # consistent with the other directories in /usr/local, which is a bind mount
   # for /mnt/stateful_partition/dev_image.