3

The method to build lineageos from source used to be very straight forward but I'm not having success when building it to the device hero2lte which is the Samsung galaxy S7 Edge.

To reproduce the issue, just follow the build steps according to official documentation, the only difference is that I'm trying to build lineage-15.1 branch instead.

repo init -u https://github.com/LineageOS/android.git -b lineage-15.1

And I also tried adding manually the repos for the device, kernel and vendor trees in local_manifests.xml:

<?xml version="1.0" encoding="UTF-8"?>
<manifest>

    <remote name="vendor"

            fetch="https://github.com"

            revision="lineage-15.1" />



    <remote name="device"

            fetch="https://github.com"

            revision="lineage-15.1"/>



    <remote name="kernel"

            fetch="https://github.com"

            revision="lineage-15.1"/>

  <project name="TheMuppets/proprietary_vendor_samsung" path="vendor/samsung" remote="vendor"/>
  <project name="LineageOS/android_device_samsung_hero2lte" path="device/samsung/hero2lte" remote="device" />
  <project name="LineageOS/android_hardware_samsung" path="hardware/samsung" remote="github" />
  <project name="LineageOS/android_kernel_samsung_universal8890" path="kernel/samsung/universal8890" remote="kernel" />
</manifest>

But every way I try ends up in the error when I run breakfast hero2lte:

including vendor/lineage/vendorsetup.sh
build/core/product_config.mk:243: *
_nic.PRODUCTS.[[device/samsung/hero2lte/lineage.mk]]: "device/samsung/hero-common/hero-common.mk" does not exist. Stop.
Device hero2lte not found. Attempting to retrieve device repository
from LineageOS Github (http://github.com/LineageOS). Found repository:
android_device_samsung_hero2lte Default revision: lineage-15.1
Checking branch info Checking if device/samsung/hero2lte is fetched
from android_device_samsung_hero2lte
LineageOS/android_device_samsung_hero2lte already fetched to
device/samsung/hero2lte Syncing repository to retrieve project.
remote: Enumerating objects: 13, done. remote: Counting
objects: 100% (13/13), done. remote: Compressing objects: 100%
(11/11), done. remote: Total 17 (delta 4), reused 7 (delta 1),
pack-reused 4 From git://github.com/LineageOS/android
f56ece1..800af59 lineage-16.0 -> origin/lineage-16.0
43f3fd0..152210f lineage-17.0 -> origin/lineage-17.0 fatal: duplicate
path device/samsung/hero2lte in
/home/fabio/android/lineage15.1/.repo/manifest.xml Repository synced!
Looking for dependencies in device/samsung/hero2lte Looking for
dependencies in device/samsung/hero-common device/samsung/hero-common
has no additional dependencies. Done build/core/product_config.mk:243:
*
_nic.PRODUCTS.[[device/samsung/hero2lte/lineage.mk]]: "device/samsung/hero-common/hero-common.mk" does not exist. Stop.

build/core/product_config.mk:243: ***
_nic.PRODUCTS.[[device/samsung/hero2lte/lineage.mk]]: "device/samsung/hero-common/hero-common.mk" does not exist. Stop.

** Don't have a product spec for: 'lineage_hero2lte'
** Do you have the right repo manifest?

EDIT In my example I'm building for lineage-15.1 but I'm accepting answers for lineage-16.0 or lineage-17.1 too. Thanks in advance.

Fnr
  • 2,096
  • 7
  • 41
  • 76
  • it's probably not the source of the problem, but `fatal: duplicate path device/samsung/hero2lte in /home/fabio/android/lineage15.1/.repo/manifest.xml` looks suspiciously, I recommend checking what causes that, may be something else is wrong too – Mixaz Sep 24 '19 at 21:02
  • also you may try to use https://github.com/ivanmeler/local_manifests/blob/heroXlte-lineage-15.1/roomservice.xml - AFAIK Ivan Meler is the author of hero2lte LineageOS port https://forum.xda-developers.com/s7-edge/development/lineageos-15-android-8-0-0-s7-edge-t3710101 – Mixaz Sep 24 '19 at 21:07
  • @Mixaz I've tried adding his repos but I am still having the same error – Fnr Oct 09 '19 at 11:56
  • sorry, I don't know what's going on in your log. You can try to ask this question in #lineageos-dev IRC channel at freenode, may be somebody faced that issues. Post link to this question there. – Mixaz Oct 11 '19 at 20:40
  • I’m voting to close this question because it belongs on [android.se]. It's not about programming. – Evan Carroll Nov 20 '20 at 01:22

1 Answers1

1

It looks like your local_manifest.xml is missing the hero-common repo.

<project name="LineageOS/android_device_samsung_hero-common" path="device/samsung/hero-common" remote="device" />
Simpl
  • 1,938
  • 1
  • 10
  • 21
  • No, I have this repo in another manifest bcz when I added to the local it failed with error message saying that it's duplicated – Fnr Sep 24 '19 at 18:38
  • Does `device/samsung/hero-common/hero-common.mk` exist in your AOSP? – Simpl Sep 24 '19 at 18:40