title: Minimal CMake building for android
body: <p>I'm trying to port a native C++ DLL to be a shared library on Android. For building, I am using VSCode, not using Visual Studio. Downloaded the Android NDK r18b. My project is CMake based, and when I try to generate it to be with the "NMake Mmakefiles" generator, I always get this error:</p>
  
  <pre><code>CMAKE_SYSTEM_NAME is 'Android' but 'NVIDIA Nsight Tegra Visual Studio Edition' is not installed.
  </code></pre>
  
  <p>I have created a small project to test this.</p>
  
  <p>main.cpp</p>
  
  <pre><code>int foo( int a, int b ) { return a + b; }
  </code></pre>
  
  <p>CMakeLists.txt</p>
  
  <pre><code>cmake_minimum_required( VERSION 3.11.0 )
  add_library( Engine SHARED main.cpp )
  </code></pre>
  
  <p>I run it with this command line (CMake 3.11.4):</p>
  
  <pre><code>cmake -g "NMake Makefiles" .. -DCMAKE_TOOLCHAIN_FILE=%NDK_ROOT%\build\cmake\android.toolchain.cmake -DANDROID_NDK=%NDK_ROOT%
  </code></pre>
  
  <p>With this one, I still get the error:</p>
  
  <pre><code>CMake Error in CMakeLists.txt:
  CMAKE_SYSTEM_NAME is 'Android' but 'NVIDIA Nsight Tegra Visual Studio Edition' is not installed.
  </code></pre>
  
  <p>Can someone help me to make this small main.cpp into an Android .so? I'd not like to use Android Studio nor an other IDE. Looking for creating a make file and add it to my VSCode build.</p>
  
  <p>Thank you.</p>