Skip to content

Commit

Permalink
tools/pkginfo: simple tool to dump a package.mk
Browse files Browse the repository at this point in the history
  • Loading branch information
MilhouseVH committed May 4, 2019
1 parent d22b3d3 commit d2f0502
Showing 1 changed file with 27 additions and 0 deletions.
27 changes: 27 additions & 0 deletions tools/pkginfo
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
#!/bin/bash

# SPDX-License-Identifier: GPL-2.0
# Copyright (C) 2019-present Team LibreELEC (https://libreelec.tv)

STRIP=no
if [ "$1" = "--strip" -o "$1" = "-s" ]; then
shift
STRIP=yes
fi

. config/options "$1"

shift

echo "PROJECT=${PROJECT}, DEVICE=${DEVICE}, ARCH=${ARCH}"

for v in PKG_NAME PKG_VERSION PKG_SITE PKG_URL PKG_DIR \
PKG_NEED_UNPACK PKG_DEPENDS_UNPACK \
PKG_DEPENDS_BOOTSTRAP PKG_DEPENDS_INIT PKG_DEPENDS_HOST PKG_DEPENDS_TARGET \
PKG_IS_ADDON PKG_IS_KERNEL_PKG $@; do
if [ "${STRIP}" = "yes" ]; then
echo "${v}=\"${!v}\"" | sed "s#${ROOT}/##g"
else
echo "${v}=\"${!v}\""
fi
done

0 comments on commit d2f0502

Please sign in to comment.