How to create an InterBase application from the Borland C++ IDE

By: Borland Staff

Abstract: Applies to Borland C++, Not C++ Builder
How to create an InterBase application from the Borland C++ IDE

Note:  This information applies to Borland C++, NOT C++ Builder

The information in this article applies to:
  * InterBase v4.x
  * InterBase v5.x
  * Borland C++ 5.x

To create an InterBase application with the Borland C++ IDE 
do the following:

    1) create a new project
       a) File | New | Project
       b) Target Type = Application(.exe)
       c) platform type = Win32
       d) Target Model = Console
       e) Unclick on all Frameworks (Class Library is selected by default)
       f) Make sure that Multithread is chosen
       g) set Advanced options 
          I) Initial Nodes = .c node
          II) unclick on .rc and .def files
       h) set project directory and name

    2) setting project compile/link options (Options | Project)
       a) InterBase applications must align to 4-byte boundaries
          - under 32-bit Compiler | Processor select Double word (4-byte) option for
            Data alignment

       b) You must include the InterBase include directory so your 
            project can find ibase.h
              - under Directories add your InterBase directory to Source 
                Directories: Include (Note: include directories must be 
                semicolon seperated)

       c) save your project options (Options | Save)

    3) add the gds32.lib file to your project
       a) In the Project file box right click on the target executable and 
           choose Add node
       b) change the file types to *.lib and select the gds32.lib file from 
            the lib directory under your InterBase directory (Note: make 
            sure not to select the gds32_ms.lib file which is for use 
            with the Microsoft compilers)

    4) Create the dependency between the .e and the .c file
       a) highlight the .c file and right click.  Select Add node and 
            choose your .e file

    5) Build your project
       a) You must gpre your application before compiling in 
            the Borland C++ IDE
          I) You can do this from a command line 
                      (Ex: gpre -z -e -m -n filename.e)
          II) You can integrate gpre into the IDE
              A) Bring up the available tools dialog (Options | tools)
              B) Create a new entry for gpre
              C) Name = name that will show up in tools dialog
              D) Path = path to gpre.exe 
              E) Command line = -e -m -n $EDNAME $CAP EDIT
              F) Advanced Options
                 1) Tool Type = Translator
                 2) Translator Details | Translate From = .e
                 3) Translator Details | Translate To = .c
                 4) Translator Details | Default for = .e

       b) Choose Project | Build all

Published on: 7/24/2000 12:00:00 AM

Server Response from: ETNASC04

Copyright© 1994 - 2013 Embarcadero Technologies, Inc. All rights reserved.