[vtkusers] Re: Re: Re: Building VTK with Kylix bc++
Stefan Bruckner
stefan.bruckner at chello.at
Tue Aug 27 17:55:42 EDT 2002
I have tried the -tD flag for building shared libraries and the -VC flag
for position independent code, but when I build I always get:
Borland C++ 5.7 Open Edition Copyright (c) 1987, 2002 Borland
/usr/src/packages/SOURCES/VTK/Utilities/tiff/mkg3states.c:
Warning W8065 /usr/src/packages/SOURCES/VTK/Utilities/tiff/mkg3states.c
383: Call to function 'getopt' with no prototype in function main
bc++ mkg3states.o -L/usr/src/packages/SOURCES/VTK/bin -lpthread -ldl
-lm -Wl,-rpath,/usr/src/packages/SOURCES/VTK/bin -o
/usr/src/packages/SOURCES/VTK/bin/mkg3states
Borland C++ 5.7 Open Edition Copyright (c) 1987, 2002 Borland
Error E2194: Could not find file
'/usr/src/packages/SOURCES/VTK/bin/mkg3states.cpp'
make[5]: *** [/usr/src/packages/SOURCES/VTK/bin/mkg3states] Fehler 1
make[4]: *** [default_target] Fehler 2
make[3]: *** [default_target_tiff] Fehler 2
make[2]: *** [default_target] Fehler 2
make[1]: *** [default_target_Utilities] Fehler 2
make: *** [default_target] Fehler 2
I have attached the bc++ command line options from the Kylix help.
Thanks for your help,
Stefan Bruckner
> Von: William A. Hoffman [mailto:billlist at nycap.rr.com]
> Gesendet: Dienstag, 27. August 2002 22:15
> An: Stefan Bruckner
> Betreff: Re: AW: [vtkusers] Building VTK with Kylix bc++
>
>
> Well, you could build static and not shared.
> If you want shared, you are going to have to figure out how
> to create a shared library with bc++. Then change those
> flags in your cmakecache. Do you have an example of how
> to build a shared library with bc++?
>
> -Bill
>
>
> At 10:17 PM 8/27/2002 +0200, you wrote:
>
>
> I have tried that, but the issue seems zu be a little more complicated.
> The Borland compiler doesn't understand many of the gcc options used to
> build the shared libraries. For some of these I wasn't able to find
> equivalents for the settings. I have tried some things but it always
> fails to build correctly ...
>
> These are the settings that seem particularly problematic:
>
> CMAKE_CXX_MODULE_BUILD_FLAGS -shared
>
> CMAKE_CXX_MODULE_LINK_FLAGS -rdynamic
>
> CMAKE_CXX_SHLIB_BUILD_FLAGS -shared
>
> CMAKE_CXX_SHLIB_CFLAGS -fPIC
>
> CMAKE_CXX_SHLIB_LINK_FLAGS -rdynamic
>
> CMAKE_CXX_SHLIB_RUNTIME_FLAG -Wl,-rpath,
> btw. it's called bc++, probably because of a naming conflict with
> Bruce's C Compiler (bcc) on a lot of Linux distros ...
>
> --
> Thanks,
> Stefan
>
>
>
> -----Ursprüngliche Nachricht-----
>
> Von: vtkusers-admin at public.kitware.com
> [mailto:vtkusers-admin at public.kitware.com] Im Auftrag von William A.
> Hoffman
>
> Gesendet: Dienstag, 27. August 2002 21:45
>
> An: Stefan Bruckner; vtkusers at public.kitware.com
>
> Betreff: Re: [vtkusers] Building VTK with Kylix bc++
>
>
>
> I would trying using this compiler like any other unix compiler:
>
>
>
> setenv CXX bcc
>
> setenv CC bcc
>
>
>
> (I am assuming the klyix compiler is called bcc from the command line,
>
> but it might have some other name.)
>
>
>
> Then run ccmake ../path/to/vtk.
>
>
>
> -Bill
>
>
>
>
>
> At 09:40 PM 8/27/2002 +0200, Stefan Bruckner wrote:
>
>
>
> Hi!
>
>
>
> I'm trying to compile VTK with the Kylix 3 bc++
> (http://www.borland.com/kylix)
>
> compiler, but I can't get it to work. Has anyone tried this yet and is
>
> willing to share his or her experience? (cmake settings would be very
> much
>
> appreciated)
>
>
>
> Also, cmake does support Borland C++ Builder in its Windows version.
> But these settings are
>
> not displayed unless you have C++ Builder installed (which I have not).
>
> Maybe someone can look at these settings and post them here. This might
> also
>
> give me some hints ...
>
>
>
> Thanks a lot!
>
>
>
> --
>
> Stefan Bruckner
>
-------------- next part --------------
The syntax for compiling on the command line is:
bc++ [option [option...]] filename [filename...]
Where:
Items enclosed in brackets are optional.
option refers to the compiler options listed below.
filename refers to the source-code files you want to compile.
Note that using an option followed by a hyphen such as -X- usually undoes whatever is set using -X. For example, -X means disable compiler autodependency output but -X- means the opposite: use compiler autodependency output. For options that have arguments, you can negate them using a hyphen before the argument, for example, -w-xxx.
To get help on the options, use the -h option. For options having multiple forms (indicated by xxx), type the option after the -h. For example, to display all of the alignment options:
bc++ -h -a
Note: If you receive "Message not found" instead of the description, you need to source kylixpath:
source <kylix3>/bin/kylixpath
The following table is an alphabetical listing of the C++ compiler options:
Option Description
@<filename>Read compiler options from the response file filename
+<filename>Use alternate compiler configuration file filename
-3 Generate 80386 protected-mode compatible instructions (Default)
-4 Generate 80386/80486 protected-mode compatible instructions
-5 Generate Pentium instructions
-6 Generate Pentium Pro instructions
-A Use ANSI keywords and extensions
-AK Use Kernighan and Ritchie keywords and extensions
-AT Use Borland C++ keywords and extensions (also -A-)
-AU Use UNIX V keywords and extensions
-a Default (-a8) data alignment; -a- is byte alignment (-a1)
-an Align data on "n" boundaries, where 1=byte, 2=word (2 bytes), 4=double word (4 bytes), 8=quad word (8 bytes), 16=paragraph (16 bytes) (Default: -a8)
-b Make enums always integer-sized (Default: -b makes enums integer size)
-b- Make enums byte-sized when possible
-C Turn nested comments on (Default: -C- turn nested comments off)
-c Compile to object file, do not link
-D<name> Define "name" as a null string
-D<name=string> Define "name" as "string"
-d Merge duplicate strings
-d- Do not merge duplicate strings (Default)
-e<filename> Specify target executable pathname. Preferred usage: -o<filename>, when -c is not used.
-ff Fast floating point (Default)
-fp Correct Pentium FDIV flaw
-gn Warnings: stop after n messages (Default = 255)
-G, -G- Optimize for size/speed; use -O1 and -O2 instead
-H Generate and use precompiled headers
-H- Do not generate or use precompiled headers (Default)
-h Request Help; -h - shows all help. You can also get specific help on an option:-h -opt
-H=<filename> Set the name of the file for precompiled headers
-H"xxx" Stop precompiling after header file xxx
-Hc Cache precompiled header (Must be used with -H or -H"xxx")
-He Enable precompiled headers with external type files (Default)
-Hh=xxx Stop precompiling after header file xxx
-Hs Enable smart cached precompiled headers (Default)
-Hu Use but do not generate precompiled headers
-I<path> Set the include file search path
-in Set maximum significant identifier length to n (Default = 250)
-Ja Expand all template members (including unused members)
-Jgd Generate definitions for all template instances and merge duplicates (Default)
-Jgx Generate external references for all template instances
-jn Stop batch compilation after n messages (Default = None)
-K Set default character type to unsigned (Default: -K- default character type signed)
-k Generate standard stack frames (Default)
-L<path> Set the library file search path
-lx Pass option x to linker
-l-x Disables option x for the linker
-M Create a linker map file
-m Generate makefile dependency information
-md Put dependency information in .d files, not in the object file
-mm Ignore system header files while generating dependency info
-mo Specify the output file for dependency information
-n<path> Set output directory for object files to path
-O Optimize jumps
-O1 Generate smallest possible code
-O2 Generate fastest possible code
-Ob Dead store elimination
-Oc Eliminate duplicate expressions within basic blocks and functions
-Od Disable all optimizations
-Oi Expand common intrinsic functions
-OS Pentium instruction scheduling
-O-S Disables instruction scheduling
-Og Optimize for speed; use -O2 instead
-Os Optimize for speed; use -O2 instead
-Ot Optimize for size; use -O1 instead
-Ov Enable loop induction variable and strength reduction
-Ox Optimize for speed; use -O2 instead
-o<filename> Set output file name to an executable file when -c is not in use, or to an object file when -c is in use
-P Perform C++ compile regardless of source extension
-P- Perform C++ compile depending on source file extension
-P<ext> Perform C++ compile, set default extension to <ext>
-p Use Pascal calling convention
-p- Use C calling convention
-pc Use C calling convention (Default: -pc, -p-)
-pr Use fastcall calling convention for passing parameters in registers
-ps Use stdcall calling convention
-Q Extended compiler error information (Default = OFF)
-q Suppress compiler identification banner (Default = OFF)
-R Include browser information in generated object files
-RT Enable runtime type information (Default)
-r Use register variables
-r- Disable the use of register variables
-rd Use register variables only when register keyword is employed
Compile to Windows-style assembly language (for informational purposes only)
-T- Remove all assembler options
-Tx Specify assembler option x
-t Target is a Linux application
-tC Target is a console application
-tCS Target is statically linked
-tD Target is a shared object file
-tP Target is a package
-U<name> Undefine any previous definitions of name
-u Generate underscores on symbol names (Default)
-V Use smart C++ virtual tables (Default)
-v Turn on source debugging
-V0 External C++ virtual tables
-V1 Public C++ virtual tables
-VA Generate all global functions in their own virtual/weak segment (Default)
-Va Support old-style class arguments
-Vc Support constructor displacements
-Vd Use old C++ for loop variable scoping rules
-Ve Zero-length empty base classes
-Vg Disable lexical digraph scanner
-vi Generate inline functions inline (Default)
-vi- Generate inline functions out of line
-Vl Use old-style Borland C++ structure layout (for compatibility with older Borland C++ compilers)
-Vmd Use the smallest possible representation for member pointers
-Vmm Support multiple inheritance for member pointers
-Vmp Honor declared precision of member pointers
-Vms Support single inheritance for member pointers
-Vmv Place no restrictions on where member pointers can point (Default)
-Vn Enable new operator names: and, or, and_eq, bitand, and so on
-Vo Set most compatibility flags; used with old code
-VP Generate PIC code (Grayed out for new applications and shared objects and On for packages)
-Vp Push 'this' first (like Pascal)
-Vr Reverse order for multi-character
-Vs Use old-style virdef generation
-Vt Put virtual table pointer at front of object layout
-vu Do not prefix underbars to exported symbol names
-Vv Use slow virtual base pointers
-Vw Emit native code instead of Unicode for multi-byte character
-Vx Zero-length empty class member functions
-w Display all warnings
-w! Returns nonzero from compiler on warnings
-wxxx Enable xxx warning message
-w-xxx Disable xxx warning message
-wmsg User-defined warnings
-X Disable compiler autodependency output (Default: -X- use compiler autodependency output)
-x Enable exception handling (Default)
-xd Enable destructor cleanup (Default)
-xf Enable fast exception prologs
-xp Enable exception location information
-xs Enable slow exception epilogs
-xv Hide special exception handling variables so variables of this name can be used.
-y Add debug line numbers
C++ message options (alphabetical listing)
Option Number (Alias) Warning message
-w-ali -w-8086 Incorrect use of #pragma alias "aliasName" = "substitutename" (Default ON)
-wamb -w8000 Ambiguous operators need parentheses (Default OFF)
-wamp -w8001 Superfluous & with function (Default OFF)
-w-asc -w-8002 Restarting compile using assembly (Default ON)
-wasm -w8003 Unknown assembler instruction (Default OFF)
-w-aus -w-8004 'identifier' is assigned a value that is never used (Default ON)
-wbbf -w8005 Bit fields must be signed or unsigned int (Default OFF)
-w-bei -w-8006 Initializing 'identifier' with 'identifier' (Default ON)
-w-big -w-8007 Hexadecimal value contains more than three digits (Default ON)
-w-ccc -w-8008 Condition is always true OR Condition is always false (Default ON)
-wcln -w8009 Constant is long (Default OFF)
-w-cod -w-8093 Incorrect use of #pragma codeseg (Default ON)
-w-com -w-8010 Continuation character \ found in // comment (Default ON)
-w-cpt -w-8011 Nonportable pointer comparison (Default ON)
-w-csu -w-8012 Comparing signed and unsigned values (Default ON)
-wdef -w8013 Possible use of 'identifier' before definition (Default OFF)
-w-dig -w-8014 Declaration ignored (Default ON)
-w-dpu -w-8015 Declare 'type' prior to use in prototype (Default ON)
-w-dsz -w-8016 Array size for 'delete' ignored (Default ON)
-w-dup -w-8017 Redefinition of 'macro' is not identical (Default ON)
-w-eas -w-8018 Assigning 'type' to 'enum' (Default ON)
-w-eff -w-8019 Code has no effect (Default ON)
-w-ext -w-8020 'identifier' is declared as both external and static (Default ON)
-w-hch -w-8021 Handler for 'type1' Hidden by Previous Handler for 'type2' (Default ON)
-w-hid -w-8022 'function1' hides virtual function 'function2' (Default ON)
-w-ias -w-8023 Array variable 'identifier' is near (Default ON)
-w-ibc -w-8024 Base class 'class1' is also a base class of 'class2' (Default ON)
-w-ifr -w-8085 Function 'function' redefined as non-inline (Default ON)
-w-ill -w-8025 Ill-formed pragma (Default ON)
-w-inl -w-8026 Functions containing certain constructs are not expanded inline (Default ON)
-w-inl -w-8027 Functions containing reserved words are not expanded inline (Default ON)
-w-lin -w-8028 Temporary used to initialize 'identifier' (Default ON)
-w-lvc -w-8029 Temporary used for parameter 'parameter' (Default ON)
-w-lvc -w-8030 Temporary used for parameter 'parameter' in call to 'function' (Default ON)
-w-lvc -w-8031 Temporary used for parameter number (Default ON)
-w-lvc -w-8032 Temporary used for parameter number in call to 'function' (Default ON)
-w-mcc -w-8098 Multi-character character constant
-w-mcs -w-8096 Incorrect use of #pragma code_seg (Default ON)
-w-mes -w-8095 Incorrect use of #pragma message (Default ON)
-w-mpc -w-8033 Conversion to 'type' fails for members of virtual base 'base' (Default ON)
-w-mpd -w-8034 Maximum precision used for member pointer type 'type' (Default ON)
-w-msg -w-8035 User-defined warnings (Default ON)
-wnak -w8036 Non-ANSI Keyword Used: 'keyword' (Default OFF)(Note: Use of this option is required for ANSI conformance)
-w-ncf -w-8037 Non-const function 'function' called for const object (Default ON)
-w-nci -w-8038 Constant member 'identifier' is not initialized (Default ON)
-w-ncl -w-8039 Constructor initializer list ignored (Default ON)
-w-nfd -w-8040 Function body ignored (Default ON)
-w-ngu -w-8041 Negating unsigned value (Default ON)
-w-nin -w-8042 Initializer for object 'identifier' ignored (Default ON)
-w-nma -w-8043 Macro definition ignored (Default ON)
-w-nmu -w-8044 #undef directive ignored (Default ON)
-wnod -w8045 No declaration for function 'function' (Default OFF)
-w-nop -w-8046 Pragma option pop with no matching option push (Default ON)
-w-npp -w-8083 Pragma pack pop with no matching pack push (Default ON)
-w-nsf -w-8047 Declaration of static function 'function(...)' ignored (Default ON)
-w-nst -w-8048 Use qualified name to access nested type 'type' (Default ON)
-w-ntd -w-8049 Use '> >' for nested templates instead of '>>' (Default ON)
-w-nto -w-8050 No type OBJ file present. Disabling external types option. (Default ON)
-w-nvf -w-8051 Non-volatile function 'function' called for volatile object (Default ON)
-w-obi -w-8052 Base initialization without a class name is now obsolete (Default ON)
-w-obs -w-8053 'identifier' is obsolete (Default ON)
-w-ofp -w-8054 Style of function definition is now obsolete (Default ON)
-w-onr -w-8097 Not all options can be restored at this time (Default ON)
-w-osh -w-8055 Possible overflow in shift operation (Default ON)
-w-ovf -w-8056 Integer arithmetic overflow (Default ON)
-w-par -w-8057 Parameter 'parameter' is never used (Default ON)
-w-pch -w-8058 Cannot create pre-compiled header: 'header' (Default ON)
-w-pck -w-8059 Structure packing size has changed (Default ON)
-w-psb -w-8099 Static 'main' is not treated as an entry point
-w-pcm -w-8094 Incorrect use of #pragma comment (Default ON)
-w-pia -w-8060 Possibly incorrect assignment (Default ON)
-wpin -w8061 Initialization is only partially bracketed (Default OFF)
-w-pow -w-8062 Previous options and warnings not restored (Default ON)
-w-prc -w-8084 Suggest parentheses to clarify precedence (Default OFF)
-w-pre -w-8063 Overloaded prefix operator 'operator' used as a postfix operator (Default ON)
-w-pro -w-8064 Call to function 'function' with no prototype (Default ON)
-w-pro -w-8065 Call to function 'function' with no prototype (Default ON)
-w-rch -w-8066 Unreachable code (Default ON)
-w-ret -w-8067 Both return and return of a value used (Default ON)
-w-rng -w-8068 Constant out of range in comparison (Default ON)
-w-rpt -w-8069 Nonportable pointer conversion (Default ON)
-w-rvl -w-8070 Function should return a value (Default ON)
-wsig -w8071 Conversion may lose significant digits (Default OFF)
-w-spa -w-8072 Suspicious pointer arithmetic (Default ON)
-w-stl -w-8087 'operator==' must be publicly visible to be contained by a 'name' (Default OFF)
-w-stl -w-8089 'operator<' must be publicly visible to be contained by a 'name' (Default OFF)
-w-stl -w-8090 'operator<' must be publicly visible to be used by a 'name' (Default OFF)
-w-stl -w-8091 'type' argument 'argument' passed to 'function' is a 'type' iterator. 'type' iterator required (Default OFF)
-w-stl -w-8092 'type' argument 'argument' passed to 'function' is not an iterator. 'type' iterator required (Default OFF)
-wstu -w8073 Undefined structure 'structure' (Default OFF)
-wstv -w8074 Structure passed by value (Default OFF)
-w-sus -w-8075 Suspicious pointer conversion (Default ON)
-w-tai -w-8076 Template instance 'instance' is already instantiated (Default ON)
-w-tes -w-8077 Explicitly specializing an explicitly specialized class member makes no sense (Default ON)
-w-thr -w-8078 Throw expression violates exception specification (Default ON)
-wucp -w8079 Mixing pointers to different 'char' types (Default OFF)
-wuse -w8080 'identifier' declared but never used (Default OFF)
-w-voi -w-8081 void functions may not return a value (Default ON)
-w-zdi -w-8082 Division by zero (Default ON)
More information about the vtkusers
mailing list