summaryrefslogtreecommitdiffstats
path: root/src/opkbuild.sh
diff options
context:
space:
mode:
authorP. J. McDermott <pjm@nac.net>2012-07-31 21:59:53 (EDT)
committer P. J. McDermott <pjm@nac.net>2012-07-31 21:59:53 (EDT)
commitf3cb9916675ee2270fefd6e8eff676c78914e4d7 (patch)
treeac5108c5a059b4beb34055a0e7c53c61e2a2ceb4 /src/opkbuild.sh
parentafa45e1f73545185f668e0ab5d50fa04d7dca4da (diff)
Rewrite oh-copyconfig.
Diffstat (limited to 'src/opkbuild.sh')
-rw-r--r--src/opkbuild.sh52
1 files changed, 1 insertions, 51 deletions
diff --git a/src/opkbuild.sh b/src/opkbuild.sh
index c3ae895..80921c1 100644
--- a/src/opkbuild.sh
+++ b/src/opkbuild.sh
@@ -375,57 +375,7 @@ step_platconf()
{
oh_cv_set step platconf
- # TODO: Put this in oh-copyconfig.
- if [ -f ../config ]; then
- while read -r src dest; do
- if [ -z "${src}" -o -z "${dest}" ]; then
- oh_error
- fi
- # Make sure the destination directory exists.
- mkdir -p "${dest%/*}" || oh_error
- # Find the config package files.
- # TODO: Don't hardcode path.
- config_dir_base="/usr/share/config/${OH_HOST_PLATFORM}/${OH_SOURCE}"
- if [ -d "${config_dir_base}-${OH_SOURCE_VERSION_UPSTREAM}" ]; then
- src_base="${config_dir_base}-${OH_SOURCE_VERSION_UPSTREAM}"
- elif [ -d "${config_dir_base}" ]; then
- src_base="${config_dir_base}"
- else
- # This shouldn't happen unless the package maintainer neglected
- # to add the config package to the package's Build-Depends
- # field.
- oh_error
- fi
- # Copy the config file(s).
- oh_info
- cp -p "${src_base}/${src}" "${dest}" || oh_error
- done <../config
- fi
- for bin_config in ../*.pkg/config; do
- while read -r src dest; do
- if [ -z "${src}" -o -z "${dest}" ]; then
- oh_error
- fi
- # Make sure the destination directory exists.
- mkdir -p "dest/${dest%/*}" || oh_error
- # Find the config package files.
- # TODO: Don't hardcode path.
- config_dir_base="/usr/share/config/${OH_HOST_PLATFORM}/${OH_SOURCE}"
- if [ -d "${config_dir_base}-${OH_SOURCE_VERSION_UPSTREAM}" ]; then
- src_base="${config_dir_base}-${OH_SOURCE_VERSION_UPSTREAM}"
- elif [ -d "${config_dir_base}" ]; then
- src_base="${config_dir_base}"
- else
- # This shouldn't happen unless the package maintainer neglected
- # to add the config package to the package's Build-Depends
- # field.
- oh_error
- fi
- # Copy the config file(s).
- oh_info
- cp -p "${src_base}/${src}" "dest/${dest}" || oh_error
- done <"${bin_config}"
- done
+ oh-copyconfig
step_build
}