Frustration with PDcurses!

This is a discussion on Frustration with PDcurses! within the Tech Board forums, part of the Community Boards category; How on earth do i get PDcurses to work with MinGW? I've already managed to compile it, and i now ...

  1. #1
    Internet Superhero
    Join Date
    Sep 2006
    Location
    Denmark
    Posts
    964

    Frustration with PDcurses!

    How on earth do i get PDcurses to work with MinGW? I've already managed to compile it, and i now have a file called "libpdcurses.a" in my lib directory, and the curses.h header in "include", but i still get undefined reference errors when trying to use any functions from the library.

    Code:
    #include <curses.h>
    int main(void)
    {
         initscr();
         endwin();
    }
    If i try to compile the above program with:
    Code:
    g++ -Llibpdcurses.a main.cpp
    i just get 2 undefined reference errors, i've also tried virtually any variation of the above, still not working?

  2. #2
    Woof, woof! zacs7's Avatar
    Join Date
    Mar 2007
    Location
    Australia
    Posts
    3,459
    Use,
    Code:
    g++ -lpdcurses main.cpp

  3. #3
    and the hat of int overfl Salem's Avatar
    Join Date
    Aug 2001
    Location
    The edge of the known universe
    Posts
    32,854
    Historically at least, order mattered, in which case
    Code:
    g++ main.cpp -lpdcurses
    If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.
    If at first you don't succeed, try writing your phone number on the exam paper.
    I support http://www.ukip.org/ as the first necessary step to a free Europe.

  4. #4
    Internet Superhero
    Join Date
    Sep 2006
    Location
    Denmark
    Posts
    964
    Apparently i didn't try every combination, but thanks to you guys it's working fine now, thanks alot

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Frustration with tutorial.
    By A34Chris in forum C Programming
    Replies: 19
    Last Post: 03-18-2008, 04:08 AM
  2. extreme frustration with vectors
    By n3v in forum C++ Programming
    Replies: 1
    Last Post: 12-04-2006, 09:39 PM
  3. Nested loop frustration
    By caroundw5h in forum C Programming
    Replies: 14
    Last Post: 03-15-2004, 09:45 PM
  4. Frustration
    By curlious in forum A Brief History of Cprogramming.com
    Replies: 6
    Last Post: 09-29-2003, 03:22 PM
  5. Frustration
    By kas2002 in forum C++ Programming
    Replies: 4
    Last Post: 05-29-2002, 06:00 PM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21