# All Builds Fails 'linux/user.h' file not found'

**URL:** <https://discuss.bitrise.io/t/all-builds-fails-linux-user-h-file-not-found/5189>\
**Category:** Builds\
**Tags:** android, android-ndk\
**Created:** [May 25, 2018, 1:50pm UTC](https://discuss.bitrise.io/t/all-builds-fails-linux-user-h-file-not-found/5189 "2018-05-25T13:50:30Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![FeleConvo](https://avatars.discourse-cdn.com/v4/letter/f/ccd318/32.png) [@FeleConvo](https://discuss.bitrise.io/u/FeleConvo)\
**Post date:** [May 25, 2018, 1:50pm UTC](https://discuss.bitrise.io/t/all-builds-fails-linux-user-h-file-not-found/5189/1 "2018-05-25T13:50:30Z")

</div>

# Bitrise Build Issue Report template

## Description of the issue

/bitrise/src/app/src/main/jni/radvision/include/rvadthread\_t.h:24:10: fatal error: ‘linux/user.h’ file not found  
#include \<linux/user.h\>  
1 warning and 1 error generated.  
make: Leaving directory `/bitrise/src/app/src/main/jni’

## Environment:

**Where did the issue happen?**

On Bitrise

Which stack?

Android & Docker, on Ubuntu 14.04 - LTS Stack

**Which build Step causes the issue and which version of the step?**

NDK Build 1.1.5

## Reproducibility

- _Does a “Rebuild” help? (You can trigger a rebuild from the Build’s page, by clicking the “Rebuild” button in the top right corner of a finished build)_ : NO
- _Does a rebuild without caches help? (You can remove the `Cache:Pull` and `Cache:Push` steps temporarily to not to use the cache, or [you can delete all the caches on the `Settings` tab of the app](http://devcenter.bitrise.io/caching/about-caching/#downloading-and-deleting-caches)._ : NO
- _Does the issue happen sporadically, or every time?_ : EVERYTIME
- _Does upgrading the build Step to the latest version help?_ : NO
- _When did the issue start?_ : 21st of this month

### Local reproduction

\_Can it be reproduced on your own Mac/PC

\_Testing with a full clean git clone

Works locally

## Build log

> **[Log in - Bitrise](https://app.bitrise.io/users/sign_in)**
>
> Bringing back the joy of iOS & Android development through automating build, testing and support cycles.

---

<div class="post-metadata">

**Author:** ![BirmacherAkos](https://sea2.discourse-cdn.com/flex016/user_avatar/discuss.bitrise.io/birmacherakos/32/1319_2.png) [@BirmacherAkos](https://discuss.bitrise.io/u/BirmacherAkos)\
**Post date:** [May 28, 2018, 2:50pm UTC](https://discuss.bitrise.io/t/all-builds-fails-linux-user-h-file-not-found/5189/2 "2018-05-28T14:50:21Z")

</div>

Hi!

Could we try this how-to? [How to install a specific Android NDK version on the Android NDK stack](http://discuss.bitrise.io/t/how-to-install-a-specific-android-ndk-version-on-the-android-ndk-stack/4400) just instead of `r15b` put `r10e`. (so just a quick summary of what to do:

open the Workflow editor  
Add a script step as the first step in the workflow and add the script from the discuss link to the input of the script step.  
Replace `r15b` with `r10e` in the script)

---

<div class="post-metadata">

**Author:** ![FeleConvo](https://avatars.discourse-cdn.com/v4/letter/f/ccd318/32.png) [@FeleConvo](https://discuss.bitrise.io/u/FeleConvo)\
**Post date:** [May 28, 2018, 3:04pm UTC](https://discuss.bitrise.io/t/all-builds-fails-linux-user-h-file-not-found/5189/3 "2018-05-28T15:04:45Z")

</div>

Hi Akos,

This was solved.

The issue was caused by the changed made to the NDK here: [https://github.com/bitrise-io/bitrise.io/commit/a62cbec806f1662611a9fc7e8cb0ff287402334e#diff-8ad163f79d9960c2636a7d60054d5d9b](https://github.com/bitrise-io/bitrise.io/commit/a62cbec806f1662611a9fc7e8cb0ff287402334e#diff-8ad163f79d9960c2636a7d60054d5d9b)

It was solved by using the script

```auto
#!/usr/bin/env bash
set -ex

# set env vars
export ANDROID_NDK_VERSION='r15b'
export ANDROID_NDK_HOME='/opt/android-ndk'
# expose for subsequent steps
envman add --key ANDROID_NDK_HOME --value "$ANDROID_NDK_HOME"

# ------------------------------------------------------
# --- Android NDK

# clean up if a previous version is already installed
rm -rf "$ANDROID_NDK_HOME"

# download
mkdir /opt/android-ndk-tmp
cd /opt/android-ndk-tmp
wget -q https://dl.google.com/android/repository/android-ndk-${ANDROID_NDK_VERSION}-linux-x86_64.zip

# uncompress
unzip -q android-ndk-${ANDROID_NDK_VERSION}-linux-x86_64.zip

# move to its final location
mv ./android-ndk-${ANDROID_NDK_VERSION} ${ANDROID_NDK_HOME}

```

From: [How to install a specific Android NDK version on the Android NDK stack](http://discuss.bitrise.io/t/how-to-install-a-specific-android-ndk-version-on-the-android-ndk-stack/4400)

Thanks.

Best regards.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex016/uploads/bitrise/original/2X/d/d901cf2aad020f2dd11918afc89ec2089bb87b35.png) [@system](https://discuss.bitrise.io/u/system)\
**Post date:** [June 27, 2018, 3:04pm UTC](https://discuss.bitrise.io/t/all-builds-fails-linux-user-h-file-not-found/5189/4 "2018-06-27T15:04:45Z")

</div>

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.
