summaryrefslogtreecommitdiff
path: root/classes
diff options
context:
space:
mode:
Diffstat (limited to 'classes')
-rw-r--r--classes/angstrom-mirrors.bbclass2
-rw-r--r--classes/base.bbclass23
-rw-r--r--classes/mono.bbclass17
-rw-r--r--classes/rootfs_deb.bbclass32
-rw-r--r--classes/rootfs_ipk.bbclass6
-rw-r--r--classes/sdk.bbclass3
6 files changed, 56 insertions, 27 deletions
diff --git a/classes/angstrom-mirrors.bbclass b/classes/angstrom-mirrors.bbclass
index cd27a8545b..e44a78c983 100644
--- a/classes/angstrom-mirrors.bbclass
+++ b/classes/angstrom-mirrors.bbclass
@@ -1,4 +1,4 @@
MIRRORS_append () {
ftp://.*/.*/ http://www.angstrom-distribution.org/unstable/sources/
-http://.*/.*/ http://www.angstrom-distribution.org/unstable/sources/
+https?$://.*/.*/ http://www.angstrom-distribution.org/unstable/sources/
}
diff --git a/classes/base.bbclass b/classes/base.bbclass
index 999d409914..2cf205fbe9 100644
--- a/classes/base.bbclass
+++ b/classes/base.bbclass
@@ -22,6 +22,7 @@ def base_chk_load_parser(config_path):
def base_chk_file(parser, pn, pv, src_uri, localpath, data):
import os, bb
+ no_checksum = False
# Try PN-PV-SRC_URI first and then try PN-SRC_URI
# we rely on the get method to create errors
pn_pv_src = "%s-%s-%s" % (pn,pv,src_uri)
@@ -36,8 +37,7 @@ def base_chk_file(parser, pn, pv, src_uri, localpath, data):
md5 = parser.get(src_uri, "md5")
sha256 = parser.get(src_uri, "sha256")
else:
- return False
- #raise Exception("Can not find a section for '%s' '%s' and '%s'" % (pn,pv,src_uri))
+ no_checksum = True
# md5 and sha256 should be valid now
if not os.path.exists(localpath):
@@ -60,6 +60,19 @@ def base_chk_file(parser, pn, pv, src_uri, localpath, data):
except OSError:
raise Exception("Executing shasum failed")
+ if no_checksum == True: # we do not have conf/checksums.ini entry
+ try:
+ file = open("%s/checksums.ini" % bb.data.getVar("TMPDIR", data, 1), "a")
+ except:
+ return False
+
+ if not file:
+ raise Exception("Creating checksums.ini failed")
+
+ file.write("[%s]\nmd5=%s\nsha256=%s\n\n" % (src_uri, md5data, shadata))
+ file.close()
+ return False
+
if not md5 == md5data:
bb.note("The MD5Sums did not match. Wanted: '%s' and Got: '%s'" % (md5,md5data))
raise Exception("MD5 Sums do not match. Wanted: '%s' Got: '%s'" % (md5, md5data))
@@ -485,11 +498,9 @@ python base_do_fetch() {
(type,host,path,_,_,_) = bb.decodeurl(url)
uri = "%s://%s%s" % (type,host,path)
try:
- if not base_chk_file(parser, pn, pv,uri, localpath, d):
- if type != "file":
+ if type == "http" or type == "https" or type == "ftp" or type == "ftps":
+ if not base_chk_file(parser, pn, pv,uri, localpath, d):
bb.note("%s-%s: %s has no entry in conf/checksums.ini, not checking URI" % (pn,pv,uri))
- else:
- bb.debug("%s-%s: %s has no entry in conf/checksums.ini, not checking URI" % (pn,pv,uri))
except Exception:
raise bb.build.FuncFailed("Checksum of '%s' failed" % uri)
}
diff --git a/classes/mono.bbclass b/classes/mono.bbclass
index b7c5439b86..ccb16d9acc 100644
--- a/classes/mono.bbclass
+++ b/classes/mono.bbclass
@@ -140,6 +140,23 @@ python mono_do_clilibs() {
fd.close()
}
+do_mono_stage() {
+ if [ "${INHIBIT_MONO_STAGE}" = "1" ]
+ then
+ return
+ fi
+
+ for package in ${PACKAGES}; do
+ if [ -d "${PKGDEST}/${package}/${libdir}" ]; then
+ cd "${PKGDEST}/${package}/${libdir}"
+ for file in `find . -iname "*.dll"`; do
+ cp --parent -fpPR "${file}" "${STAGING_LIBDIR}/"
+ done
+ fi
+ done
+}
+addtask mono_stage after do_package before do_populate_staging
+
def mono_after_parse(d):
import bb
# Insert mono_do_clilibs into PACKAGEFUNCS
diff --git a/classes/rootfs_deb.bbclass b/classes/rootfs_deb.bbclass
index d3e5832251..5571f699e7 100644
--- a/classes/rootfs_deb.bbclass
+++ b/classes/rootfs_deb.bbclass
@@ -10,8 +10,8 @@ fakeroot rootfs_deb_do_rootfs () {
mkdir -p ${IMAGE_ROOTFS}/var/dpkg/info
mkdir -p ${IMAGE_ROOTFS}/var/dpkg/updates
- rm -f ${STAGING_DIR}/etc/apt/sources.list.rev
- rm -f ${STAGING_DIR}/etc/apt/preferences
+ rm -f ${STAGING_DIR}${sysconfdir}/apt/sources.list.rev
+ rm -f ${STAGING_DIR}${sysconfdir}/apt/preferences
> ${IMAGE_ROOTFS}/var/dpkg/status
> ${IMAGE_ROOTFS}/var/dpkg/available
# > ${STAGING_DIR}/var/dpkg/status
@@ -28,21 +28,21 @@ fakeroot rootfs_deb_do_rootfs () {
apt-ftparchive packages . | bzip2 > Packages.bz2
echo "Label: $arch" > Release
- echo "deb file:${DEPLOY_DIR_DEB}/$arch/ ./" >> ${STAGING_DIR}/etc/apt/sources.list.rev
+ echo "deb file:${DEPLOY_DIR_DEB}/$arch/ ./" >> ${STAGING_DIR}${sysconfdir}/apt/sources.list.rev
(echo "Package: *"
echo "Pin: release l=$arch"
echo "Pin-Priority: $((800 + $priority))"
- echo) >> ${STAGING_DIR}/etc/apt/preferences
+ echo) >> ${STAGING_DIR}${sysconfdir}/apt/preferences
priority=$(expr $priority + 5)
done
- tac ${STAGING_DIR}/etc/apt/sources.list.rev > ${STAGING_DIR}/etc/apt/sources.list
+ tac ${STAGING_DIR}${sysconfdir}/apt/sources.list.rev > ${STAGING_DIR}${sysconfdir}/apt/sources.list
- cat "${STAGING_DIR}/etc/apt/apt.conf.sample" \
+ cat "${STAGING_DIR}${sysconfdir}/apt/apt.conf.sample" \
| sed -e 's#Architecture ".*";#Architecture "${TARGET_ARCH}";#' \
- > "${STAGING_DIR}/etc/apt/apt-rootfs.conf"
+ > "${STAGING_DIR}${sysconfdir}/apt/apt-rootfs.conf"
- export APT_CONFIG="${STAGING_DIR}/etc/apt/apt-rootfs.conf"
+ export APT_CONFIG="${STAGING_DIR}${sysconfdir}/apt/apt-rootfs.conf"
export D=${IMAGE_ROOTFS}
export OFFLINE_ROOT=${IMAGE_ROOTFS}
export IPKG_OFFLINE_ROOT=${IMAGE_ROOTFS}
@@ -112,17 +112,17 @@ fakeroot rootfs_deb_do_rootfs () {
if [ -e ${IMAGE_ROOTFS}/usr/dpkg/alternatives ]; then
rmdir ${IMAGE_ROOTFS}/usr/dpkg/alternatives
fi
- if [ ! -e ${IMAGE_ROOTFS}/usr/lib/ipkg ] ; then
- mkdir -p ${IMAGE_ROOTFS}/usr/lib/ipkg
+ if [ ! -e ${IMAGE_ROOTFS}${libdir}/ipkg ] ; then
+ mkdir -p ${IMAGE_ROOTFS}${libdir}/ipkg
fi
- if [ ! -e ${IMAGE_ROOTFS}/etc/ipkg ] ; then
- mkdir -p ${IMAGE_ROOTFS}/etc/ipkg
+ if [ ! -e ${IMAGE_ROOTFS}${sysconfdir}/ipkg ] ; then
+ mkdir -p ${IMAGE_ROOTFS}${sysconfdir}/ipkg
fi
- ln -sf /usr/lib/ipkg/alternatives ${IMAGE_ROOTFS}/usr/dpkg/alternatives
- ln -sf /usr/dpkg/info ${IMAGE_ROOTFS}/usr/lib/ipkg/info
- ln -sf /usr/dpkg/status ${IMAGE_ROOTFS}/usr/lib/ipkg/status
+ ln -sf ${libdir}/ipkg/alternatives ${IMAGE_ROOTFS}/usr/dpkg/alternatives
+ ln -sf /usr/dpkg/info ${IMAGE_ROOTFS}${libdir}/ipkg/info
+ ln -sf /usr/dpkg/status ${IMAGE_ROOTFS}${libdir}/ipkg/status
${ROOTFS_POSTPROCESS_COMMAND}
@@ -150,6 +150,6 @@ rootfs_deb_log_check() {
}
remove_packaging_data_files() {
- rm -rf ${IMAGE_ROOTFS}/usr/lib/ipkg/
+ rm -rf ${IMAGE_ROOTFS}${libdir}/ipkg/
rm -rf ${IMAGE_ROOTFS}/usr/dpkg/
}
diff --git a/classes/rootfs_ipk.bbclass b/classes/rootfs_ipk.bbclass
index 6babee30a2..c6e2099e7c 100644
--- a/classes/rootfs_ipk.bbclass
+++ b/classes/rootfs_ipk.bbclass
@@ -39,8 +39,8 @@ fakeroot rootfs_ipk_do_rootfs () {
export D=${IMAGE_ROOTFS}
export OFFLINE_ROOT=${IMAGE_ROOTFS}
export IPKG_OFFLINE_ROOT=${IMAGE_ROOTFS}
- mkdir -p ${IMAGE_ROOTFS}/etc/ipkg/
- grep "^arch" ${IPKGCONF_TARGET} >${IMAGE_ROOTFS}/etc/ipkg/arch.conf
+ mkdir -p ${IMAGE_ROOTFS}${sysconfdir}/ipkg/
+ grep "^arch" ${IPKGCONF_TARGET} >${IMAGE_ROOTFS}${sysconfdir}/ipkg/arch.conf
for i in ${IMAGE_ROOTFS}${libdir}/ipkg/info/*.preinst; do
if [ -f $i ] && ! sh $i; then
@@ -82,5 +82,5 @@ rootfs_ipk_log_check() {
}
remove_packaging_data_files() {
- rm -rf ${IMAGE_ROOTFS}/usr/lib/ipkg/
+ rm -rf ${IMAGE_ROOTFS}${libdir}/ipkg/
}
diff --git a/classes/sdk.bbclass b/classes/sdk.bbclass
index 8067798000..441da77bd0 100644
--- a/classes/sdk.bbclass
+++ b/classes/sdk.bbclass
@@ -21,6 +21,7 @@ exec_prefix = "${prefix}"
base_prefix = "${exec_prefix}"
FILES_${PN} = "${prefix}"
-FILES_${PN}-dbg += "${prefix}/bin/.debug \
+FILES_${PN}-dbg += "${prefix}/.debug \
+ ${prefix}/bin/.debug \
${prefix}/sbin/.debug \
"