Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8881851
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 14, 20262026-06-14T20:25:55+00:00 2026-06-14T20:25:55+00:00

I found a method for importing 3D models to Android’s OpenGL on Stackoverflow here:

  • 0

I found a method for importing 3D models to Android’s OpenGL on Stackoverflow here:

Is there a way to import a 3D model into Android?

Attempting to follow the instructions I copied the source and tried to compile the program. I got a massive number of errors, here is just a small sample:

    /tmp/ccPavSpL.o:OFF-OpenGL_loader.cc:(.text+0xd): undefined reference to `std::basic_string<char,
    std::char_traits<char>, std::allocator<char> >::size() const'

I think the problem was I wasn’t passing in arguments to the program, so I tried passing arguments like so:

    $  gcc OFF-OpenGL_loader.cc circle.off output.xml

(My .off file was in the same directory as the other source files and the output.xml was also in the same file.)
I got these errors

    /usr/lib/gcc/i686-pc-cygwin/3.4.4/../../../../i686-pc-cygwin/bin/ld:circle.off: file format not recognized;
    treating as linker script
    /usr/lib/gcc/i686-pc-cygwin/3.4.4/../../../../i686-pc-cygwin/bin/ld:circle.off:2: syntax error
    collect2: ld returned 1 exit status

Anyway so I have a feeling I wasn’t supposed to have an output.xml file but when I didn’t have one then it gave me a file not found error.

The opensource files were not in actual files so I feel like I should show you all my files and I feel weird uploading someone else’s source to a github repo, so here is a rapid share link to the source files:

http://d01.megashares.com/dl/2YylIbE/SourceCodeAnd.offFile.zip

I feel weird sharing files like this^^ but I don’t really see any other option. It just contains my .off file and .xml file and the C and C++ files.

Any help would be greatly appreciated, I’ve spent the past few days stuck on this.
Thanks!

Edit

So I ran it with g++ and with no parameters and these were the results:

     $  g++ OFF-OpenGL_loader.cc
     /tmp/ccNFneYn.o:OFF-OpenGL_loader.cc:(.text+0x1aa): undefined reference to  
     `ReadFile::getExtension(char*)'/tmp/ccNFneYn.o:
    OFF-OpenGL_loader.cc:(.text+0x2f8): undefined reference to 
    operator>>(std::basic_ifstream<char, std::
    char_traits<char> >&, ReadFile&)'/tmp/ccNFneYn.o:OFF-
    OpenGL_loader.cc:(.text+0x6de): undefined reference to `ReadFile::ReadFile()'/tmp/ccNFneYn.o:OFF-
    OpenGL_loader.cc:(.text+0x6f9): undefined reference to `ReadFile::~ReadFile()'/usr/lib/gcc/i686-pc-
    cygwin/3.4.4/../../../../i686-pc-cygwin/bin/ld: 
    /tmp/ccNFneYn.o: bad reloc address 0x1c in section 
    `.gcc_except_table'/usr/lib/gcc/i686-pc-cygwin/3.4.4/.
    ./../../../i686-pc-cygwin/bin/ld: final link failed: 
    Invalid operationcollect2: ld returned 1 exit status

What kind of errors am I looking for?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-14T20:25:56+00:00Added an answer on June 14, 2026 at 8:25 pm

    The problem was that when I ran my program in Visual Studio it would both compile and run the program, and because the source required parameters to be run, it would come up with runtime errors.

    Then because I didn’t know how to pass parameters to programs in visual studio, I tried using Cygwin which gave me errors, probably because it wasn’t configured correctly. Not really sure why those errors happened.

    So to solve this whole thing I just built my program with Visual Studio, navigated to the .exe file that it creates when it compiles, and then ran that .exe in the command line.

    So the moral of the story is: always remember that when you hit that green play button, it both compiles and runs the program. So if your error has to do with the circumstances that you run your program in, you might get errors even if your code is perfectly fine.

    Thanks Bo Persson for helping me get that idea!

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Is there a way to Import an entire CSV file into SQLite through the
I found that there's a clearRect() method, but can't find any to clear an
I found the method addAWTKeyListener in the class Toolkit, but I can't get it
I've found a method using reflection (and got it's MethodInfo ). How can I
I've found a method on the Internet to convert RGB values to HSV values.
I added 3 optional boolean parameters to a method found within a VB6 DLL.
I am getting a Method not found: 'Boolean MyCompany.LibraryAssembly.SomeFunction(System.String)' exception/error when running a VB.NET
I was working on a demo method and found something strange(at least to me
I found it odd that a string method operation on a string object doesn't
I found out this morning that proc.new works in a class initialize method, but

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.