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 8253769
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 8, 20262026-06-08T00:59:21+00:00 2026-06-08T00:59:21+00:00

I want to use SQLite with c++ on Ubuntu. I chose to try the

  • 0

I want to use SQLite with c++ on Ubuntu. I chose to try the example from https://www.sqlite.org/quickstart.html. But when running c++ test.cpp -o test I get the error:

/tmp/ccTwwjKw.o: In function `main':
test.cpp:(.text+0xf1): undefined reference to `sqlite3_open'
test.cpp:(.text+0x106): undefined reference to `sqlite3_errmsg'
test.cpp:(.text+0x12e): undefined reference to `sqlite3_close'
test.cpp:(.text+0x15d): undefined reference to `sqlite3_exec'
test.cpp:(.text+0x18f): undefined reference to `sqlite3_free'
test.cpp:(.text+0x19b): undefined reference to `sqlite3_close'
collect2: ld gab 1 als Ende-Status zurück

I think the Problem is the same as here: Sqlite undefined reference to `sqlite3_open' error in Netbeans C++ on Ubuntu, Integrating SQLite into Netbeans C++ Ubuntu. But I have no make file and I don’t use netbeans.

  • 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-08T00:59:23+00:00Added an answer on June 8, 2026 at 12:59 am

    This is a linker error and you are not linking to any libraries. Link to the correct libraries using -llibname where libname is the name of your library with lib removed from the start. For example if the libname is libsqlite3.so try adding -lsqlite3 at the end of your compilation step. Of course you need to also provide the path to that library if it is in a non standard place using the -L/path/to/lib option and obviously you will need to have installed the relevant library first.

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

Sidebar

Related Questions

I have normal sqlite database and want to use fts3. As mentioned in http://www.sqlite.org/fts3.html
In my Android app, I want to use my existing sqlite database.I followed http://www.reigndesign.com/blog/using-your-own-sqlite-database-in-android-applications/
I am starting a project from scratch in WPF using SQLite.I want to use
I just want to use SQLite in a Java application. I found sqlitejdbc but
I want to use an asynchronous method to select strings from SQLite DB with
I need to use SQLite in linux/ubuntu and I want to use sqlite like
I want to get start with DayPilot control I do not use SQLite and
I want to use sqlite3 for my iphone application. But it is not working.
I want use BYTE_ORDER macro in my Xcode project but i can't because i
I want to use an embed an sqlite database into an existing tcl application

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.