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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 24, 20262026-05-24T16:51:38+00:00 2026-05-24T16:51:38+00:00

When I try and build my project I get the following errors: 1>Assignment1CoreTest.obj :

  • 0

When I try and build my project I get the following errors:

1>Assignment1CoreTest.obj : error LNK2019: unresolved external symbol "struct point * __cdecl findLongPaths(struct point *,double)" (?findLongPaths@@YAPAUpoint@@PAU1@N@Z) referenced in function "public: void __thiscall Geometry_CoreUnitTest::test_method(void)" (?test_method@Geometry_CoreUnitTest@@QAEXXZ)
1>Assignment1CoreTest.obj : error LNK2019: unresolved external symbol "double __cdecl calculateLineLength(struct point *)" (?calculateLineLength@@YANPAUpoint@@@Z) referenced in function "public: void __thiscall Geometry_CoreUnitTest::test_method(void)" (?test_method@Geometry_CoreUnitTest@@QAEXXZ)
1>C:\Users\user\documents\visual studio 2010\Projects\Assignment1\Debug\Assignment1.exe : fatal error LNK1120: 2 unresolved externals

I’ve been trying to work out why for the last hour or so and have made absolutely no progress so I was wondering if anyone might be able to point me in the right direction. Obviously I’m doing something stupid but I can’t work out what.

This is my AssignmentOneCoreTest.cpp:

#define BOOST_TEST_MODULE Test_Assignment1

#include <boost/test/unit_test.hpp>

#include "geometry.h"

BOOST_AUTO_TEST_CASE(Geometry_CoreUnitTest) {
    point p[3] = {{0,0}, {0,3}, {0,1, true}};
    point longest[2] = {{0,1}, {0,3,true}};
    BOOST_CHECK_EQUAL(calculateLineLength(p), 5);

    point *longest_calculated = findLongPaths(p, 1.1);
    BOOST_CHECK_EQUAL(longest_calculated[1].y, longest[1].y);
    delete longest_calculated;
}

Geometry.cpp:

#include "geometry.h"
#include <iostream>
using namespace std; 

double calculateLineLength(point *points)
{
    ...
}

point *findLongPaths(point *points, double threshold_distance)
{
    ...
}

and Geometry.h:

#ifndef GEOMETRY_H
#define GEOMETRY_H

typedef struct {
    int x;
    int y;
    bool end;
} point;

double calculateLineLength(point *points);
point *findLongPaths(point *points, double threshold_distance);

#endif

I’m totally stumped and starting to get kinda frustrated, what am I overlooking?

  • 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-24T16:51:39+00:00Added an answer on May 24, 2026 at 4:51 pm

    you are getting linker error.
    Most probably you are not generating the object code for Geometry.cpp

    this would work for now:

    1. create an empty project;
    2. copy the header files in the headerfiles folder
    3. copy the cpp files in the cpp files folder

    then build the project;

    this will build your Geometry.cpp program as well.

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

Sidebar

Related Questions

I get the following errors when I try to build this project: error C2182:
When I try to build my setup project, I get the following error: An
When I try to build my project I get the following message in the
When I try to build my solution, I get the following error: Visual Studio
I'm getting an error message when I try to build my project in eclipse:
Try loading this normal .jpg file in Internet Explorer 6.0. I get an error
When I try to build a project that uses Flex and where the Flex
I try to build my app with CMake on Mac OS X, I get
When I try to build my projects in Visual Studio 2008, web sites won't
I try to build a gui (Swing) for a simple java application. The 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.