How to Compile DLL?

Dear friend,
I tried very hard (couple of days) to create a dll file, which contains 2 C++ file and 2 header file and 2 external thirty-party libraries (*.lib).
When I used the following command to generate *.dll file, some errors happened.
[COMMAND]
cl -Ic:\jdk1.3\include -Id:\jdk1.3\include\win32 -Id:\project\include -Gz -LD main.c exception.c book.lib order.lib /Femain.dll
[After execute the command, the ERRORs]
Creating library main.lib and object main.exp
main.obj : error LNK2001: unresolved external symbol _getFileType@0
A bunch of error LNK2001.
Any one has some experience and can give me a hand?
Very Appreciated in advance!!!

Those are link errors; the linker is apparently not finding getFileType and some other routines.
You haven't provided much to go on. I suggest you look in the C++ errors description, where LNK2001 is described, along with possible causes.

Similar Messages

  • How to use .dll compiled in Delphi in Java?

    Can anyone provide me information how to use .dll compiled in Delphi in Java? The .dll Delphi program may be non-OOP program.

    Hi
    If You want to write anything in PASCAL then simply write JNI code in C++ and call functions from this DELPHI DLL, but remember about changing the order of parameters etc when You call it. I had exactly the same problem, but it is possible, and we succeed.
    You will need exact description of input parameters required by PASCAL functions and of output parameters. Then construct in C++ objects wchich looks in memory exacly the same as they will look if You will be using PASCAL. Then PASCAL function will interprete this area in memory as known structure and will run.
    Maciek

  • How to use matlab compiled DLL in Labview ?

    I have LV 8.5, and am unable to use a matlab compiled DLL in my LV code. I have tried the 'import'  command, but it does not list any functions. However, it does not show any errors during its execution. The existing solutions/responses to this question do not work either. I would also like to know of a way to deal with mxArray datatype. What is its equivalent in C (or any other high-level language) ? How do I retrieve an array that is returned from the matlab dll ?

    I'm assuming you have either Matlab installed or at the very least the Matlab Runtime, otherwise the DLL won't work. The "import" command relies on having a header file. Do you have one? You also need to make sure the DLL has been compiled so that it's compatible with LabVIEW. The most likely problem is name mangling, which also occurs when you try to compile a DLL written in C++. See this post, which contains links to useful posts.
    The mxArray datatype is a special datatype which is actually a structure. It's complicated. Your best bet is to create a C DLL that acts as an intermediary between the Matlab DLL and LabVIEW. If you are able to, you can, instead, simply call the Matlab code directly using the Matlab script node.

  • How to use dll in Labview ?

    I compile this code to dll file with VC++2010 filename is test_dll.dll .
    #include "stdafx.h"
    #include <iostream>
    #include <Windows.h>
    using namespace std;
    int main(int a){
        cout << "Test dll...............\n";
        return a;
    After that, I put Call Library Function node in editor and double click Call Library Function node. I browse test_dll.dll into Library name or path and set function prototype to int32_t main(int32_t a); but it show error Call Library Function Node 'test_dll.dll:main':function not found in libraly. How to use dll in Labview ?  And I have more question is what is differrent from Tools -> Import -> Shared Library(.dll) and use Call Library Function node.
    Solved!
    Go to Solution.

    The issue you are having is that LabVIEW is not capable of using C++ DLLs directly. It only handles C DLLs. This does not mean that if you you cannot use the DLL if it's compiled with the C++ compiler as opposed to the C compiler. Rather, it means that you must take extra steps in order to use it from LabVIEW. The primary issue is that of name mangling or adornment. This is discussed here: http://zone.ni.com/devzone/cda/tut/p/id/4877. Basically you need to prepend extern "C" in front of your prototypes in your header files. I would also suggest reviewing this article: https://decibel.ni.com/content/docs/DOC-14564.

  • How to add dll library to application?

    I start programmed the CVI a few weeks ago and I have a little problem. I must make an application layer for profibus master device. However I total do not know how to add dynamic library to program, because in another way I get the error: undefined symbol. I know that it very trivial, but I cannot find solution. I have a lib file and also I include file about device, but I still get the error – undefined symbol – can you help me?
    Thanks very much for any advice or help

    Dear laszku,
    Are you looking for solutions to connect your CVI application with PLC? Because there are also solutions for that which are easy to use, and to implement with CVI.
    If you want to use your DLLs, there are some on-line help, how to import them in CVI.
    Basicaly there are two different method to import DLLs:
    - static import, when you import the library in your CVI project. The dll will be loaded when the exe starts running. If there is an issue to load the library, you'll be able to get the error at compilation time.
    - dynamic dll import, when you load the library at run-time. With this, you get the flexibility to control, when will be the dll linked to your exe in the memory, while running. The disadvantage is, you'll get errors only at run-time.
    I recommend you some of our on-line tutorial, how to load DLL into your application in CVI:
    CVI Help: Loading Dlls - This says: You cannot import DLLs directly into your project. You need to create DLL Import Library, which can be imported into your project.
    To do so, look at this knowledge base: Creating Import Libraries for a DLL in LabWindows/CVI
    You might get answers for your following questions at this FAQ page:
    FAQ: Using Dynamic Link Libraries with LabWindows/CVI
    Some help sites:
    Rules for Using DLL Files
    Linking to Functions Defined in a DLL From LabWindows/CVI
    If you need dynamic linkink, you can get example code with this site:
    How Can I Access DLL Functions in a LabWindows/CVI Program Without Including the Import Library in t...
    I hope, I could help you to find the way how to import DLL libraries.
    If you still couldn't solve the error after studying the links, please provide me more information, where, which symbol is missing, and also the full error message.
    The error you get, can be caused by the linker or pre-compiler also, which doesn't find the symbol you requested. Please check the path of your library and dll also.
    Best Regards,
    Tamas Szekely
    Applications Engineer
    National Instruments

  • How to add dll file in plugin

    Hi everybody,
    I have a short question concerning the plug-in.
    I created a plug-in  using visual studio 2005 for Adobe effect cs4
    but i want to add dll on that plugin so,how to add dll in that plugin
    please help me!!!!
    Thanks

    Any other dependencies apart from C/C++ runtime, for example cuda
    runtime which you cannot link against statically - you have to copy it
    into After Effect support files, where the executable lives (or in
    windows library directory, but that i would rather not do)!
    Am 19.06.2011 16:15, schrieb shachar carmi:
    to include external dependencies in the plug-in, go to:
    Project Properties -->  C/C++ -->  Code Generation
    and change the "Runtime Library" to "/MT"
    this should make the compiler include the needed code from other DLLs in your code.

  • How to compile only prism-es2 native on windows...

    Hi,
    I only desire to compile the JavaFX prism-es2 native for windows.
    (Because the prism-es2.dll is not included in JDK 8).
    The information I have from OpenJFX is:
    https://wiki.openjdk.java.net/display/OpenJFX/Building+OpenJFX
    (Not very usefull).
    https://wiki.openjdk.java.net/display/Nashorn/Building+Nashorn
    http://hg.openjdk.java.net/jdk8/build/raw-file/tip/README-builds.html
    I do not wish to recompile the JDK 8 in totality !!!!!!
    Only the part Prism-es2 native... How I can do that ???
    I had taken the source code from:
    http://hg.openjdk.java.net/openjfx/8/master/rt
    Thank you ....

    -How to compile OpenJFX ?
    I try several ways (JDK1.6, JDK1.7, ...) to compile and all time,
    I receive a lot of errors.
    (Missing com.sun.javafx.font,
      I do not found these packages: com.sun.javafx.font and com.sun.javafx.text.
          (possibly auto-generated)
    And the use of ant with: -Dbuild.compiler=javac1.7 change absolutely nothing...
    =>This is how finally I compile sucessfully. (After one week of different tests !!!)
    +First, I follow the instructions of:
      https://wikis.oracle.com/display/OpenJDK/Building+OpenJFX
      http://hg.openjdk.java.net/jdk7/build/raw-file/tip/README-builds.html#windows
    Take the source code:
      http://hg.openjdk.java.net/openjfx/8/master
      http://hg.openjdk.java.net/openjfx/8/master/rt
      http://hg.openjdk.java.net/openjfx/8/master/tests
    +From OpenJDK)
    -Basic Windows Check List:    (I follow all the instructions).
    1. Install the CYGWIN product.                          <--Done (The 64 bits version)
    2. Install the Bootstrap JDK, set ALT_BOOTDIR.          <--Done (JDK 1.8)
    3. Optional Import JDK, set ALT_JDK_IMPORT_PATH.    <--Not done(Not necessary for us)
    4. Install the Microsoft Visual Studio Compilers).  <--Done
       Visual Studio 2010 Express (Visual C++/C) installed.
       Windows SDK 7.1 installed (To build 64 bits). ==>WindowsSdkDir added.
       VS100COMNTOOLS is defined.
    5. Setup all environment variables for compilers (see compilers).   <--Done (64 bits)
        ...\Common7\Tools\vsvars32.bat not used because
            ...\VC\bin\amd64\vcvars64.bat is used for 64 bits.
       We set all manually for us)
        set CYGWIN=C:\ProgramFiles\cygwin64\bin
        set VSINSTALLDIR=C:\ProgramFiles(x86)\Microsoft_Visual_Studio10.0
        set WindowsSdkDir=C:\ProgramFiles\Microsoft_SDKs\Windows\v7.1
        set PATH=%VSINSTALLDIR%\vc\bin\amd64;%VSINSTALLDIR%\Common7\IDE;%WindowsSdkDir%\bin;%CYGWIN%;%PATH%
        set INCLUDE=%VSINSTALLDIR%\vc\include;%WindowsSdkDir%\include
        set LIB=%VSINSTALLDIR%\vc\lib\amd64;%WindowsSdkDir%\lib\x64
    6. Install Microsoft DirectX SDK.                         <--Done. (June 2010 version)
       (From: http://www.microsoft.com/en-ca/download/details.aspx?id=6812)
       set DXSDK_DIR=C:\ProgramFiles(x86)\MicrosoftDirectX_SDK(June2010)
       set INCLUDE=%INCLUDE%;%DXSDK_DIR%\Include;
       set LIB=%LIB%;%DXSDK_DIR%\Lib\x64;
    7. Install Ant 1.7.1 or newer, make sure it is in your PATH and set ANT_HOME. <--Done.
       (The version 1.9.1)
    And also)
      -So it's important that the Visual Studio paths in PATH preceed the CYGWIN path /usr/bin.
          (due to link.exe)        <--Done
      -And for the: MSVCR100.DLL   <--Done
       set ALT_MSVCRNN_DLL_PATH=%VSINSTALLDIR%\Common7\Packages\Debugger\X64 (This is the only place found)
       set LIB=%LIB%;%ALT_MSVCRNN_DLL_PATH%;
    +From OpenJFX)
    I follow all the instructions...
    But for antlr, I use the version from: http://www.antlr3.org/download/
    -Change inside build-src\genVSproperties.bat
    to include my zzz_batch1\c_settings1.bat
    c_settings1.bat)
    REM ------------------------------------------------------------------------
    REM PATCH ZZZ....Visual Studio 2010...
    Rem Must be called by master\build-src\genVSproperties.bat
    REM Result is inside vs.properties
    REM No .NET\Framework...
    REM These lines will be installation-dependent.
    set CYGWIN=C:\ProgramFiles\cygwin64\bin
    set VSINSTALLDIR=C:\ProgramFiles(x86)\Microsoft_Visual_Studio10.0
    set WindowsSdkDir=C:\ProgramFiles\Microsoft_SDKs\Windows\v7.1
    set DXSDK=C:\ProgramFiles(x86)\MicrosoftDirectX_SDK(June2010)
    set ALT_MSVCRNN_DLL_PATH=%VSINSTALLDIR%\Common7\Packages\Debugger\X64
    REM The following should be largely installation-independent.
    set VCINSTALLDIR=%VSINSTALLDIR%\VC
    REM
    set INCLUDE=%VCINSTALLDIR%\include;%WindowsSdkDir%\include;%DXSDK%\Include;%INCLUDE%
    set LIB=%VCINSTALLDIR%\lib\amd64;%WindowsSdkDir%\lib\x64;%DXSDK%\Lib\x64;%ALT_MSVCRNN_DLL_PATH%;%LIB%
    set LIBPATH=%VCINSTALLDIR%\lib;%LIBPATH%
    REM
    set DEVENVDIR=%VSINSTALLDIR%\Common7\IDE
    set DEVENVCMD=%DEVENVDIR%\VCExpress.exe
    REM
    set PATH=%VCINSTALLDIR%\bin\amd64;%VSINSTALLDIR%\Common7\IDE;%WindowsSdkDir%\bin;%CYGWIN%;%PATH%
    REM echo "%DEVENVDIR%" %DEVENVDIR%
    REM ------------------------------------------------------------------------
    genVSproperties.bat)
    if not exist "%DEVENVCMD%" set DEVENVCMD=%DEVENVDIR%\VCExpress.exe
    REM ZZZ Patch...
    call ..\zzz_batch1\c_settings1.bat
    REM Echo out a properties file
    Now I receive a lot of errors at the compilation:
    jar:
        [mkdir] Created dir: C:\zgroup1\userbase1\javafx1\open-jfx\master\rt\javafx-ui-quantum\build\classes
        [javac] Compiling 43 source files to C:\zgroup1\userbase1\javafx1\open-jfx\master\rt\javafx-ui-quantum\build\classes
        [javac] C:\zgroup1\userbase1\javafx1\open-jfx\master\rt\javafx-ui-quantum\src\com\sun\javafx\tk\quantum\SceneState.java:49: error: constructor PresentableState in class PresentableState cannot be applied to given types;
        [javac]         super();
        [javac]         ^
        [javac]   required: View
    etc ...
    After search, I found that the compilation process, use the file:
       C:\ProgramFiles\Java\jdk1.8.0\jre\lib\ext\jfxrt.jar
       I rename it: jfxrt.jarXXX
       (I don't know how this jar is included after some searchs).
       After the C:\zgroup1\userbase1\javafx1\open-jfx\master\artifacts\sdk\rt\lib\ext\jfxrt.jar
       causes the same errors. I create an empty jar named jfxrt.jar.
       Now I can recompile all, (After a clean)
       I clean all, I recompile but I have the another errors.
    I change the rt\build.xml:
           <condition property="include.ogl">
              <istrue value="${isWindows}"/>
            </condition>
         <!--
            Build targets...
          -->
        <target name="jar" depends="init">
            <ant antfile="${rt.root.dir}/javafx-accessible/build.xml" target="jar" inheritAll="false"/>
            <ant antfile="${rt.root.dir}/javafx-common/build.xml" target="jar" inheritAll="false"/>
            <ant antfile="${rt.root.dir}/javafx-logging/build.xml" target="jar" inheritAll="false"/>
            <ant antfile="${rt.root.dir}/glass/build.xml" target="jar" inheritAll="false"/>
            <ant antfile="${rt.root.dir}/javafx-beans/build.xml" target="jar" inheritAll="false"/>
            <ant antfile="${rt.root.dir}/javafx-util-converter/build.xml" target="jar" inheritAll="false"/>
            <ant antfile="${rt.root.dir}/javafx-anim/build.xml" target="jar" inheritAll="false"/>
            <ant antfile="${rt.root.dir}/javafx-geom/build.xml" target="jar" inheritAll="false"/>
            <ant antfile="${rt.root.dir}/pisces/build.xml" target="jar" inheritAll="false"/>
            <ant antfile="${rt.root.dir}/decora-compiler/build.xml" target="jar" inheritAll="false"/>
            <ant antfile="${rt.root.dir}/decora-runtime/build.xml" target="jar" inheritAll="false"/>
            <ant antfile="${rt.root.dir}/javafx-sg-common/build.xml" target="jar" inheritAll="false"/>
            <ant antfile="${rt.root.dir}/javafx-ui-common/build.xml" target="jar" inheritAll="false"/>
            <ant antfile="${rt.root.dir}/javafx-concurrent/build.xml" target="jar" inheritAll="false"/>
            <ant antfile="${rt.root.dir}/prism-util/build.xml" target="jar" inheritAll="false"/>
            <ant antfile="${rt.root.dir}/prism-common/build.xml" target="jar" inheritAll="false"/>
            <ant antfile="${rt.root.dir}/javafx-ui-quantum/build.xml" target="jar" inheritAll="false"/>
            <ant antfile="${rt.root.dir}/javafx-sg-prism/build.xml" target="jar" inheritAll="false"/>
            <ant antfile="${rt.root.dir}/javafx-embed-swing/build.xml" target="jar" inheritAll="false"/>
            <ant antfile="${rt.root.dir}/javafx-ui-controls/build.xml" target="jar" inheritAll="false"/>
            <ant antfile="${rt.root.dir}/javafx-ui-charts/build.xml" target="jar" inheritAll="false"/>
            <ant antfile="${rt.root.dir}/decora-prism/build.xml" target="jar" inheritAll="false"/>
            <antcall target="jar-decora-d3d"/>
            <antcall target="jar-decora-es2"/>
            <ant antfile="${rt.root.dir}/decora-jsw/build.xml" target="jar" inheritAll="false"/>
            <ant antfile="${rt.root.dir}/decora-prism-sw/build.xml" target="jar" inheritAll="false"/>
            <ant antfile="${rt.root.dir}/decora-prism-ps/build.xml" target="jar" inheritAll="false"/>
            <antcall target="jar-decora-sse"/>
            <ant antfile="${rt.root.dir}/prism-util/build.xml" target="jar" inheritAll="false"/>
            <ant antfile="${rt.root.dir}/prism-common/build.xml" target="jar" inheritAll="false"/>
            <ant antfile="${rt.root.dir}/prism-j2d/build.xml" target="jar" inheritAll="false"/>
            <ant antfile="${rt.root.dir}/prism-ps/build.xml" target="jar" inheritAll="false"/>
            <ant antfile="${rt.root.dir}/prism-null/build.xml" target="jar" inheritAll="false"/>
            <antcall target="jar-prism-sw"/>
            <antcall target="jar-prism-d3d"/>
            <antcall target="jar-prism-es2-all"/>
            <ant antfile="${rt.root.dir}/javafx-beans-dt/build.xml" target="jar" inheritAll="false"/>
            <ant antfile="${rt.root.dir}/javafx-fxml/build.xml" target="jar" inheritAll="false"/>
            <antcall target="jar-javafx-android"/>
            <antcall target="jar-javafx-embed-swt"/>
            <ant antfile="${rt.root.dir}/javafx-builders/build.xml" target="jar" inheritAll="false"/>
        </target>
    I recompile and now:
    jar:
        [mkdir] Created dir: C:\zgroup1\userbase1\javafx1\open-jfx\master\rt\javafx-ui-common\build\classes
        [javac] Compiling 471 source files to C:\zgroup1\userbase1\javafx1\open-jfx\master\rt\javafx-ui-common\build\classes
        [javac] C:\zgroup1\userbase1\javafx1\open-jfx\master\rt\javafx-ui-common\src\com\sun\webkit\dom\JSObject.java:30: error: cannot find symbol
        [javac] import netscape.javascript.JSException;
        [javac]                           ^
        [javac]   symbol:   class JSException
    --->Compile webview (and webview needs another packages, circular problems)...
    Recompile all is not really possible due to intersecting packages...
    I change rt\glass\glass\build.xml because missing)
        <property name="jfx.accessible.dir" value="${rt.dist.root.dir}/javafx-accessible"/>
        <property name="jfx.accessible.jar" value="${jfx.accessible.dir}/dist/javafx-accessible.jar"/>
    Now I recompile, I have errors but now I understand something.
    When master\artifacts\sdk\rt\lib\ext\jfxrt.jar is the empty version, I compile at a certain point.
    I copy the C:\ProgramFiles\Java\jdk1.8.0\jre\lib\ext\jfxrt.jar to master\artifacts\sdk\rt\lib\ext
    and I able to go to another point. When errors, I take the empty version and alternatively I pass
    from the empty to full version.
    Finally I compile all and:
    dist:
         [echo] Creating merged openjfxrt.jar file
        [mkdir] Created dir: C:\zgroup1\userbase1\javafx1\open-jfx\master\rt\dist\lib
          [jar] Building jar: C:\zgroup1\userbase1\javafx1\open-jfx\master\rt\dist\lib\openjfxrt.jar
         [echo] Copying binaries
        [mkdir] Created dir: C:\zgroup1\userbase1\javafx1\open-jfx\master\rt\dist\bin
         [copy] Copying 1 file to C:\zgroup1\userbase1\javafx1\open-jfx\master\rt\dist\bin
    BUILD SUCCESSFUL
    I have my ES2 (Decora,Prism) part compiled with prism-es2.dll inside prism-es2-native.jar
    Now I will test all !!!

  • Triggered DAQ from a LabVIEW-compiled DLL

    Bit of an obsure one here:
    I have a DAQmx task on a NI PXI-6052E device that is started by an external hardware trigger (a rising edge on PFI0).  The task commands the acquisition of 200 or so samples at around 3 kS/s, after which it waits for the next rising edge trigger.
    This works fine when run from the LabVIEW IDE (2010) itself, and also when run from a compiled Windows executable.  But when run from a compiled DLL, it doesn't - it waits until the timeout expires and returns no data.  The trigger pulse is definitely still arriving at the card, so I can only assume that I am doing something wrong, or that it's a bug with LabVIEW.  (Googling and forum searching gets me nowhere, so I'm beginning to think I might be the first person in the world to try this )
    Switching out the real DAQ device for a simulated one in MAX makes it work, presumably because simulated devices don't do triggering anyway.  Removing the trigger and making it run freely also gets it to work, but the triggering is essential to my application.
    Any ideas?

    Hi Ian,
    I will help you find a solution for this issue you are encountering. Firstly, can I ask you for a few more details regarding your application.
    Can I check that you are compiling the VI through a build specification in your project explorer. Does this project contain any subVIs or does it just use the one standalone front end VI.
    Are you then trying to call this DLL function back into a LabVIEW development environment? or are you calling it into a different program, TestStand? Visual basics? If you are using a program other than LabVIEW can your try calling it from the LabVIEW Development Environment where you created it.
    Also, how are you calling the DLL. DLLs can be called statically and dynamically, the differences have be outlined in this KnowledgeBase article.
    Could you also refer to this KnowledgeBase which outlines the method for building a DLL in LabVIEW. Check to ensure you followed all the required steps. At the bottom of the article there are useful links which provide details on how to call DLLs.
    Sorry for asking so many questions but the answers to these will really help me understand your issue.
    Many Thanks,
    Aaron. E
    Applications Engineer Team Lead
    National Instruments
    ni.com/support

  • How to compile and register a Java CFX tag with multiple class files?

    All-
    If this is the wrong forum for CFX questions, please let me
    know.
    I need to determine how to compile and register a Java CFX
    tag that contains multiple class files. One class file implements
    the CustomTag interface and the other class files implement various
    supporting classes. All of the documentation that I have found
    talks about using a single class file. I am assuming that a JAR
    file will be involved, but I am not sure of the specifics.
    Thanks in advance for your help.
    -Josh

    Yes, it will involve a jar. Use your java IDE (eclipse,
    etcetera ..) to create a jar containing all of the classes. Check
    your ide's documentation for how to create jar files. After you
    have created the jar, place the jar in the CF class path so CF will
    recognize it. For example the {cf_root}/WEB-INF/lib directory. CF
    must be restarted before it will detect the new jar. After
    restarting CF, register the CFX tag in the ColdFusion Administrator
    using the name of the class that implements the CustomTag
    interface.
    Though it is worth noting you can also instantiate java
    classes directly from ColdFusion (ie without using a CFX
    tag).

  • How to compile Oracle Linux source?

    I accidentally downloaded source DVD "Oracle Linux Release 5 Update 2 source - DVD" instead of installable ISO image. Is there anyway I can compile it to make bootable ISO image?
    I tried to search this forum as well as other places but couldn't find any information hence thought of opening a thread before I proceed to download correct file which will again take 10+ hrs with my Internet speed :(
    Any help is highly appreciated. Also I need to know which packages are required to be installed for compiling the source if at all that is possible. I am using Ubuntu 11.10 Desktop.
    Thanks in advance for any help and hope to get a reply soon :) I need to urgently install Oracle 11gR2 on it.
    Edited by: user6582219 on Apr 12, 2012 1:10 AM
    While browsing the forum for any possible solution I came to a thread that discuss installation of a package oracle-rdbms-server-11gR2-preinstall. When searched through search engine I came to know about recent certification Oracle 11gR2 on Oracle Linux 6, here is the link https://blogs.oracle.com/linux/entry/announcing_oracle_database_11g_r2
    https://blogs.oracle.com/linux/entry/announcing_oracle_database_11g_r2
    Thing is I already have Oracle Linux 6 Update 2 (the latest) installed on my machine in dual boot mode so I dropped the idea of installing version 5.2. As per the documentation 11gR2 was not certified earlier on Linux 6.2 so I thought of installing 5.2 but it is not necessary now.
    I would still appreciate if someone could answer my question just for knowing the procedure compiling source. May be it can help someone else trying to achieve this.
    I have another couple of important questions and need guidance from the experts over here. I am not sure if it is appropriate to open a new thread but for now I am posting them here.
    Before proceeding here are my environment details:
    Machine: x86 32 bit with 2 GB RAM/250 GB HD.
    OS: Kubuntu 11.10 Desktop and Oracle Linux 6 Update 2 in dual boot mode.
    Here are my partition details for your reference but as I am planning to do the installation from the scratch following new ideal scheme you can jump to last paragraph following the line "*********************************" for my questions.
    Unfortunately my partition plan went wrong and here is what I have now:
    Disk /dev/sda: 250.1 GB, 250059350016 bytes
    255 heads, 63 sectors/track, 30401 cylinders, total 488397168 sectors
    Units = sectors of 1 * 512 = 512 bytes
    Sector size (logical/physical): 512 bytes / 512 bytes
    I/O size (minimum/optimal): 512 bytes / 512 bytes
    Disk identifier: 0x3d5ba9e1
    Device Boot Start End Blocks Id System
    /dev/sda1 * 2048 1002047 500000 83 Linux
    /dev/sda2 151525080 361253654 104864287+ 7 HPFS/NTFS/exFAT
    /dev/sda4 1003518 151001087 74998785 5 Extended
    /dev/sda5 1003520 7002111 2999296 82 Linux swap / Solaris
    /dev/sda6 7004160 11001855 1998848 83 Linux
    /dev/sda7 11003904 51001343 19998720 83 Linux
    /dev/sda8 51003392 110041087 29518848 83 Linux
    Partition table entries are not in disk order
    /dev/sda1 here is /tmp, /dev/sda2 is my data partition, I have separate /home / (root) partition for Kubuntu and remianing around 20 GB in extended partition is used for Oracle Linux 6.2 with default Oracle suggested LVM partition. I also have separate /boot for Kubuntu and I chose not to install grub while installing Oracle Linux. I later modified grub.cfg to add entries for Oracle Linux and now I can boot both OSs successfully.
    My issue now is I cannot extend 20 GB space (in extended partition) that I have given to Oracle though I have around 40 GB space available. This is because I alreay have 4 primary partitions (one for /boot others for "data" and one extended partition). So I have to make primary partition out of free space and install Oracle in a single partition without following recommended partition layout scheme.
    Now I want to do the installation of both the OS from the scratch and really need an advice on partition layout scheme. Here is summary of what I wan to achieve:
    1. Keep the "data" partition (primary) intact and carve an ideal partition layout for both the OS with separate /boot, /tmp, /home, swap (and may be for /usr???). Also may be I can share swap?
    2. How do I go about using LVM and is it recommended for this case? What would be ideal locations for each partitions and sizes? I already used 100 GB for "data" so now I want to keep 60 GB for Oracle Linux (and Oracle DB for which I will again make few sub-partitions) and remaining will be for Kubuntu.
    Well, I am not sure if this is the right place to ask these questions but since I can see very knowlegeable top contributors here that are willing to help novice users I thought of posting these questions.
    I would really really appreciate if someone can provide me rough draft of partition scheme in my case considering the sub-partitions needed for Oracle DB. I went thorugh number of forums and documentations to come up with solutuion and finally thought of getting help after much confusion.
    I really need to carefully plan this time because it's third time I am doing reinstallation from the scratch because of poor plan I followed previously.
    Thank you very much in advance and please let me know in case more information is needed from my side.
    Regards,
    Ramesh

    I accidentally downloaded source DVD "Oracle Linux Release 5 Update 2 source - DVD" instead of installable ISO image. Is there anyway I can compile it to make bootable ISO image?Google will be your best friend for such a question, for instance, "Creating a Custom centos Linux bootable ISO Image". There is no need to duplicate the effort. I recommend you download the correct installation DVD, e.g. 5.8
    Thing is I already have Oracle Linux 6 Update 2 (the latest) installed on my machine in dual boot mode so I dropped the idea of installing version 5.2. As per the documentation 11gR2 was not certified earlier on Linux 6.2 so I thought of installing 5.2 but it is not necessary now.So you don't need to install 5.2 anymore, but you want the information how to compile a installation DVD from the 5.2 source anyway?!
    I have another couple of important questions and need guidance from the experts over here. I am not sure if it is appropriate to open a new thread but for now I am posting them here.Questions may be important for you, but not necessarily for others. No one will complain if you create a new thread for particular questions or subjects. It is better to separate your topics and questions rather than creating a multi-mega thread, which does little to help anyone else but you. It means more work on your end, but it will be easier for anyone to participate or answer your questions, and it will allow you to better award answers.
    Regarding your partitioning questions: It is generally difficult to address such topics in a forum. You are asking for a book of information. My advice is to drop the old fashioned concepts of dual or triple boot options and install Oracle VirtualBox instead. It will make all of these questions obsolete and you can use whatever defaults when installing your virtual machine guest OS. Its a far more superior way of dealing with multiple operating systems on one and the same computer.
    I am using Ubuntu 11.10 Desktop.
    I need to urgently install Oracle 11gR2 on it.For what it's worth, if you can combine the two source below you should be able to install and run 11gR2 on Ubuntu 11.10.
    Install Oracle 11gR2 on Ubuntu Linux 11.04 (64-bit) Howto
    Install Oracle 11gR2 on Ubuntu Linux 11.04 (64-bit) Howto
    Oracle 11gR2 Express Edition on Linux Ubuntu 11.10 howto
    Oracle 11gR2 Express Edition on Linux Ubuntu 11.10 howto
    However, check out VirtualBox.

  • How to compile a single file in a project

    I have placed my java connector file called "xxxTargetconnector .class" in the below mentioned path
    D:\FSCM9DMO\webserv\FSCMDMO9\applications\peoplesoft\PSIGW\WEB-INF\classes\com\peoplesoft\pt\integrationgateway\targetconnector
    I have converted the above class file in to a java file using a decompiler.Now i would like to recompile the java file to get the byte code.This class file imports many class files from jar files which is placed in the below mentioned path.
    D:\FSCM9DMO\webserv\Cybersource.
    Before compiling i set the path to include the jar files
    for ex , set path = D:\FSCM9DMO\webserv\Cybersource
    For compilation i went to the below path using command prompt and compiled the particular file.
    D:\FSCM9DMO\webserv\FSCMDMO9\applications\peoplesoft\PSIGW\WEB-INF\classes\com\peoplesoft\pt\integrationgateway\targetconnector>javac xxxTargetConnector.java
    Unfortunately i got around 99 errors saying
    xxxTargetConnector.java:187: cannot find symbol
    symbol : variable Logger
    location: class com.peoplesoft.pt.integrationgateway.targetconnector.xxxTargetConnector
    How to compile a single file in a project ?

    According to [http://java.sun.com/javase/6/docs/technotes/tools/windows/javac.html], "As a special convenience, a class path element containing a basename of * is considered equivalent to specifying a list of all the files in the directory with the extension .jar or .JAR. I have never tried using this feature.
    So if all of your dependent classes are in in jar files that are in D:\FSCM9DMO\webserv\Cybersource, a command like the following should work.
    javac -cp D:\FSCM9DMO\webserv\Cybersource\* xxxTargetConnector.java
    Note that setting your operating system path variable has no impact on where Javac looks for dependent classes.

  • How to compile all forms in a directoy at time?

    Hi friends, thank for your replies for the previous questions.
    Now
    How to compile all form modules located in a directory
    at a time? usually what I know is opening form one by one
    and compile it. But I want to compile all forms and create
    executable files at a time.
    Is project Builder helpfule to achive this??
    thanks
    madhu

    Yes, his file is useful -- it should run on Windows XP. You need to copy the above text into a file using a standard text editor, something like Notepad. To run it, you open a Cmd.exe DOS window on your pc, change directory (CD) to the folder where your forms are, and enter the command script file name.
    Here are several more links to other topics in this forum asking how to do the same thing:
    Re: How To Compile 370 forms ?
    Re: Creating Oracle 10g Forms and Reports Builds

  • How to compile a java file which is in memory?

    how to compile a java file which is in memory?
    such as:
    String s="class MyClass {....}";
    how to compile the string?
    thx

    come on ...That was a perfectly valid solution.
    Do you know how to call the sun.* compiler? If not then search the forums for it. If that interface still exists (which it might not in newer versions) you then will create a string stream from your class and pass it to that.

  • Pls help me on how to compile servlet

    pls i need the help of some kind one to assist me on how to compile and deploy servlet .I'm new to javaEE & am using the javaEE tutorial from sun site.In the first example servlet in d book, after compiling and deploying the greetingServlet and responseServlet and deployed it ,i was told to include a welcome jsp file in d war file. all these i have done but the server always complain of not been able locate d greetingServlet.
    i use the netbeans IDE and sun java application server.The greetingServlet & responseServlet codes are these; Pls I don't know what to put in the jsp file
    package servlets;
    import java.io.*;
    import java.util.*;
    import java.sql.*;
    import javax.servlet.*;
    import javax.servlet.http.*;
    * This is a simple example of an HTTP Servlet.  It responds to the GET
    * method of the HTTP protocol.
    public class GreetingServlet extends HttpServlet {
        public void doGet(
            HttpServletRequest request,
            HttpServletResponse response) throws ServletException, IOException {
            response.setContentType("text/html");
            response.setBufferSize(8192);
            PrintWriter out = response.getWriter();
            // then write the data of the response
            out.println("<html>" + "<head><title>Hello</title></head>");
            // then write the data of the response
            out.println(
                    "<body  bgcolor=\"#ffffff\">"
                    + "<img src=\"duke.waving.gif\" alt=\"Duke waving\">"
                    + "<h2>Hello, my name is Duke. What's yours?</h2>"
                    + "<form method=\"get\">"
                    + "<input type=\"text\" name=\"username\" size=\"25\">"
                    + "<p></p>" + "<input type=\"submit\" value=\"Submit\">"
                    + "<input type=\"reset\" value=\"Reset\">" + "</form>");
            String username = request.getParameter("username");
            if ((username != null) && (username.length() > 0)) {
                RequestDispatcher dispatcher = getServletContext()
                                                   .getRequestDispatcher(
                            "/response");
                if (dispatcher != null) {
                    dispatcher.include(request, response);
            out.println("</body></html>");
            out.close();
        public String getServletInfo() {
            return "The Hello servlet says hello.";
    package servlets;
    import java.io.*;
    import java.util.*;
    import java.sql.*;
    import javax.servlet.*;
    import javax.servlet.http.*;
    * This is a simple example of an HTTP Servlet.  It responds to the GET
    * method of the HTTP protocol.
    public class ResponseServlet extends HttpServlet {
        public void doGet(
            HttpServletRequest request,
            HttpServletResponse response) throws ServletException, IOException {
            PrintWriter out = response.getWriter();
            // then write the data of the response
            String username = request.getParameter("username");
            if ((username != null) && (username.length() > 0)) {
                out.println("<h2>Hello, " + username + "!</h2>");
        public String getServletInfo() {
            return "The Response servlet says hello.";
    }

    Here is what you will need to do.
    1. Compile the servlets by performing the following steps
    1.1 Open a command line in the directory where your servlets are located.
    1.2 Type the following commands
    1.2.1 javac GreetingServlet.java
    1.2.2 javac ResponseServlet.java
    Then you should see the .class files for these classes appear in the directory .
    Next you will put these class files in the WEB-INF/classes directory.
    Once you have done that you will edit your web.xml in the WEB-INF directory to include the two servlets. That code will look something like this
    <?xml version="1.0" encoding="ISO-8859-1"?>
    <!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.2//EN"
    "http://java.sun.com/j2ee/dtds/web-app_2_2.dtd">
    <web-app>
         <servlet>
              <servlet-name>GreetingServlet</servlet-name>
              <servlet-class>GreetingServlet</servlet-class>
         </servlet>
         <servlet-mapping>
              <servlet-name>GreetingServlet</servlet-name>
              <url-pattern>/GreetingServlet</url-pattern>
         </servlet-mapping>
         <servlet>
              <servlet-name>ResponseServlet</servlet-name>
              <servlet-class>ResponseServlet</servlet-class>
         </servlet>
         <servlet-mapping>
              <servlet-name>ResponseServlet</servlet-name>
              <url-pattern>/ResponseServlet</url-pattern>
         </servlet-mapping>
    </web-app>Once you have done this save the web.xml file and recompile the war file by following these steps
    1 open a commandline in the root directory where the servlets are
    2 type the following command jar -cvf warFileName.war .
    *Note the space and period at the end of the command are not a mistake the space . tells the jar tool to complie the war from the directory you are current in.
    Once this command is successfully ran you should see a .war file appear in the directory you are in. Then simply put the war file in your deploy directory of your server and you are finished.
    alternatly if you are just doing this for yourself to learn servlets and this is not going to be deployed anywhere then I would just use the W3C's Jigsaw server which does all the work for you all you have to do is compile the servlets and put the class files in the servlets directory and you are done.

  • How to Compile & Deploy the Java Concurrent Program File

    Hi,
    There is a requirement to create the Java Concurrent Program in Oracle eBusiness. I am able to create the Java Concurrent Program file. But unable to do the following things:
    1.Since it is custom file, which location I will deploy the file?
    2. How to compile the file?
    3. In the execution file path and executable file name what should I specify for JCP?
    Please guide me.
    Thanks

    Please see (How to register and execute Java Concurrent Program ?in Oracle Applications R11i ? [ID 186301.1]) for the complete steps (i.e. define concurrent program and add it to the request group, .etc.) -- This is also applicable to R12.
    You may also see:
    Classpath Setting of Third Party Jar Files in R12 Java Concurrent Program (JCP) [ID 1292694.1]
    Integrating Custom Applications with Oracle Applications [ID 176852.1]
    Java Concurrent Program FAQ [ID 827575.1]
    https://forums.oracle.com/forums/search.jspa?threadID=&q=Java+AND+Concurrent+AND+Program&objID=c3&dateRange=all&userID=&numResults=15&rankBy=10001
    Thanks,
    Hussein

Maybe you are looking for