Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6684471
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T04:56:38+00:00 2026-05-26T04:56:38+00:00

I’m trying to make a simple build script that would work on windows and

  • 0

I’m trying to make a simple build script that would work on windows and unix systems.
The script is to be run from cygwin if windows, otherwise just a standard shell.

The script will do the following:

  1. set the directory variable SDK_ROOT to ‘/cygdrive/C/PROGRA~2/Android/android-sdk/’
  2. set the directory variable NDK_ROOT to ‘/cygdrive/C/PROGRA~2/android-ndk-r6b’
  3. cd Android/bin/
  4. run javah -d ../../test/mytest/ -classpath .:$SDK_ROOT/platforms/android-8/android.jar com.test.MyTest
  5. cd ..
  6. run $NDK_ROOT/ndk-build

I’m not sure what kind of scripting language to use nor its syntax, I only know it would roughly look like above. Any ideas on how to proceed?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-26T04:56:38+00:00Added an answer on May 26, 2026 at 4:56 am

    It seems to me that you already wrote the script, it just needs a few modifications:

    Windows
    myscript.cmd

    @ECHO OFF
    setlocal
    
    SET SDK_ROOT=C:\PROGRA~2\Android\android-sdk\
    SET NDK_ROOT=C:\PROGRA~2\android-ndk-r6b\
    CD Android/bin/
    javah -d ../../test/mytest/ -classpath .:%SDK_ROOT%/platforms/android-8/android.jar com.test.MyTest
    CD ..
    RUN %NDK_ROOT%/ndk-build
    
    endlocal
    

    Unix
    myscript.sh

    #!/bin/bash
    SDK_ROOT="/cygdrive/C/PROGRA~2/Android/android-sdk/"
    NDK_ROOT="/cygdrive/C/PROGRA~2/android-ndk-r6b"
    cd Android/bin/
    javah -d ../../test/mytest/ -classpath .:${SDK_ROOT}/platforms/android-8/android.jar com.test.MyTest
    cd ..
    $NDK_ROOT/ndk-build
    

    Also, make sure that javah exists in your PATH env variable.
    if it doesn’t exist, you can add it to the scripts at the beginning:

    Windows
    SET PATH=c:\path\to\javah;%PATH%

    Unix
    export PATH=/path/to/javah:$PATH

    Note: you might have to modify the sdk/ndk paths for the script on windows.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm parsing an RSS feed that has an ’ in it. SimpleXML turns this
I'm trying to decode HTML entries from here NYTimes.com and I cannot figure out
I'm trying to create an if statement in PHP that prevents a single post
I am trying to understand how to use SyndicationItem to display feed which is
Basically, what I'm trying to create is a page of div tags, each has
link Im having trouble converting the html entites into html characters, (&# 8217;) i
That's pretty much it. I'm using Nokogiri to scrape a web page what has
I have just tried to save a simple *.rtf file with some websites and
For some reason, after submitting a string like this Jack’s Spindle from a text
I've got a string that has curly quotes in it. I'd like to replace

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.