cannot find htonl

by taosinker » Thu, 13 Aug 2009 17:28:08 GMT


Sponsored Links
 Hi all:

When I build my native lib, an error find.
" undefined reference to `htonl'"


Do you have any advice?

Thanks

--~--~---------~--~----~------------~-------~--~----~



Other Threads

1. enable disable status of a menu item

dear all

I have an menu with two menu items called ITEM A and ITEM B both use
icon android.R.drawable.ic_menu_close_clear_cancel. At the first time
I set ITEM A is enabled, ITEM B is disabled. But the system shows both
are disabled except the menu text.
I do drag the ITEM A and the system shows both are enabled !!!

does anyone explain me why
thank you very much

--~--~---------~--~----~------------~-------~--~----~

2. Runtime Exception error, please help...my app does not run.

hi all,

this test code is to display a spinner, and adds an item, which is a
snapshot of a webview site (eg.  http://www.***.com/  , etc.

I am unable to get it to run/display on android emulator, and it shows
a runtime exception in my eclipse plugin de{*filter*}.

I am new to this, so your help is greatly appreciated.
-jeremy

--- code -----


import java.io.ByteArrayOutputStream;

import android.app.Activity;
import android.graphics.Bitmap;
import android.graphics.Picture;
import android.net.Uri;
import android.os.Bundle;
import android.webkit.WebView;
import android.widget.ArrayAdapter;
import android.widget.ImageView;
import android.widget.Spinner;


public class ws extends Activity {
    /** Called when the activity is first created. */

        public Spinner spinner;
        public WebView wv;
        public ImageView img;

        @Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        this.initSpinner();
        setContentView(R.layout.slidex);
        //this.initSpinner();

    }


    public void initSpinner()
    {
        this.spinner = (Spinner)this.findViewById(R.id.spinner1);
        this.wv = new WebView(this);

        this.wv.loadUrl(" http://www.***.com/ ");
        this.img = new ImageView(this);
        this.img.setMaxHeight(100);
        this.img.setMaxWidth(50);
        Picture pic = this.wv.capturePicture();
        ByteArrayOutputStream bs = new ByteArrayOutputStream();
        pic.writeToStream(bs);
        byte [] bdata = bs.toByteArray();
        int [] idata = new int[bdata.length+1];
        this.img.setImageBitmap(Bitmap.createBitmap(idata,50,100,
Bitmap.Config.ALPHA_8));
        //this.img.setImageURI(pic);

          //ArrayAdapter adapter = new ArrayAdapter
(this,R.id.spinner1);
          //adapter.add(this.img);
        try {
        this.spinner.addView(this.img);
        }catch(RuntimeException rt)
        {
        rt.printStackTrace();
        }


    }

}

--~--~---------~--~----~------------~-------~--~----~

3. Built-In Search Bar Widget??

4. Testing Tips

5. how to achieve HTTPS client authentication

6. How to Send SMS in Android

7. load image from the web?