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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 30, 20262026-05-30T23:57:49+00:00 2026-05-30T23:57:49+00:00

Trying to run the following code in Qt Creator on Win7 64bit. #include <boost/date_time/posix_time/posix_time.hpp>

  • 0

Trying to run the following code in Qt Creator on Win7 64bit.

#include <boost/date_time/posix_time/posix_time.hpp>
#include <boost/date_time/gregorian/gregorian.hpp>

int main() {
    using namespace boost::posix_time;
    ptime t = microsec_clock::universal_time();
    std::cout << to_iso_extended_string(t) << "Z\n";
}

This is my *.pro file:

INCLUDEPATH += "C:\Program Files (x86)\boost\boost_1_47"
CONFIG += boost
LIBS += -L"C:\Program Files (x86)\boost\boost_1_47\lib"
LIBS += -lboost_date_time-vc71-mt-1_47

I get the following error:

c:\Program Files (x86)\boost\boost_1_47\boost\date_time\date_formatting.hpp:49: error: undefined reference to `boost::gregorian::greg_month::as_long_string() const’

c:\Program Files (x86)\boost\boost_1_47\boost\date_time\date_formatting.hpp:44: error: undefined reference to `boost::gregorian::greg_month::as_short_string() const’

How can I get this to work? I read that I need to build the date time lib but I’m not to sure how I would do that.

  • 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-05-30T23:57:51+00:00Added an answer on May 30, 2026 at 11:57 pm

    These boost library binaries are compiled with and for the Visual C++ compiler (you can guess by the ‘vc71’ in the file name), but you are using QtCreator with the MinGW compiler and you can’t mix C++ libraries compiled with different compilers (only the C part of the library would be usable).

    You can either continue to use MinGW and recompile boost yourself *, or change the compiler used by QtCreator in the project configuration, assuming you have installed any version of Visual C++ and the Qt binaries for that compiler.

    * : Since MinGW can be configured with lot of different incompatible options, it is safer to recompile boost than using precompiled binaries, unless you are sure they were built with the same MinGW that is included in your Qt SDK.

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

Sidebar

Related Questions

I am new to python and I am trying to run following code: m=int(raw_input())
I'm trying to run following code: some_sock.async_connect(...); // handle_connect() sets the 'condition' flag boost::asio::deadline_timer
I am trying to run the following code from within Eclipse: Process process =
I am trying to run the following code: public BigDecimal valuate(String searchTerms, String categoryPath)
I'm trying to run the following code with Ninject.Moq: [TestMethod] public void TestMethod1() {
I am trying to run the following code (which I got from here ).
I am trying to run the following ruby code from IRB but am unable
I'm using the following code to run a passthrough query. I'm trying to run
I'm trying to run this jQuery selector: $(#label option[value=\newLabel\]) On the following code: <select
i am trying to run following code mDb.beginTransaction(); String updateQuery =INSERT INTO MAAccounts(userId, accountId,

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.