How do you compile JNI in Linux

I do JNI well windows using command line facility from Visual Studio but i have never learnt compiling native code for Linux...

A makefile would probably make the most sense. Here's the docs for the GNU make - http://www.delorie.com/gnu/docs/make/make_toc.html

Similar Messages

  • How do you compile Flex-dependent classes with ASC?

    Hi,
    I've been trying unsuccessfully for most of the evening to compile a .as file that relies on mx.collections.ListCollectionView using asc. I figured I could just import the Flex framework SWCs from the command line with asc, but asc doesn't seem to respect SWCs - it only seems to respect .abc files.
    So, I've spent most of my time trying to compile the Flex framework into a single .abc file that I can import whenever I want to compile a class that relies on Flex. I figured I could make a base .as file with include statements for all of the Flex .as files (copying the approach I saw for files like builtin.as) and compile that, but all I seem to get are compiler errors - mostly "[Compiler] Error #1181: Forward reference to base class (base class name)."
    I have a feeling I'm doing this completely the wrong way. I'd very much appreciate any assistance that anybody can offer me.
    Thanks,
    - max

    <div class=Section1><br /><br /><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";<br />color:#1F497D'>I use MXMLC to compile my .as file projects.<o:p></o:p></span></p><br /><br /><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";<br />color:#1F497D'><o:p> </o:p></span></p><br /><br /><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";<br />color:#1F497D'>Alex Harui<o:p></o:p></span></p><br /><br /><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";<br />color:#1F497D'>Flex SDK Developer<o:p></o:p></span></p><br /><br /><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";<br />color:#1F497D'><a href="http://www.adobe.com/"><span style='color:blue'>Adobe<br />Systems Inc.</span></a><o:p></o:p></span></p><br /><br /><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";<br />color:#1F497D'>Blog: <a href="http://blogs.adobe.com/aharui"><span<br />style='color:blue'>http://blogs.adobe.com/aharui</span></a><o:p></o:p></span></p><br /><br /><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";<br />color:#1F497D'><o:p> </o:p></span></p><br /><br /><div style='border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0in 0in 0in'><br /><br /><p class=MsoNormal><b><span style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'>From:</span></b><span<br />style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'> Maxim Porges<br />[mailto:[email protected]] <br><br /><b>Sent:</b> Monday, February 09, 2009 9:22 PM<br><br /><b>To:</b> [email protected]<br><br /><b>Subject:</b> How do you compile Flex-dependent classes with ASC?<o:p></o:p></span></p><br /><br /></div><br /><br /><p class=MsoNormal><o:p> </o:p></p><br /><br /><p class=MsoNormal style='margin-bottom:12.0pt'>A new discussion was started by<br />Maxim Porges in <br><br /><br><br /><b>Developers</b> --<br><br />  How do you compile Flex-dependent classes with ASC?<br><br /><br><br />Hi, <br><br /><br><br />I've been trying unsuccessfully for most of the evening to compile a .as file<br />that relies on mx.collections.ListCollectionView using asc. I figured I could<br />just import the Flex framework SWCs from the command line with asc, but asc<br />doesn't seem to respect SWCs - it only seems to respect .abc files. <br><br /><br><br />So, I've spent most of my time trying to compile the Flex framework into a<br />single .abc file that I can import whenever I want to compile a class that<br />relies on Flex. I figured I could make a base .as file with include statements<br />for all of the Flex .as files (copying the approach I saw for files like<br />builtin.as) and compile that, but all I seem to get are compiler errors -<br />mostly &quot;[Compiler] Error #1181: Forward reference to base class (base<br />class name).&quot; <br><br /><br><br />I have a feeling I'm doing this completely the wrong way. I'd very much<br />appreciate any assistance that anybody can offer me. <br><br /><br><br />Thanks, <br><br /><br><br />- max <o:p></o:p></p><br /><br /><div class=MsoNormal><br /><br /><hr size=2 width=200 style='width:150.0pt' align=left><br /><br /></div><br /><br /><p class=MsoNormal style='margin-bottom:12.0pt'>View/reply at <a<br />href="http://www.adobeforums.com/webx?13@@.59b7d5d2">How do you compile<br />Flex-dependent classes with ASC?</a><br><br />Replies by email are OK.<br><br />Use the <a<br />href="http://www.adobeforums.com/webx?280@@.59b7d5d2!folder=.3c060fa3">unsubscribe</a>< br />form to cancel your email subscription.<o:p></o:p></p><br /><br /></div>

  • How do you exit the Arch Linux installer?

    How do you exit the Arch Linux installer? I decided to install windows before installing Arch Linux because I want to dual-boot/with those operating systems.
    What command should I type to exit & eject my Install CD?

    reset button?
    I think it depends on far into the process you are, if you are formatting the drive anew then it shouldn't matter much when, where, or how
    Best of Luck,
    Pat Jr.
    Last edited by PatJr (2009-01-21 14:49:42)

  • How do you compile multiple class files in a unix cmd prompt?

    I have been using Java for a few years now, but for some reason I have a course that requires us to compile/run and hand-in our java assignments using Unix...
    I know how to compile a simple program on unix with a single source file, but how the heck do you compile and run a program with say... 2 or more sources files linked together?
    I really doubt the answer is just type
    javac java1.java
    javac java2.java
    javac java3.java
    and then running the source file with the main in it.
    Hopefully someone here can help me.
    Thanks
    Roger

    okay, well I took some time to read up online how to do this and I guess i'll answer my own post just in case someone else wants to know the answer.
    2 ways I found were:
    1)For example, you can list all of the source file names in a file named sourcefiles. This file might look like:
    MyClass1.java
    MyClass2.java
    MyClass3.java
    You could then run the compiler with:
    % javac @sourcefiles
    2)Or if all the files are in the same directory you can do this:
    This example compiles all the source files in the package greetings.
    % ls
    greetings/
    % ls greetings
    Aloha.java GutenTag.java Hello.java Hi.java
    % javac greetings/*.java
    If that is confusing to read I found all the answers from this webpage:
    http://java.sun.com/j2se/1.3/docs/tooldocs/solaris/javac.html

  • How do you compile movie on new iMovie app?

    I have been a user of the prior iMovie software.  I now have the newest version and am puzzled since when compiling a new video I cannot figure how to save it into a file which I can burn to a disk which will play on my standard blu-ray player.  When I complete a video in the new iMovie and click on "Share" and select "file" is saves a file in my computer but the file will not play on the DVD.  How do you go from the compiled video in iMovie and get a burnable file which will play on the DVD? (If I click on this file to open it, it will not open.) Is there some other software which is necessary? Thank you for any suggestions?  I did download "Quicktime Player 7 Pro" into my utility folder, but I can't see how this helps.

    Top menu> imovie> preferences> General> Show advanced tools.

  • How to successfully compile form in Linux

    Hi there,
    I have a form, which is called: TESTFORM.fmb
    I tried to compile this form using the following command:
    export LD_LIBRARY_PATH=/u0/oracle/prodora/8.0.6/lib
    f60gen module=/u0/oracle/prodappl/ar/11.5.0/forms/US/TESTFORM.fmb USERID=apps/passwordAlthough fmx is successfully generated, the following error is also encountered during compile:
    FRM-18108: Failed to load the following objects.
    Source Module:APPSTAND
    Source Object: STANDARD_PC_AND_VA
    Source Module:APPSTAND
    Source Object: STANDARD_TOOLBAR
    Source Module:APPSTAND
    Source Object: STANDARD_CALENDAR
    I look for APPSTAND.fmb and I found it in this location: /u0/oracle/prodappl/ar/11.5.0/forms/US/
    So I then tried to compile again using the following command, but the problem is still occurred:
    export LD_LIBRARY_PATH=/u0/oracle/prodora/8.0.6/lib
    export forms_path=/u0/oracle/prodappl/ar/11.5.0/forms/US/
    f60gen module=/u0/oracle/prodappl/ar/11.5.0/forms/US/TESTFORM.fmb USERID=apps/passwordMy question is how to successfully compile this form?
    Any input would be helpful. Thank you

    Jimmy;
    Are you using a WebLogic server?
    If yes, you should use the Forms Compiler frmcmp.sh
    #!/bin/sh
    for file in *.fmb
    do
    frmcmp_batch.sh module=$file userid=<your connect string> compile_all=yes
    done
    Tested on WebLogic and working, your paths will be different
    #!/bin/sh
    export ORACLE_HOME=/u01/app/oracle/product/fmw/oracle_pfrd
    export FORMS_PATH=/u01/app/oracle/product/fmw/fr_inst
    export PATH=$PATH:$ORACLE_HOME/bin:$FORMS_PATH/bin
    export TERM=vt220
    export ORACLE_TERM=vt220
    export TNS_ADMIN=/u01/app/oracle/product/fmw/oracle_pfrd/network/admin
    for file in *.fmb
    do
    frmcmp_batch.sh module=$file userid=scott/tigersy@dev2 compile_all=yes
    done
    Edited by: mseberg on Mar 2, 2011 8:57 AM
    script run from directory .fmb's are in
    Should also work on iAS
    Thanks!!
    Edited by: mseberg on Mar 8, 2011 5:22 AM

  • How do you compile shared dynamic library in OS/X?

    I am trying to compile a open source component in OS/X (gcc, ANSI C) from the following makefile:
    include makefile_header #standard system makefile variables in this
    # include additional makefile headers here
    # add needed cflags here
    DSI_CFLAGS=$(GLOBUS_CFLAGS)
    # add needed includes here
    DSI_INCLUDES=$(GLOBUS_INCLUDES) -I/opt/bes/include/bes
    # added needed ldflags here
    DSI_LDFLAGS=$(GLOBUS_LDFLAGS) -L/opt/bes/lib -L/opt/bes/lib/bes
    # add needed libraries here
    DSI_LIBS= -lbes_ppt -lbes_dispatch
    FLAVOR=gcc32dbg
    globus_gridftp_server_bes.o:
    $(GLOBUS_CC) $(DSI_CFLAGS) $(DSI_INCLUDES) \
    -shared -o libglobus_gridftp_server_bes_$(FLAVOR).so \
    globus_gridftp_server_bes.c \
    $(DSI_LDFLAGS) $(DSI_LIBS)
    install:
    cp -f libglobus_gridftp_server_bes_$(FLAVOR).so $(GLOBUS_LOCATION)/lib
    #end makefile
    -shared is not recognized by OS/X's gcc variant. Substituting -dynamiclib or -bundle does not seem to be correct method (errors). How should I go about changing the compile command so that it will build me the libglobus_server_bes_gcc32.so lib file?
    Thanks.
    --Stephan
    Macbook Pro, Powerbook G4   Mac OS X (10.4.9)   *NIX OSS developer

    I get the following compile message:
    /usr/bin/gcc -g -m32 -fno-common -Wall -I/usr/local/globus/include/gcc32dbg -I/opt/bes/include/bes \
    -o libglobusgridftp_server_besgcc32dbg.so \
    globusgridftp_serverbes.c \
    -L/usr/local/globus/lib -L/usr/local/globus//lib -m32 -L/opt/bes/lib -L/opt/bes/lib/bes -lbes_ppt -lbes_dispatch
    In file included from /usr/local/globus/include/gcc32dbg/globus_common.h:58,
    from /usr/local/globus/include/gcc32dbg/globusgridftpserver.h:26,
    from globusgridftp_serverbes.c:12:
    /usr/local/globus/include/gcc32dbg/globuscommoninclude.h:28: error: syntax error before 'extern'
    make: * [globusgridftp_serverbes.o] Error 1
    The compile command with -shared works in linux, no error in globuscommoninclude.h as above.
    globuscommoninclude.h upto the error:
    #if !defined(GLOBUSCOMMON_INCLUDEH)
    #define GLOBUSCOMMON_INCLUDEH 1
    #include "globus_config.h"
    #ifdef _GNUC_
    #define GlobusFuncName(func) static const char * globus_funcname \
    _attribute__((__unused_)) = #func
    #else
    #define GlobusFuncName(func) static const char * globus_funcname = #func
    #endif
    extern const char * globus_funcname; //<- error on this line
    <br>
    Macbook Pro, Powerbook G4   Mac OS X (10.4.9)   *NIX OSS developer

  • How do you compile "type body" objects that are invalid?

    We just completed a few application upgrades and now the objects catindexmethods and textindexmethods are invalid. These are part of our intermedia install but haven't started using it yet. How to I recompile these objects to be valid again?

    Did a little deeper and you shall find it:
    alter type xxx compile body;

  • How do you compile a lifecycle module

    I want to develop a Lifecycle module for Sun Java System Application Server 8, Platform Edition.
    I have read through http://docs.sun.com/source/817-6087/dglfcycl.html#wp16956 .
    The bit of info that is missing from this document is the name of the jar that holds the Lifecycle* classes l(like LifecycleListener).
    This makes it a bit difficult to compile my lifecycle module.

    Where did you find that information?
    Is it in a document that I missed?
    thanks,
    vbk

  • How do run the jni in linux enviroment??

    I run the HelloWorld sample in linux
    but I stock in load the share library!
    When I type this command as following:
    cc -G -I/usr/local/java/include -I/usr/local/java/include/linux \
    HelloWorldImp.c -o libhello.so
    there are error message like this :
    unrecognized option '-G'
    /usr/lib/gcc-lib/i386-redhat-linux/2.96/../../../crt1.o:In function '_start':
    /usr/lib/gcc-lib/i386-redhat-linux/2.96/../../../crt1.o(.text+0x18):
    undefined reference to 'main'
    can you help me solve the problem?

    gcc -I/usr/lib/java-1.3/include -I/usr/lib/java-1.3/include/linux \
         -fPIC -g -c -Wall HelloWorldImp.c
    gcc -shared -Wl,-soname,libhello.so -o libhello.so HelloWorldImp.o
    when you call the library in java
    System.loadLibrary("hello");

  • How do you compile just the drm radeon module?

    for background on my problem
    http://bbs.archlinux.org/viewtopic.php?id=76995
    I was wondering if anyone knew of a good guide to just compiling drm.ko and radeon.ko modules. i've looked around and cant seem to find any.

    You have to re-compile the (2.6.30 or later) kernel to do so.
    Last edited by Wintervenom (2009-07-31 17:18:30)

  • How do you compile a subclass?

    Can anyone help in answering the following question regarding inheritance?
    I have two classes one extending the other. When I put both classes into a single file and run the javac command to compile them the compilation takes place and no errors are given.
    However if I place the classes into seperate files and compile the superclass first and then the subclass. The superclass compiles but the subclass compilation fails with a cannot recognise symbol (superclass name) error.
    I have a workaround which is to compile both classes at the same time using javac *.java. However would like to know the reasons why the compilation fails and if there is a correct way to resolve this problem.
    As extra info the class files are sitting within the same directory on my machine.
    Any help greatly appreciated

    It might not be the classpath. If running javac
    *.java works, that means that both directories
    containing the files can 'see' each other. I don't
    think it would have worked at all if your classpath
    wasn't set correctly.That's wrong.
    If you run javac *.java, then you have made each .java
    file in the current directory explicitely available to
    the compiler.
    There is no such thing as directories being able to
    'see' each other - it is the compiler that needs to be
    able to 'see' the files and directories that your
    files are in.
    The compiler can 'see' the files whose names you pass
    in on the command line, and the directories and files
    that are in your classpath. If your classpath does not
    contain the directory that the superclass .class file
    is in (whether or not it is the current directory),
    then the compiler will give the posted error.Have updated the classpath and things are now working as I'd expected. Thanks for your help and good background info.

  • How do you compile for flash player 11.3 in Flash Professional CS6?

    I can add a new AIR SDK and compile for AIR 3.3, but I can't figure out how to compile for Flash Player 11.3. 
    Thanks

    You'll have a much better chance of getting a prompt answer in the Flash Professional forum:
    Flash Professional
    This forum is for Adobe Creative Cloud issues.

  • PLEASE HELP!!  HOW DO YOU COMPILE THE HELLO PROGRAM?

    Hi everybody,
    I just install j2sdk1.4.1_01 on my RH 8. And it's install under the directory /usr/j2sdk1.4.1_01 Now, I was compiling the hello program under /home/JAVATEST
    and it gives me the following error
    Exception in thread "main" java.lang.NoClassDefFoundError: hello
    Could anyone please help me on how to solve this problem. I have try to setup CLASSPATH under .bash_profile as this:
    JAVA_HOME=/usr/j2sdk1.4.1_01
    export JAVA_HOME
    CLASSPATH=./:$JAVA_HOME/lib
    export CLASSPATH
    and still. It would still give me the error. Would anybody please help me on it?? Thanks. I need to do my homework soon. ^<^ thanks

    I think it's your program.
    it's I believe like this isn't it?
    // Put this in a file called hello.java
    public class hello
        public static void main(String args[])
            System.out.println("Hello world!");
        }Try compiling this with the following command : @home>javac hello.java
    then run the command with : @home>java hello
    It should run just like that

  • How do you reinstall firefox on Linux without any internet browser? My boyfriend just did this and I'm trying to help him get it back.

    Firefox was playing up so he deleted it with the idea of re-installing it and obviously didn't think ahead. Now he has no internet browser, so he has no way of re-installing firefox. Does anyone have any suggestions?

    Download installer for Linux first from connected pc
    * getfirefox.com
    copy it to offline pc via any flash drive, or cd or other storage device, then install
    <br>
    See:
    * https://support.mozilla.com/en-US/kb/Installing%20Firefox%20on%20Linux

Maybe you are looking for