Compile dtAgeiaPhysX in 64-bit Linux

Source: Internet
Author: User
Article Title: Compile dtAgeiaPhysX in 64-bit Linux. Linux is a technology channel of the IT lab in China. Includes basic categories such as desktop applications, Linux system management, kernel research, embedded systems, and open source.

DtAgeiaPhysX is a plug-in of Delta3D that encapsulates nVidia PhysX. To use it, you must also compile Delta3D. Unfortunately, compiling Delta3D is not a small task, and PhysX does not have a 64-bit version. In this case, all related software must be installed or compiled with a 32-bit version. The trouble is far beyond imagination. It seems that the CMakeLists.txt file in the Delta3D svn library is a bit problematic. I have corrected it, but I don't remember what I have changed. In short, it is not very difficult, I will not remember it here.

In general, because the vast majority of 32-bit software or libraries are not installed, the compilation process often encounters errors such as incompatible library files. At this time, you can use the full path name of the rpm-qf library file to check the database. Once you know the library name, you can use the yum install library name. i586 to install its 32-bit version. During installation, conflicts may easily occur (some files are the same as 64-bit versions). If the installation is unsuccessful, You need to identify the cause. If only files such as doc or include conflict with each other, you can perform bold overwriting. In this case, you can find the downloaded rpm package in the corresponding subdirectory of/var/cache/yum/and use the rpm-ivh -- force rpm file name to forcibly overwrite and install the package.

The annoyance is that the CMake script usually determines whether to use a 64-bit system by checking whether the CMAKE_SIZEOF_VOID_P is 8. In this way, the 32-bit library will also be installed in the lib64 directory. I thought, either change CMakeLists.txt and set the target directory to lib directly. Otherwise, I had to install it manually without making install. Depressed. Can't you tell cmake that I want to compile a 32-bit version? -- Changed CMakeLists.txt and set LIB_POSTFIX to null.

Delta3D: an open-source 3D simulation/game engine software that integrates many related components, such as ODE, OpenDIS, and OpenAL, and has almost the ability to directly create 3D simulation systems or games. 3D is mainly based on OSG.

Modify the CMakeLists.txt file, find the appropriate location, add the-m32 parameter to CMAKE_CXX_FLAGS, and forcibly compile it into a 32-bit version. If you really don't want to find it, add: SET (CMAKE_CXX_FLAGS "$ {CMAKE_CXX_FLAGS}-m32" at the end ".

The following issues should be caused by the GCC version. It seems that cstdio in the new version of GCC is no longer used as the default header file.

Snprintf is not defined in. modify this file and add # include Okay.

Va_list is not defined in. Same as above, modify this file and add # include Okay.

Fpos_t is not defined in. The process is the same as above.

I don't know why I want to find/usr/local/lib64/libgne. a and forcibly change the CMakeModules/FindGNE. cmake file to assign values directly. It is suspected that it is a cache problem.

OSG: Open Scene Graph is basically the C ++ package of OpenGL. However, it provides many advanced functions and is basically a complete 3D engine.

DtAgeiaPhysX: it is an encapsulation of the nVidia PhysX physical engine (originally developed by Ageia, which has been acquired by nVidia) for Delta3D integration.

OpenDIS:

It does not use CMake. It is a little troublesome. You need to add the-m32 parameter and modify the Makefile. However, there is nothing in its main Makefile, but there are four makefiles, one DIS. mak is the main one, and there are two example. mak file, as well as a unit test. there is no way to change the mak file one by one.

HawkNL:

GNElib:

Gdal: This guy is actually a general library and should not be listed here. However, it is a special case and will appear in the form of a compilation error when the connection is not available, different from other databases. In fact, because there is no 32-bit package, it is missing a cpl_config-32.h header file, installed with 32-bit package ...... On my system, a guy with 17 "family" software -- if not all modern Linux versions have an automatic dependency resolution mechanism, it will be crazy.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.