Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(38)

Unified Diff: src/common/make_pkg.sh

Issue 523109: Install libchrome-dev and libchromeos-dev packages (Closed)
Patch Set: Created 10 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | src/scripts/build_platform_packages.sh » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/common/make_pkg.sh
diff --git a/src/common/make_pkg.sh b/src/common/make_pkg.sh
new file mode 100755
index 0000000000000000000000000000000000000000..8d4352d74e333fcea38606486a10c5db1ca37e7a
--- /dev/null
+++ b/src/common/make_pkg.sh
@@ -0,0 +1,45 @@
+#!/bin/bash
+
+# Copyright (c) 2009 The Chromium OS Authors. All rights reserved.
+# Use of this source code is governed by a BSD-style license that can be
+# found in the LICENSE file.
+
+# Builds the .deb package.
+
+# Load common constants. This should be the first executable line.
+# The path to common.sh should be relative to your script's location.
+COMMON_SH="$(dirname "$0")/../scripts/common.sh"
+. "$COMMON_SH"
+
+PKG_BASE="libchromeos"
+
+# All packages are built in the chroot
+assert_inside_chroot
+
+# Command line options
+DEFINE_string build_root "$DEFAULT_BUILD_ROOT" "Root of build output"
+
+# Parse command line and update positional args
+FLAGS "$@" || exit 1
+eval set -- "${FLAGS_ARGV}"
+
+# Die on any errors
+set -e
+
+# Make output dir
+OUT_DIR="$FLAGS_build_root/x86/local_packages"
+mkdir -p "${OUT_DIR}"
+
+# Remove previous package from output dir
+rm -f "${OUT_DIR}/${PKG_BASE}"-dev_*.deb
+
+# Rebuild the package
+pushd "$TOP_SCRIPT_DIR"
+rm -f ../${PKG_BASE}-dev_*.deb
+dpkg-buildpackage -b -tc -us -uc -j$NUM_JOBS
+mv ../${PKG_BASE}-dev_*.deb "$OUT_DIR"
+rm ../${PKG_BASE}_*.changes
+popd
+
+# Install packages that are necessary for building later packages.
+sudo -E dpkg -i "${OUT_DIR}/${PKG_BASE}"-dev_*.deb
« no previous file with comments | « no previous file | src/scripts/build_platform_packages.sh » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698