Standalone toolchains

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

Standalone toolchains

John Dallman
I use a standalone toolchain, but not Android Studio. I'm not actually building an Android app, at all, ever. Instead, I build with a stand-alone toolchain, and link that into a command-line test harness which I run in the ADB shell. My development and testing devices are permanently connected to the Linux machines I use for building and testing. 

All of my building is done with the tools from the standalone toolchain, and I don't use Gradle, CMake, or any other tools supplied with Android Studio: I'm building code which has its own build system, and the standalone toolchain is the easy way to plug Android tools into that. I'm only supporting one ABI, 64-bit ARM, so I only need one toolchain. 

In the NDK r19 release notes, I see: 

Issue 780: Standalone toolchains are now unnecessary. Clang, binutils, the sysroot, and other toolchain pieces are now all installed to $NDK/toolchains/llvm/prebuilt/<host-tag> and Clang will automatically find them.

I have two questions about this: 

Can I copy $NDK/toolchains/llvm/prebuilt/<host-tag> and its subdirectories out of there, and put them elsewhere? I do that with my current standalone toolchain, and put it on server disk so that all my Linux build machines can see and use the same copy of the toolchain. I'm quite keen to carry on organizing it that way, and not to use up server disk space with a copy of Android Studio that I will never use. 

Presumably I now need to specify the Android API level and STL explicitly in my compile command lines? Until now, I've just used the "clang" script that building a standalone toolchain created for me, which put those options on the command line automatically, 

Thanks in advance,

John

--
You received this message because you are subscribed to the Google Groups "android-ndk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/android-ndk.
To view this discussion on the web visit https://groups.google.com/d/msgid/android-ndk/CAH1xqg%3D-3Y_FJRRO%3DFN8cFtv8Yz966xmTSb1t6_xL9ofptxn9Q%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Standalone toolchains

Dan Albert
They should be relocatable, although I don't believe I've tried that. You wouldn't need a full studio install even if they aren't; just an NDK (though I'd like to fix the relocatability issues if they aren't).



On Tue, Jan 22, 2019, 08:07 John Dallman <[hidden email] wrote:
I use a standalone toolchain, but not Android Studio. I'm not actually building an Android app, at all, ever. Instead, I build with a stand-alone toolchain, and link that into a command-line test harness which I run in the ADB shell. My development and testing devices are permanently connected to the Linux machines I use for building and testing. 

All of my building is done with the tools from the standalone toolchain, and I don't use Gradle, CMake, or any other tools supplied with Android Studio: I'm building code which has its own build system, and the standalone toolchain is the easy way to plug Android tools into that. I'm only supporting one ABI, 64-bit ARM, so I only need one toolchain. 

In the NDK r19 release notes, I see: 

Issue 780: Standalone toolchains are now unnecessary. Clang, binutils, the sysroot, and other toolchain pieces are now all installed to $NDK/toolchains/llvm/prebuilt/<host-tag> and Clang will automatically find them.

I have two questions about this: 

Can I copy $NDK/toolchains/llvm/prebuilt/<host-tag> and its subdirectories out of there, and put them elsewhere? I do that with my current standalone toolchain, and put it on server disk so that all my Linux build machines can see and use the same copy of the toolchain. I'm quite keen to carry on organizing it that way, and not to use up server disk space with a copy of Android Studio that I will never use. 

Presumably I now need to specify the Android API level and STL explicitly in my compile command lines? Until now, I've just used the "clang" script that building a standalone toolchain created for me, which put those options on the command line automatically, 

Thanks in advance,

John

--
You received this message because you are subscribed to the Google Groups "android-ndk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/android-ndk.
To view this discussion on the web visit https://groups.google.com/d/msgid/android-ndk/CAH1xqg%3D-3Y_FJRRO%3DFN8cFtv8Yz966xmTSb1t6_xL9ofptxn9Q%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "android-ndk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/android-ndk.
To view this discussion on the web visit https://groups.google.com/d/msgid/android-ndk/CAFVaGhvWfW3P-3VzmaUFDJBLL9RcvzqXXk3nbXnAeYYeFZ8wng%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Standalone toolchains

John Dallman
Thanks for that. I'll try this when I get closer to updating my NDK. 

John

On Tue, Jan 22, 2019 at 6:21 PM 'Dan Albert' via android-ndk <[hidden email]> wrote:
They should be relocatable, although I don't believe I've tried that. You wouldn't need a full studio install even if they aren't; just an NDK (though I'd like to fix the relocatability issues if they aren't).



On Tue, Jan 22, 2019, 08:07 John Dallman <[hidden email] wrote:
I use a standalone toolchain, but not Android Studio. I'm not actually building an Android app, at all, ever. Instead, I build with a stand-alone toolchain, and link that into a command-line test harness which I run in the ADB shell. My development and testing devices are permanently connected to the Linux machines I use for building and testing. 

All of my building is done with the tools from the standalone toolchain, and I don't use Gradle, CMake, or any other tools supplied with Android Studio: I'm building code which has its own build system, and the standalone toolchain is the easy way to plug Android tools into that. I'm only supporting one ABI, 64-bit ARM, so I only need one toolchain. 

In the NDK r19 release notes, I see: 

Issue 780: Standalone toolchains are now unnecessary. Clang, binutils, the sysroot, and other toolchain pieces are now all installed to $NDK/toolchains/llvm/prebuilt/<host-tag> and Clang will automatically find them.

I have two questions about this: 

Can I copy $NDK/toolchains/llvm/prebuilt/<host-tag> and its subdirectories out of there, and put them elsewhere? I do that with my current standalone toolchain, and put it on server disk so that all my Linux build machines can see and use the same copy of the toolchain. I'm quite keen to carry on organizing it that way, and not to use up server disk space with a copy of Android Studio that I will never use. 

Presumably I now need to specify the Android API level and STL explicitly in my compile command lines? Until now, I've just used the "clang" script that building a standalone toolchain created for me, which put those options on the command line automatically, 

Thanks in advance,

John

--
You received this message because you are subscribed to the Google Groups "android-ndk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/android-ndk.
To view this discussion on the web visit https://groups.google.com/d/msgid/android-ndk/CAH1xqg%3D-3Y_FJRRO%3DFN8cFtv8Yz966xmTSb1t6_xL9ofptxn9Q%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "android-ndk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/android-ndk.
To view this discussion on the web visit https://groups.google.com/d/msgid/android-ndk/CAFVaGhvWfW3P-3VzmaUFDJBLL9RcvzqXXk3nbXnAeYYeFZ8wng%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "android-ndk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/android-ndk.
To view this discussion on the web visit https://groups.google.com/d/msgid/android-ndk/CAH1xqgmx2m%2B7REmNY4VGXNz7i5M%2BxQn8g5xAzD76KrMEimLc4g%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Standalone toolchains

John Dallman
Well, I finally got to updating NDK, and had no trouble with this. Thanks very much.

John

On Wed, Jan 23, 2019 at 9:47 AM John Dallman <[hidden email]> wrote:
Thanks for that. I'll try this when I get closer to updating my NDK. 

John

On Tue, Jan 22, 2019 at 6:21 PM 'Dan Albert' via android-ndk <[hidden email]> wrote:
They should be relocatable, although I don't believe I've tried that. You wouldn't need a full studio install even if they aren't; just an NDK (though I'd like to fix the relocatability issues if they aren't).



On Tue, Jan 22, 2019, 08:07 John Dallman <[hidden email] wrote:
I use a standalone toolchain, but not Android Studio. I'm not actually building an Android app, at all, ever. Instead, I build with a stand-alone toolchain, and link that into a command-line test harness which I run in the ADB shell. My development and testing devices are permanently connected to the Linux machines I use for building and testing. 

All of my building is done with the tools from the standalone toolchain, and I don't use Gradle, CMake, or any other tools supplied with Android Studio: I'm building code which has its own build system, and the standalone toolchain is the easy way to plug Android tools into that. I'm only supporting one ABI, 64-bit ARM, so I only need one toolchain. 

In the NDK r19 release notes, I see: 

Issue 780: Standalone toolchains are now unnecessary. Clang, binutils, the sysroot, and other toolchain pieces are now all installed to $NDK/toolchains/llvm/prebuilt/<host-tag> and Clang will automatically find them.

I have two questions about this: 

Can I copy $NDK/toolchains/llvm/prebuilt/<host-tag> and its subdirectories out of there, and put them elsewhere? I do that with my current standalone toolchain, and put it on server disk so that all my Linux build machines can see and use the same copy of the toolchain. I'm quite keen to carry on organizing it that way, and not to use up server disk space with a copy of Android Studio that I will never use. 

Presumably I now need to specify the Android API level and STL explicitly in my compile command lines? Until now, I've just used the "clang" script that building a standalone toolchain created for me, which put those options on the command line automatically, 

Thanks in advance,

John

--
You received this message because you are subscribed to the Google Groups "android-ndk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/android-ndk.
To view this discussion on the web visit https://groups.google.com/d/msgid/android-ndk/CAH1xqg%3D-3Y_FJRRO%3DFN8cFtv8Yz966xmTSb1t6_xL9ofptxn9Q%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "android-ndk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/android-ndk.
To view this discussion on the web visit https://groups.google.com/d/msgid/android-ndk/CAFVaGhvWfW3P-3VzmaUFDJBLL9RcvzqXXk3nbXnAeYYeFZ8wng%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "android-ndk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/android-ndk/CAH1xqg%3Do_V0CPg73WcJhtPn8_ZSJ6e3BuK%2BEUWSL8mBxOp5bVg%40mail.gmail.com.