summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Olbrich <m.olbrich@pengutronix.de>2018-05-31 20:34:55 +0200
committerMichael Olbrich <m.olbrich@pengutronix.de>2018-06-04 10:53:31 +0200
commit6647aa3dca3398177cce6269dffd7b847c41f62a (patch)
tree59f665f5db2638afcce033f5d7dba1fa9f307403
parent2777f2edbf367f4a36e3f0fb393fa74077e405c9 (diff)
downloadptxdist-6647aa3dca3398177cce6269dffd7b847c41f62a.tar.gz
ptxdist-6647aa3dca3398177cce6269dffd7b847c41f62a.tar.xz
remove old base platform code
It's obsolete and broken. dev packages should be used instead. Signed-off-by: Michael Olbrich <m.olbrich@pengutronix.de>
-rwxr-xr-xbin/ptxdist59
-rw-r--r--rules/base-pkgs.in6
-rw-r--r--rules/base-pkgs.make40
-rw-r--r--rules/glibc.in1
-rw-r--r--rules/kernel-production.make31
-rw-r--r--rules/kernel.make21
-rw-r--r--rules/other/Toplevel.make4
-rw-r--r--rules/project-name.in132
-rw-r--r--scripts/lib/ptxd_lib_00-init.sh35
-rw-r--r--scripts/lib/ptxd_make_00-init.sh37
-rw-r--r--scripts/lib/ptxd_make_image_common.sh4
-rw-r--r--scripts/lib/ptxd_make_xpkg_common.sh7
12 files changed, 9 insertions, 368 deletions
diff --git a/bin/ptxdist b/bin/ptxdist
index 7e0556949..7df1384f3 100755
--- a/bin/ptxdist
+++ b/bin/ptxdist
@@ -1092,33 +1092,8 @@ clean() {
local ptxconf_sysroot_host="$(ptxd_get_ptxconf PTXCONF_SYSROOT_HOST)"
local ptxconf_sysroot_cross="$(ptxd_get_ptxconf PTXCONF_SYSROOT_CROSS)"
local ptxconf_gnu_target="$(ptxd_get_ptxconf PTXCONF_GNU_TARGET)"
- local ptxconf_project_build_production="$(ptxd_get_ptxconf PTXCONF_PROJECT_BUILD_PRODUCTION)"
- for dir in "${ptxconf_sysroot_target}" "${ptxconf_sysroot_host}" "${ptxconf_sysroot_cross}"; do
- if [ ! -d "${dir}" ]; then
- continue
- fi
-
- if [ -n "${ptxconf_project_build_production}" ]; then
- #
- # in case of a production build, delete sysroots.
- # it makes no sense to keep them,
- # but delete the image and state dirs
- #
- rm -fr -- "${dir}"
- else
- #
- # remove the dir only if it is inside the workspace; if we for
- # example build toolchains to /opt/...,
- # we don't want to clean them here!
- #
- case "${dir}" in
- (${PTXDIST_WORKSPACE}/*)
- rm -fr -- "${dir}" ;;
- (*) ;;
- esac
- fi
- done
+ rm -rf -- "${ptxconf_sysroot_target}" "${ptxconf_sysroot_host}" "${ptxconf_sysroot_cross}"
# this is for ptxdist-1 backward compatibility
dir="${PTXDIST_WORKSPACE}/local/${ptxconf_gnu_target}"
@@ -2443,45 +2418,21 @@ setup_platform_continue_with_broken_config()
# "*DIR" correct directory definitions
#
setup_platform() {
- local platform platform_version project project_version production
+ local platform platform_version project project_version
# ptxd_get_ptxconf's return value is
platform="$(ptxd_get_ptxconf PTXCONF_PLATFORM)" || [ ${?} -eq 1 ] &&
project="$(ptxd_get_ptxconf PTXCONF_PROJECT)" || [ ${?} -eq 1 ] &&
- project_version="$(ptxd_get_ptxconf PTXCONF_PROJECT_VERSION)" || [ ${?} -eq 1 ] &&
- production="$(ptxd_get_ptxconf PTXCONF_PROJECT_BUILD_PRODUCTION)" || [ ${?} -eq 1 ] || return
+ project_version="$(ptxd_get_ptxconf PTXCONF_PROJECT_VERSION)" || [ ${?} -eq 1 ] || return
# remove space and "(" ")"
project_version="${project_version//[ \(\)]/_}"
- local prefix
- if [ -n "${production}" ]; then
- if ! prefix="$(ptxd_get_ptxconf PTXCONF_PROJECT_BUILD_PRODUCTION_PREFIX)"; then
- if setup_platform_continue_with_broken_config; then
- # use default
- prefix="${PTXDIST_WORKSPACE}"
- else
- ptxd_dialog_msgbox \
- "error: 'production' release is activated, but the config symbol\n" \
- " PROJECT_BUILD_PRODUCTION_PREFIX is empty.\n" \
- "\n" \
- " Please do 'ptxdist menuconfig',\n" \
- " navigate into the submenu 'Project Name & Version'\n" \
- " and enter a production prefix, \n" \
- " or choose: 'Build Type (development)'."
- return 1
- fi
- fi
- platform_version="$(ptxd_get_ptxconf PTXCONF_PLATFORM_VERSION)"
- else
- prefix="${PTXDIST_WORKSPACE}"
- fi
-
if [ -n "${platform}" ]; then
- PTXDIST_PLATFORMDIR="${prefix}/platform-${platform}${platform_version}"
+ PTXDIST_PLATFORMDIR="${PTXDIST_WORKSPACE}/platform-${platform}${platform_version}"
PTXDIST_PLATFORMSUFFIX=".${platform}"
else
- PTXDIST_PLATFORMDIR="${prefix}/platform"
+ PTXDIST_PLATFORMDIR="${PTXDIST_WORKSPACE}/platform"
PTXDIST_PLATFORMSUFFIX=""
fi
diff --git a/rules/base-pkgs.in b/rules/base-pkgs.in
deleted file mode 100644
index dab0735ce..000000000
--- a/rules/base-pkgs.in
+++ /dev/null
@@ -1,6 +0,0 @@
-## SECTION=core
-
-config BASE_PKGS
- bool
- select BASE
- default y if PROJECT_USE_BASE_PLATFORM
diff --git a/rules/base-pkgs.make b/rules/base-pkgs.make
deleted file mode 100644
index 8ead99e0e..000000000
--- a/rules/base-pkgs.make
+++ /dev/null
@@ -1,40 +0,0 @@
-# -*-makefile-*-
-#
-# Copyright (C) 2009 by Marc Kleine-Budde <mkl@pengutronix.de>
-# (C) 2010 by Michael Olbrich <m.olbrich@pengutronix.de>
-#
-# See CREDITS for details about who has contributed to this project.
-#
-# For further information about the PTXdist project and license conditions
-# see the README file.
-#
-
-#
-# We provide this package
-#
-PACKAGES-$(PTXCONF_BASE_PKGS) += base-pkgs
-
-# ----------------------------------------------------------------------------
-# Install
-# ----------------------------------------------------------------------------
-
-$(STATEDIR)/base-pkgs.install:
- @$(call targetinfo)
- @echo -e \
- "copying 'root' from\n" \
- "'$(PTXDIST_BASE_PLATFORMDIR)'\n"
- @tar -c --exclude="./dev/*" \
- -C "$(PTXDIST_BASE_PLATFORMDIR)/root" . | \
- tar -x -C "$(ROOTDIR)" && \
- check_pipe_status
- @$(call touch)
-
-# ----------------------------------------------------------------------------
-# Target-Install
-# ----------------------------------------------------------------------------
-
-$(STATEDIR)/base-pkgs.targetinstall:
- @$(call targetinfo)
- @$(call touch)
-
-# vim: syntax=make
diff --git a/rules/glibc.in b/rules/glibc.in
index 662f0aa3e..76174b964 100644
--- a/rules/glibc.in
+++ b/rules/glibc.in
@@ -7,7 +7,6 @@ config GLIBC
if GLIBC
menu "glibc "
- depends on !PROJECT_USE_BASE_PLATFORM
comment "Install options"
diff --git a/rules/kernel-production.make b/rules/kernel-production.make
deleted file mode 100644
index 21caeb025..000000000
--- a/rules/kernel-production.make
+++ /dev/null
@@ -1,31 +0,0 @@
-# -*-makefile-*-
-#
-# Copyright (C) 2009 by Marc Kleine-Budde <mkl@pengutronix.de>
-#
-# See CREDITS for details about who has contributed to this project.
-#
-# For further information about the PTXdist project and license conditions
-# see the README file.
-#
-
-ifdef PTXCONF_PROJECT_USE_PRODUCTION
-
-$(STATEDIR)/kernel.extract:
- @$(call targetinfo)
- @$(call touch)
-
-$(STATEDIR)/kernel.prepare:
- @$(call targetinfo)
- @$(call touch)
-
-$(STATEDIR)/kernel.compile:
- @$(call targetinfo)
- @$(call touch)
-
-kernel_clean:
- @rm -rf $(STATEDIR)/kernel.* $(STATEDIR)/kernel-modules.*
- @rm -rf $(PKGDIR)/kernel_* $(PKGDIR)/kernel-modules_*
-
-endif
-
-# vim: syntax=make
diff --git a/rules/kernel.make b/rules/kernel.make
index e3e3b4084..e5d5178ed 100644
--- a/rules/kernel.make
+++ b/rules/kernel.make
@@ -14,17 +14,6 @@
#
PACKAGES-$(PTXCONF_KERNEL) += kernel
-
-#
-# when using a production release,
-# we use the precompiled kernel from /opt
-#
-ifdef PTXCONF_PROJECT_USE_PRODUCTION
-KERNEL_BDIR := $(PTXDIST_BASE_PLATFORMDIR)/build-target
-else
-KERNEL_BDIR := $(BUILDDIR)
-endif
-
#
# Paths and names
#
@@ -37,7 +26,7 @@ else
KERNEL_SUFFIX := tar.gz
KERNEL_URL := https://git.kernel.org/torvalds/t/$(KERNEL).$(KERNEL_SUFFIX)
endif
-KERNEL_DIR := $(KERNEL_BDIR)/$(KERNEL)
+KERNEL_DIR := $(BUILDDIR)/$(KERNEL)
KERNEL_CONFIG := $(call remove_quotes, $(PTXDIST_PLATFORMCONFIGDIR)/$(PTXCONF_KERNEL_CONFIG))
KERNEL_LICENSE := GPL-2.0-only
KERNEL_SOURCE := $(SRCDIR)/$(KERNEL).$(KERNEL_SUFFIX)
@@ -98,8 +87,6 @@ KERNEL_IMAGE_PATH_$(PTXCONF_KERNEL_IMAGE_VMLINUX) := $(KERNEL_DIR)/vmlinux
KERNEL_IMAGE_PATH_$(PTXCONF_ARCH_AVR32) := $(KERNEL_DIR)/arch/$(PTXCONF_KERNEL_ARCH_STRING)/boot/images/$(KERNEL_IMAGE)
-ifndef PTXCONF_PROJECT_USE_PRODUCTION
-
ifdef PTXCONF_KERNEL
$(KERNEL_CONFIG):
@echo
@@ -205,8 +192,6 @@ ifdef PTXCONF_KERNEL_TOOL_IIO
endif
@$(call touch)
-endif # !PTXCONF_PROJECT_USE_PRODUCTION
-
# ----------------------------------------------------------------------------
# Install
# ----------------------------------------------------------------------------
@@ -302,8 +287,6 @@ endif
# Clean
# ----------------------------------------------------------------------------
-ifndef PTXCONF_PROJECT_USE_PRODUCTION
-
$(STATEDIR)/kernel.clean:
@$(call targetinfo)
@$(call clean_pkg, KERNEL)
@@ -333,6 +316,4 @@ kernel_oldconfig kernel_menuconfig kernel_nconfig: $(STATEDIR)/kernel.extract
cp $(KERNEL_DIR)/.config $(KERNEL_CONFIG); \
fi
-endif
-
# vim: syntax=make
diff --git a/rules/other/Toplevel.make b/rules/other/Toplevel.make
index 632d2c475..82adf969f 100644
--- a/rules/other/Toplevel.make
+++ b/rules/other/Toplevel.make
@@ -91,9 +91,7 @@ PTX_PACKAGES_SELECTED := \
$(LAZY_PACKAGES)
PTX_PACKAGES_INSTALL := \
- $(PACKAGES) \
- $(PTXDIST_BASE_PACKAGES) \
- $(PACKAGES-b)
+ $(PACKAGES)
# might be non existent
include $(foreach dir, $(call reverse,$(subst :,$(space),$(PTXDIST_PATH_POSTRULES))), $(sort $(wildcard $(dir)/*.make)))
diff --git a/rules/project-name.in b/rules/project-name.in
index a9fdc4792..54562341b 100644
--- a/rules/project-name.in
+++ b/rules/project-name.in
@@ -34,138 +34,6 @@ config PROJECT_VERSION
The string is supposed to start with a "-".
comment "------------------------------------"
-
-config PROJECT_USE_BASE_PLATFORM
- bool
-
-choice
- prompt "Build Type"
- default PROJECT_BUILD_DEVEL
-
-config PROJECT_BUILD_DEVEL
- bool
- prompt "development"
- help
- Perform a development build, which installs everything into
- "${PTXDIST_WORKSPACE}/platform-<PLATFORM>".
-
- This is the default. If unsure select this.
-
-config PROJECT_BUILD_PRODUCTION
- bool
- prompt "production"
- help
- Perform a production build, which installs everything into
- central, system wide location.
-
-endchoice
-
-
-choice
- prompt "location"
- depends on PROJECT_BUILD_PRODUCTION
- default PROJECT_BUILD_PRODUCTION_PREFIX_DEFAULT_CHOICE
-
-config PROJECT_BUILD_PRODUCTION_PREFIX_DEFAULT_CHOICE
- bool
- prompt "default"
- help
- Build pre-built production release to the default
- location. It will be composed of:
- - project vendor,
- - project name and
- - project version.
-
- The path will look like this:
-
- "/opt/OSELAS.BSP/Pengutronix/OSELAS.BSP-Pengutronix-AllYes-trunk/platform-ARM-reference-trunk"
-
- This is the default. If unsure select this.
-
-
-config PROJECT_BUILD_PRODUCTION_PREFIX_CUSTOM_CHOICE
- bool
- prompt "custom"
- help
- Build production relase and place it in an individual
- location.
-
-endchoice
-
-
-config PROJECT_BUILD_PRODUCTION_PREFIX_CUSTOM
- string
- prompt "custom location"
- depends on PROJECT_BUILD_PRODUCTION_PREFIX_CUSTOM_CHOICE
- help
- Specify the location where to place your production release.
-
-config PROJECT_BUILD_PRODUCTION_PREFIX
- string
- default "/opt/OSELAS.BSP/${PTXCONF_PROJECT_VENDOR}/OSELAS.BSP-${PTXCONF_PROJECT_VENDOR}-${PTXCONF_PROJECT}${PTXCONF_PROJECT_VERSION}" \
- if PROJECT_BUILD_PRODUCTION_PREFIX_DEFAULT_CHOICE
- default "${PTXCONF_PROJECT_BUILD_PRODUCTION_PREFIX_CUSTOM}" \
- if PROJECT_BUILD_PRODUCTION_PREFIX_CUSTOM_CHOICE
-
-comment "------------------------------------"
-
-config PROJECT_USE_PRODUCTION
- bool
- prompt "use pre-built production release"
- depends on PROJECT_BUILD_DEVEL
- select PROJECT_USE_BASE_PLATFORM
- help
- Use a pre-built production release.
-
-choice
- prompt "location"
- depends on PROJECT_USE_PRODUCTION
- default PROJECT_USE_PRODUCTION_PREFIX_DEFAULT_CHOICE
-
-config PROJECT_USE_PRODUCTION_PREFIX_DEFAULT_CHOICE
- bool
- prompt "default"
- help
- Use pre-built production release from default location.
-
- This is the default. If unsure select this.
-
-config PROJECT_USE_PRODUCTION_PREFIX_CUSTOM_CHOICE
- bool
- prompt "custom"
- help
- Use pre-built production release from an individual location.
-
-endchoice
-
-config PROJECT_USE_PRODUCTION_PREFIX_CUSTOM
- string
- prompt "custom location"
- depends on PROJECT_USE_PRODUCTION_PREFIX_CUSTOM_CHOICE
-
-config PROJECT_USE_PRODUCTION_PREFIX
- string
- default "/opt/OSELAS.BSP/${PTXCONF_PROJECT_VENDOR}/OSELAS.BSP-${PTXCONF_PROJECT_VENDOR}-${PTXCONF_PROJECT}${PTXCONF_PROJECT_VERSION}" if PROJECT_USE_PRODUCTION_PREFIX_DEFAULT_CHOICE
- default "${PTXCONF_PROJECT_USE_PRODUCTION_PREFIX_CUSTOM}" if PROJECT_USE_PRODUCTION_PREFIX_CUSTOM_CHOICE
-
-config PROJECT_USE_LOCAL_PLATFORM
- bool
- prompt "built on top of another platform"
- depends on PROJECT_BUILD_DEVEL && !PROJECT_USE_PRODUCTION
- select PROJECT_USE_BASE_PLATFORM
- help
- Use an existing platform as origin. This platform must be
- specified in the "platform name" entry.
-
-config PROJECT_USE_LOCAL_PLATFORM_NAME
- string
- prompt "platform name"
- depends on PROJECT_USE_LOCAL_PLATFORM
- help
- The name of the platform to use. This is the directory name of
- the platform in the ptxdist workspace e.g. ``platform-i586''.
-
-comment "------------------------------------"
comment "pre-built package handling"
comment "------------------------------------"
diff --git a/scripts/lib/ptxd_lib_00-init.sh b/scripts/lib/ptxd_lib_00-init.sh
index d14781a56..99dd4249f 100644
--- a/scripts/lib/ptxd_lib_00-init.sh
+++ b/scripts/lib/ptxd_lib_00-init.sh
@@ -11,41 +11,6 @@
#
-# figure out if we use a production or base BSP
-#
-# out:
-# sysroot_base_platform
-#
-ptxd_init_get_sysroot_base_platform() {
- local prefix
-
- if prefix="$(ptxd_get_ptxconf PTXCONF_PROJECT_USE_PRODUCTION_PREFIX)"; then
- local platform
- if platform="$(ptxd_get_ptxconf PTXCONF_PLATFORM)"; then
- local platform_version="$(ptxd_get_ptxconf PTXCONF_PLATFORM_VERSION)"
- prefix="${prefix}/platform-${platform}${platform_version}"
- else
- : # nothing to do for non-platform BSPs
- fi
- elif prefix="$(ptxd_get_ptxconf PTXCONF_PROJECT_USE_LOCAL_PLATFORM_NAME)"; then
- prefix="${PTXDIST_WORKSPACE}/${prefix}"
- else
- return
- fi
-
- # FIXME: HACK we hardcode "sysroot-target" here
- sysroot_base_platform="${prefix}/sysroot-target"
-
- if [ ! -d "${sysroot_base_platform}" ]; then
- ptxd_bailout "$(ptxd_print_path "${prefix}") is not a valid platform."
- fi
-
- PTXDIST_BASE_PLATFORMDIR="${prefix}"
- export PTXDIST_BASE_PLATFORMDIR
-}
-
-
-#
#
#
ptxd_init_ptxdist_path() {
diff --git a/scripts/lib/ptxd_make_00-init.sh b/scripts/lib/ptxd_make_00-init.sh
index b2cae72f5..4103d4f39 100644
--- a/scripts/lib/ptxd_make_00-init.sh
+++ b/scripts/lib/ptxd_make_00-init.sh
@@ -137,12 +137,6 @@ ptxd_init_ptxdist_path_sysroot() {
local sysroot="$(ptxd_get_ptxconf PTXCONF_SYSROOT_TARGET)"
local sysroot_prefix="${sysroot}:${sysroot}/usr"
- local sysroot_base_platform
- if ptxd_init_get_sysroot_base_platform; then
- sysroot="${sysroot}:${sysroot_base_platform}"
- sysroot_prefix="${sysroot_prefix}:${sysroot_base_platform}:${sysroot_base_platform}/usr"
- fi
-
local sysroot_all="${sysroot}"
local sysroot_prefix_all="${sysroot_prefix}"
if [ -n "${PTXDIST_SYSROOT_TOOLCHAIN}" ]; then
@@ -175,34 +169,6 @@ ptxd_init_ptxdist_path_sysroot_host() {
#
-# fixup collectionconfig when using another platform
-#
-# out:
-# PTXDIST_BASE_PACKAGES packages of the used platform (without 'm' when using a collection)
-# PTXDIST_COLLECTIONCONFIG a modified collectionconfig (for packages from the other platform)
-#
-ptxd_init_collectionconfig() {
- if [ -e "${PTXDIST_COLLECTIONCONFIG}" ]; then
- local new_collection="${PTXDIST_TEMPDIR}/collectionconfig"
- sed -e 's/=y$/=b/' "${PTXDIST_COLLECTIONCONFIG}" > "${new_collection}"
- export PTXDIST_COLLECTIONCONFIG="${new_collection}"
- PTXDIST_BASE_PACKAGES="$(PTXDIST_PTXCONFIG="${PTXDIST_BASE_PLATFORMDIR}/selected_ptxconfig"
- PTXDIST_PLATFORMCONFIG="${PTXDIST_BASE_PLATFORMDIR}/selected_platformconfig"
- PTXDIST_BASE_PLATFORMDIR=
- ptxd_lib_init
- ptxd_make_log "print-PACKAGES-y")"
- else
- PTXDIST_BASE_PACKAGES="$(PTXDIST_PTXCONFIG="${PTXDIST_BASE_PLATFORMDIR}/selected_ptxconfig"
- PTXDIST_PLATFORMCONFIG="${PTXDIST_BASE_PLATFORMDIR}/selected_platformconfig"
- PTXDIST_BASE_PLATFORMDIR=
- ptxd_lib_init
- ptxd_make_log "print-PACKAGES")"
- fi
- export PTXDIST_BASE_PACKAGES
-}
-
-
-#
# out: 'lib' or 'lib64', derived from the ld-{linux,uClibc}.so.? from the compiler toolchain
#
ptxd_get_lib_dir() {
@@ -404,9 +370,6 @@ ptxd_make_init() {
ptxd_init_devpkg &&
- if [ -n "${PTXDIST_BASE_PLATFORMDIR}" ]; then
- ptxd_init_collectionconfig
- fi &&
ptxd_init_cross_env &&
ptxd_init_host_env &&
ptxd_init_save_wrapper_env
diff --git a/scripts/lib/ptxd_make_image_common.sh b/scripts/lib/ptxd_make_image_common.sh
index f8564b6e8..402ff532b 100644
--- a/scripts/lib/ptxd_make_image_common.sh
+++ b/scripts/lib/ptxd_make_image_common.sh
@@ -66,10 +66,6 @@ ptxd_make_image_init() {
image_ipkg_repo_dirs=( "${image_repo_dist_dir}" )
fi
- if [ -n "${PTXDIST_BASE_PLATFORMDIR}" ]; then
- image_ipkg_repo_dirs[${#image_ipkg_repo_dirs[@]}]="${PTXDIST_BASE_PLATFORMDIR}/packages"
- fi
-
exec 2>&${PTXDIST_FD_LOGERR}
}
export -f ptxd_make_image_init
diff --git a/scripts/lib/ptxd_make_xpkg_common.sh b/scripts/lib/ptxd_make_xpkg_common.sh
index c35b4f4e4..864f325d6 100644
--- a/scripts/lib/ptxd_make_xpkg_common.sh
+++ b/scripts/lib/ptxd_make_xpkg_common.sh
@@ -56,11 +56,8 @@ export -f ptxd_dopermissions
# ptxd_reply (array)
#
ptxd_do_xpkg_map() {
- if [ -n "${PTXDIST_BASE_PLATFORMDIR}" ]; then
- set -- "${@/#/${ptx_state_dir}/}" "${@/#/${PTXDIST_BASE_PLATFORMDIR}/state/}"
- else
- set -- "${@/#/${ptx_state_dir}/}"
- fi
+ set -- "${@/#/${ptx_state_dir}/}"
+
ptxd_reply=( $(cat "${@/%/.xpkg.map}" 2>/dev/null) )
[ ${#ptxd_reply[@]} -ne 0 ]