Skip to content

Commit db4c9f9

Browse files
committed
Merge pull request #56 from lbt/hybris-10.1
maguro make update; fix hammerhead Provides; use -j <n> in make
2 parents e18dfe2 + df2179f commit db4c9f9

File tree

3 files changed

+19
-10
lines changed

3 files changed

+19
-10
lines changed

droid-hal-device.inc

Lines changed: 14 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,22 @@
1-
# This file should be %included into a device specific spec file
1+
# This file should be %%included into a device specific spec file
22
# where macros are defined:
33
# device: should be the CM codename
44
# vendor: determine the directory used for ./device/<vendor>/<device>
55
# device_pretty: User-visible model name of the device
66
# vendor_pretty: User-visible manufacturer name of the device
7+
# hadk_make_target: the target used when running make in the HABUILD_SDK on the OBS. Defaults to "hybris-hal"
78

89
%define __provides_exclude_from ^%{_libexecdir}/droid-hybris/.*$
910
%define android_root .
1011
%define rel_date %(date +'%%Y%%m%%d%%H%%M')
1112

13+
# On the OBS this package should be built in the i486 scheduler against
14+
# mer/sailfish *_i486 targets.
15+
# The prjconf should have an ExportFilter like this (mer/sailfish has this):
16+
# ExportFilter: \.armv7hl\.rpm$ armv8el
17+
# We lie about our architecture and allows OBS to cross-publish this 486 cross-built spec to the armv7hl repos
18+
%define _target_cpu armv7hl
19+
1220
# Support build info extracted from OBS builds too
1321
%if 0%{?_obs_build_project:1}
1422
%define _build_flavour %(echo %{_obs_build_project} | awk -F : '{if (NF == 3) print $3; else if (NF == 2) print strdevel; else print strunknown}' strdevel=devel strunknown=unknown)
@@ -37,10 +45,6 @@ Name: droid-hal-%{device}
3745
Version: 0.0.6
3846
Release: %{rel_date}
3947
Provides: droid-hal
40-
%if %{device} == hammerhead
41-
# Each device that provides files in /etc/ofono should have this provides
42-
Provides: ofono-configs
43-
%endif
4448
Provides: flash-partition
4549
# The repo sync service on OBS prepares a 'source tarball' of the rpm
4650
# dir since we currently have a complex setup with subdirs which OBS
@@ -89,7 +93,7 @@ BuildRequires: sudo-for-abuild
8993
################
9094
%package devel
9195
Group: Development/Tools
92-
# Requires: %{name} = %{version}-%{release}
96+
# Requires: %%{name} = %%{version}-%%{release}
9397
Provides: droid-hal-devel
9498
Summary: Development files for droid-hal device: %{device}
9599

@@ -249,7 +253,7 @@ cp %{SOURCE40} %{SOURCE0}
249253
%if 0%{?_obs_build_project:1}
250254
# Hadk style build of android on OBS
251255
echo Running droid build in HABUILD_SDK
252-
ubu-chroot -r /srv/mer/sdks/ubu "cd %android_root; source build/envsetup.sh; breakfast %{device}; rm -f .repo/local_manifests/roomservice.xml; make hybris-hal"
256+
ubu-chroot -r /srv/mer/sdks/ubu "cd %android_root; source build/envsetup.sh; breakfast %{device}; rm -f .repo/local_manifests/roomservice.xml; make %{?_smp_mflags} %{?hadk_make_target}%{!?hadk_make_target:hybris-hal}"
253257
%endif
254258

255259
# Make a tmp location for built installables
@@ -384,7 +388,7 @@ mkdir -p $RPM_BUILD_ROOT%{_libdir}/pkgconfig/
384388
mv $HDRS/android-headers.pc $RPM_BUILD_ROOT%{_libdir}/pkgconfig/
385389

386390
# If this ever becomes unmanageable then
387-
# grep -l dev/alog %{android_root}/out/target/product/%{device}/system/lib/*
391+
# grep -l dev/alog %%{android_root}/out/target/product/%{device}/system/lib/*
388392
# libdsyscalls.so and libc.so are blacklisted
389393
ln -s ../system/lib/{liblog.so,libcutils.so} $RPM_BUILD_ROOT%{_libexecdir}/droid-hybris/lib-dev-alog/.
390394

@@ -400,7 +404,7 @@ cp -a %{SOURCE12} $RPM_BUILD_ROOT/
400404

401405
# droid user support This may be better done by passing a list of
402406
# users/groups and running 'ensure_usergroups_exist newlist oldlist'
403-
# which would preserve oldlist in %post and delete any users no longer
407+
# which would preserve oldlist in %%post and delete any users no longer
404408
# needed (unlikely!). This avoids the transient removal of uids and
405409
# group issues
406410
install -D tmp/rpmsrc/droid-user-add.sh $RPM_BUILD_ROOT%{_libdir}/droid/droid-user-add.sh
@@ -453,7 +457,7 @@ sed -e 's|%DEVICE%|%{device}|g' \
453457
-e "s|%ARCH%|%{__isa_name}|g" \
454458
rpm/ssu/board-mappings.d/05-sfe.ini.in >$RPM_BUILD_ROOT/%{board_mapping_file}
455459

456-
# Copy kickstart packs (for %{device}-kickstart-configuration)
460+
# Copy kickstart packs (for %%{device}-kickstart-configuration)
457461
mkdir -p $RPM_BUILD_ROOT/%{_datadir}/ssu/kickstart/pack/%{device}
458462
sed -e 's|@DEVICE@|%{device}|g' rpm/kickstart/pack/package-droid-updater > $RPM_BUILD_ROOT/%{_datadir}/ssu/kickstart/pack/%{device}/package-droid-updater
459463
# and attachments

droid-hal-hammerhead.spec

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,8 @@
1212

1313
Requires: rfkill
1414
Requires: bluez >= 4.101+git33
15+
# Each device that provides files in /etc/ofono should have this provides
16+
Provides: ofono-configs
1517

1618
%include rpm/droid-hal-device.inc
1719

droid-hal-maguro.spec

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,4 +10,7 @@
1010

1111
%define enable_kernel_update 1
1212

13+
# This modifies the 'make' target in the HABUILD_SDK make when run on the OBS
14+
%define hadk_make_target brcm_patchram_plus hybris-hal
15+
1316
%include rpm/droid-hal-device.inc

0 commit comments

Comments
 (0)