I'm not able to compile it on my Linux box :(

Help
2005-05-12
2013-04-16
  • Dawid Gajownik
    Dawid Gajownik
    2005-05-12

    I got this errors:

    [y4kk0@X emu51]$ g++ emu51.cpp -o emu51
    /usr/lib/gcc/i386-redhat-linux/4.0.0/../../../crt1.o(.text+0x18): In function `_start':
    : undefined reference to `main'
    /tmp/ccL8gyck.o(.text+0xa0): In function `clear':
    emu51.cpp: undefined reference to `clear_bitmap'
    /tmp/ccL8gyck.o(.text+0xf6): In function `draw_SEG_digit(BITMAP*, int, int, int, int, unsigned char)':
    emu51.cpp: undefined reference to `getb'
    /tmp/ccL8gyck.o(.text+0x11a):emu51.cpp: undefined reference to `getg'
    /tmp/ccL8gyck.o(.text+0x13e):emu51.cpp: undefined reference to `getr'
    /tmp/ccL8gyck.o(.text+0x163):emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0x3b9): In function `draw_LED_bin(BITMAP*, int, int, int, unsigned char)':
    emu51.cpp: undefined reference to `getb'
    /tmp/ccL8gyck.o(.text+0x3dd):emu51.cpp: undefined reference to `getg'
    /tmp/ccL8gyck.o(.text+0x401):emu51.cpp: undefined reference to `getr'
    /tmp/ccL8gyck.o(.text+0x426):emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0x47e):emu51.cpp: undefined reference to `circlefill'
    /tmp/ccL8gyck.o(.text+0x58e): In function `GetText(char*, BITMAP*, int, int, int, int, int, char*)':
    emu51.cpp: undefined reference to `create_bitmap'
    /tmp/ccL8gyck.o(.text+0x5a2):emu51.cpp: undefined reference to `create_bitmap'
    /tmp/ccL8gyck.o(.text+0x5c3):emu51.cpp: undefined reference to `blit'
    /tmp/ccL8gyck.o(.text+0x5e5):emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0x627):emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0x668):emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0x6b5):emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0x6ff):emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0x730):emu51.cpp: undefined reference to `textprintf_centre'
    /tmp/ccL8gyck.o(.text+0x768):emu51.cpp: undefined reference to `clear_keybuf'
    /tmp/ccL8gyck.o(.text+0x774):emu51.cpp: undefined reference to `key'
    /tmp/ccL8gyck.o(.text+0x799):emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0x7cb):emu51.cpp: undefined reference to `textprintf'
    /tmp/ccL8gyck.o(.text+0x7e5):emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0x839):emu51.cpp: undefined reference to `blit'
    /tmp/ccL8gyck.o(.text+0x84a):emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0x888):emu51.cpp: undefined reference to `readkey'
    /tmp/ccL8gyck.o(.text+0x95e):emu51.cpp: undefined reference to `key'
    /tmp/ccL8gyck.o(.text+0x9bb):emu51.cpp: undefined reference to `key'
    /tmp/ccL8gyck.o(.text+0x9ed):emu51.cpp: undefined reference to `blit'
    /tmp/ccL8gyck.o(.text+0x9fb):emu51.cpp: undefined reference to `destroy_bitmap'
    /tmp/ccL8gyck.o(.text+0xa09):emu51.cpp: undefined reference to `destroy_bitmap'
    /tmp/ccL8gyck.o(.text+0xa29): In function `ShowMessage(char*, BITMAP*, int, int, int, int, char*)':
    emu51.cpp: undefined reference to `create_bitmap'
    /tmp/ccL8gyck.o(.text+0xa3d):emu51.cpp: undefined reference to `create_bitmap'
    /tmp/ccL8gyck.o(.text+0xa5e):emu51.cpp: undefined reference to `blit'
    /tmp/ccL8gyck.o(.text+0xa80):emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0xac2):emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0xb03):emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0xb50):emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0xb9a):emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0xbcb):emu51.cpp: undefined reference to `textprintf_centre'
    /tmp/ccL8gyck.o(.text+0xbe5):emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0xc17):emu51.cpp: undefined reference to `textprintf'
    /tmp/ccL8gyck.o(.text+0xc2b):emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0xc61):emu51.cpp: undefined reference to `textprintf_centre'
    /tmp/ccL8gyck.o(.text+0xc7f):emu51.cpp: undefined reference to `blit'
    /tmp/ccL8gyck.o(.text+0xc87):emu51.cpp: undefined reference to `key'
    /tmp/ccL8gyck.o(.text+0xc95):emu51.cpp: undefined reference to `key'
    /tmp/ccL8gyck.o(.text+0xcb9):emu51.cpp: undefined reference to `blit'
    /tmp/ccL8gyck.o(.text+0xcc7):emu51.cpp: undefined reference to `destroy_bitmap'
    /tmp/ccL8gyck.o(.text+0xcd5):emu51.cpp: undefined reference to `destroy_bitmap'
    /tmp/ccL8gyck.o(.text+0xcf4): In function `QuestionBox(char*, BITMAP*, int, int, int, int, char*, int)':
    emu51.cpp: undefined reference to `create_bitmap'
    /tmp/ccL8gyck.o(.text+0xd08):emu51.cpp: undefined reference to `create_bitmap'
    /tmp/ccL8gyck.o(.text+0xd37):emu51.cpp: undefined reference to `blit'
    /tmp/ccL8gyck.o(.text+0xd59):emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0xd9b):emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0xddc):emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0xe29):emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0xe73):emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0xea4):emu51.cpp: undefined reference to `textprintf_centre'
    /tmp/ccL8gyck.o(.text+0xeb8):emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0xeee):emu51.cpp: undefined reference to `textprintf_centre'
    /tmp/ccL8gyck.o(.text+0xf96):emu51.cpp: undefined reference to `textprintf'
    /tmp/ccL8gyck.o(.text+0xfca):emu51.cpp: undefined reference to `blit'
    /tmp/ccL8gyck.o(.text+0xfd2):emu51.cpp: undefined reference to `key'
    /tmp/ccL8gyck.o(.text+0xfdb):emu51.cpp: undefined reference to `key'
    /tmp/ccL8gyck.o(.text+0xff5):emu51.cpp: undefined reference to `key'
    /tmp/ccL8gyck.o(.text+0xffe):emu51.cpp: undefined reference to `key'
    /tmp/ccL8gyck.o(.text+0x1018):emu51.cpp: undefined reference to `key'
    /tmp/ccL8gyck.o(.text+0x1052): In function `ShowMsgEx(char*, BITMAP*, int, int, int, int, char*, int)':
    emu51.cpp: undefined reference to `create_bitmap'
    /tmp/ccL8gyck.o(.text+0x1066):emu51.cpp: undefined reference to `create_bitmap'
    /tmp/ccL8gyck.o(.text+0x1095):emu51.cpp: undefined reference to `blit'
    /tmp/ccL8gyck.o(.text+0x10b7):emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0x10f9):emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0x113a):emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0x1187):emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0x11d1):emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0x1202):emu51.cpp: undefined reference to `textprintf_centre'
    /tmp/ccL8gyck.o(.text+0x1216):emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0x124c):emu51.cpp: undefined reference to `textprintf_centre'
    /tmp/ccL8gyck.o(.text+0x12f4):emu51.cpp: undefined reference to `textprintf'
    /tmp/ccL8gyck.o(.text+0x1328):emu51.cpp: undefined reference to `blit'
    /tmp/ccL8gyck.o(.text+0x1330):emu51.cpp: undefined reference to `key'
    /tmp/ccL8gyck.o(.text+0x133e):emu51.cpp: undefined reference to `key'
    /tmp/ccL8gyck.o(.text+0x1362):emu51.cpp: undefined reference to `blit'
    /tmp/ccL8gyck.o(.text+0x1370):emu51.cpp: undefined reference to `destroy_bitmap'
    /tmp/ccL8gyck.o(.text+0x137e):emu51.cpp: undefined reference to `destroy_bitmap'
    /tmp/ccL8gyck.o(.text+0x6231): In function `regs::regs(unsigned char*, BITMAP*)':
    emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0x6256):emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0x6278):emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0x6297):emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0x62b6):emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0x6305):emu51.cpp: undefined reference to `create_bitmap'
    /tmp/ccL8gyck.o(.text+0x633b): In function `regs::regs(unsigned char*, BITMAP*)':
    emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0x6360):emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0x6382):emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0x63a1):emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0x63c0):emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0x640f):emu51.cpp: undefined reference to `create_bitmap'
    /tmp/ccL8gyck.o(.text+0x647d): In function `regs::blit_it(int, int)':
    emu51.cpp: undefined reference to `blit'
    /tmp/ccL8gyck.o(.text+0x64dc): In function `regs::draw()':
    emu51.cpp: undefined reference to `textprintf'
    /tmp/ccL8gyck.o(.text+0x65ae):emu51.cpp: undefined reference to `textprintf'
    /tmp/ccL8gyck.o(.text+0x67ee):emu51.cpp: undefined reference to `textprintf_centre'
    /tmp/ccL8gyck.o(.text+0x6838): In function `regs::hexoutB(int, int, int, unsigned char)':
    emu51.cpp: undefined reference to `textprintf'
    /tmp/ccL8gyck.o(.text+0x6869):emu51.cpp: undefined reference to `textprintf'
    /tmp/ccL8gyck.o(.text+0x6893):emu51.cpp: undefined reference to `textprintf'
    /tmp/ccL8gyck.o(.text+0x68dc): In function `dis_asm::dis_asm(unsigned char*, BITMAP*)':
    emu51.cpp: undefined reference to `create_bitmap'
    /tmp/ccL8gyck.o(.text+0x6938): In function `dis_asm::dis_asm(unsigned char*, BITMAP*)':
    emu51.cpp: undefined reference to `create_bitmap'
    /tmp/ccL8gyck.o(.text+0x698b): In function `dis_asm::hexoutB(int, int, int, unsigned char)':
    emu51.cpp: undefined reference to `textprintf'
    /tmp/ccL8gyck.o(.text+0x69b9):emu51.cpp: undefined reference to `textprintf'
    /tmp/ccL8gyck.o(.text+0x69e0):emu51.cpp: undefined reference to `textprintf'
    /tmp/ccL8gyck.o(.text+0x6a05): In function `dis_asm::draw(unsigned short)':
    emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0x6a22):emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0x6a3c):emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0x6b1e):emu51.cpp: undefined reference to `textprintf'
    /tmp/ccL8gyck.o(.text+0x6c16):emu51.cpp: undefined reference to `textprintf'
    /tmp/ccL8gyck.o(.text+0x6c78):emu51.cpp: undefined reference to `textprintf'
    /tmp/ccL8gyck.o(.text+0x6cf3):emu51.cpp: undefined reference to `textprintf'
    /tmp/ccL8gyck.o(.text+0x6e56):emu51.cpp: undefined reference to `textprintf_centre'
    /tmp/ccL8gyck.o(.text+0x6e95): In function `dis_asm::blit_it(int, int)':
    emu51.cpp: undefined reference to `blit'
    /tmp/ccL8gyck.o(.text+0x6f1a): In function `flags::flags(BITMAP*)':
    emu51.cpp: undefined reference to `create_bitmap'
    /tmp/ccL8gyck.o(.text+0x6f60): In function `flags::flags(BITMAP*)':
    emu51.cpp: undefined reference to `create_bitmap'
    /tmp/ccL8gyck.o(.text+0x6fad): In function `flags::draw()':
    emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0x6fca):emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0x6fe4):emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0x702c):emu51.cpp: undefined reference to `textprintf'
    /tmp/ccL8gyck.o(.text+0x7066):emu51.cpp: undefined reference to `textprintf'
    /tmp/ccL8gyck.o(.text+0x70a0):emu51.cpp: undefined reference to `textprintf'
    /tmp/ccL8gyck.o(.text+0x70da):emu51.cpp: undefined reference to `textprintf'
    /tmp/ccL8gyck.o(.text+0x7115):emu51.cpp: undefined reference to `textprintf'
    /tmp/ccL8gyck.o(.text+0x7151):emu51.cpp: more undefined references to `textprintf' follow
    /tmp/ccL8gyck.o(.text+0x75ae): In function `flags::draw()':
    emu51.cpp: undefined reference to `textprintf_centre'
    /tmp/ccL8gyck.o(.text+0x75ef): In function `flags::blit_it(int, int)':
    emu51.cpp: undefined reference to `blit'
    /tmp/ccL8gyck.o(.text+0x7636): In function `ramv::ramv(BITMAP*)':
    emu51.cpp: undefined reference to `create_bitmap'
    /tmp/ccL8gyck.o(.text+0x7692): In function `ramv::ramv(BITMAP*)':
    emu51.cpp: undefined reference to `create_bitmap'
    /tmp/ccL8gyck.o(.text+0x76ff): In function `ramv::blit_it(int, int)':
    emu51.cpp: undefined reference to `blit'
    /tmp/ccL8gyck.o(.text+0x7746): In function `ramv::hexoutB(int, int, int, unsigned char)':
    emu51.cpp: undefined reference to `textprintf'
    /tmp/ccL8gyck.o(.text+0x7777):emu51.cpp: undefined reference to `textprintf'
    /tmp/ccL8gyck.o(.text+0x77a1):emu51.cpp: undefined reference to `textprintf'
    /tmp/ccL8gyck.o(.text+0x77c5): In function `ramv::draw(unsigned short)':
    emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0x77e2):emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0x77ff):emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0x7816):emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0x7830):emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0x784a):emu51.cpp: more undefined references to `makecol' follow
    /tmp/ccL8gyck.o(.text+0x78c7): In function `ramv::draw(unsigned short)':
    emu51.cpp: undefined reference to `textprintf'
    /tmp/ccL8gyck.o(.text+0x7a98):emu51.cpp: undefined reference to `font'
    /tmp/ccL8gyck.o(.text+0x7ab8):emu51.cpp: undefined reference to `textprintf'
    /tmp/ccL8gyck.o(.text+0x7c30):emu51.cpp: undefined reference to `textprintf_centre'
    /tmp/ccL8gyck.o(.text+0x7dcd): In function `load_code_table(code_51*)':
    emu51.cpp: undefined reference to `screen'
    /tmp/ccL8gyck.o(.text+0x7e2e): In function `load_ram(char*, unsigned char*)':
    emu51.cpp: undefined reference to `screen'
    /tmp/ccL8gyck.o(.text+0x7ef6): In function `load_hex(char*, unsigned char*)':
    emu51.cpp: undefined reference to `screen'
    /tmp/ccL8gyck.o(.text+0x8067): In function `ChangeMonitedSFRRegister(regs*)':
    emu51.cpp: undefined reference to `screen'
    /tmp/ccL8gyck.o(.text+0x80ba):emu51.cpp: undefined reference to `screen'
    /tmp/ccL8gyck.o(.text+0x80de):emu51.cpp: more undefined references to `screen' follow
    /tmp/ccL8gyck.o(.text+0x816f): In function `reset51()':
    emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0x8178):emu51.cpp: undefined reference to `screen'
    /tmp/ccL8gyck.o(.text+0x81b3): In function `ViewAt()':
    emu51.cpp: undefined reference to `screen'
    /tmp/ccL8gyck.o(.text+0x821a): In function `ChangePC()':
    emu51.cpp: undefined reference to `screen'
    /tmp/ccL8gyck.o(.text+0x826f): In function `ChangeRegValue_SFR()':
    emu51.cpp: undefined reference to `screen'
    /tmp/ccL8gyck.o(.text+0x829a):emu51.cpp: undefined reference to `screen'
    /tmp/ccL8gyck.o(.text+0x8305):emu51.cpp: more undefined references to `screen' follow
    /tmp/ccL8gyck.o(.text+0x858c): In function `LoadSrc()':
    emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0x8595):emu51.cpp: undefined reference to `screen'
    /tmp/ccL8gyck.o(.text+0x8616):emu51.cpp: undefined reference to `screen'
    /tmp/ccL8gyck.o(.text+0x8661): In function `ChMaxI(int*)':
    emu51.cpp: undefined reference to `screen'
    /tmp/ccL8gyck.o(.text+0x86b1): In function `ChMemMode()':
    emu51.cpp: undefined reference to `screen'
    /tmp/ccL8gyck.o(.text+0x86fe): In function `FillExt()':
    emu51.cpp: undefined reference to `screen'
    /tmp/ccL8gyck.o(.text+0x8722):emu51.cpp: more undefined references to `screen' follow
    /tmp/ccL8gyck.o(.text+0x8828): In function `main_init()':
    emu51.cpp: undefined reference to `install_allegro'
    /tmp/ccL8gyck.o(.text+0x8830):emu51.cpp: undefined reference to `install_timer'
    /tmp/ccL8gyck.o(.text+0x8835):emu51.cpp: undefined reference to `install_keyboard'
    /tmp/ccL8gyck.o(.text+0x883f):emu51.cpp: undefined reference to `set_color_depth'
    /tmp/ccL8gyck.o(.text+0x885a):emu51.cpp: undefined reference to `set_gfx_mode'
    /tmp/ccL8gyck.o(.text+0x8865):emu51.cpp: undefined reference to `desktop_palette'
    /tmp/ccL8gyck.o(.text+0x886a):emu51.cpp: undefined reference to `set_palette'
    /tmp/ccL8gyck.o(.text+0x8887):emu51.cpp: undefined reference to `set_color'
    /tmp/ccL8gyck.o(.text+0x88a4):emu51.cpp: undefined reference to `set_color'
    /tmp/ccL8gyck.o(.text+0x88c1):emu51.cpp: undefined reference to `set_color'
    /tmp/ccL8gyck.o(.text+0x88e1):emu51.cpp: undefined reference to `set_color'
    /tmp/ccL8gyck.o(.text+0x88f1):emu51.cpp: undefined reference to `load_datafile'
    /tmp/ccL8gyck.o(.text+0x892c): In function `_mangled_main()':
    emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0x8945):emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0x895e):emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0x8977):emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0x8990):emu51.cpp: undefined reference to `makecol'
    /tmp/ccL8gyck.o(.text+0x899d):emu51.cpp: undefined reference to `screen'
    /tmp/ccL8gyck.o(.text+0x89b9):emu51.cpp: undefined reference to `screen'
    /tmp/ccL8gyck.o(.text+0x89d6):emu51.cpp: undefined reference to `screen'
    /tmp/ccL8gyck.o(.text+0x89eb):emu51.cpp: undefined reference to `screen'
    /tmp/ccL8gyck.o(.text+0x8d76):emu51.cpp: undefined reference to `screen'
    /tmp/ccL8gyck.o(.text+0x8d8b):emu51.cpp: undefined reference to `rect'
    /tmp/ccL8gyck.o(.text+0x8d99):emu51.cpp: undefined reference to `screen'
    /tmp/ccL8gyck.o(.text+0x8db4):emu51.cpp: undefined reference to `rect'
    /tmp/ccL8gyck.o(.text+0x8dc8):emu51.cpp: undefined reference to `screen'
    /tmp/ccL8gyck.o(.text+0x8de2):emu51.cpp: undefined reference to `textprintf'
    /tmp/ccL8gyck.o(.text+0x8df6):emu51.cpp: undefined reference to `screen'
    /tmp/ccL8gyck.o(.text+0x8e10):emu51.cpp: undefined reference to `textprintf'
    /tmp/ccL8gyck.o(.text+0x8e24):emu51.cpp: undefined reference to `screen'
    /tmp/ccL8gyck.o(.text+0x8e3e):emu51.cpp: undefined reference to `textprintf'
    /tmp/ccL8gyck.o(.text+0x8e4c):emu51.cpp: undefined reference to `screen'
    /tmp/ccL8gyck.o(.text+0x8e7a):emu51.cpp: undefined reference to `screen'
    /tmp/ccL8gyck.o(.text+0x8e91):emu51.cpp: undefined reference to `textprintf'
    /tmp/ccL8gyck.o(.text+0x8e9f):emu51.cpp: undefined reference to `screen'
    /tmp/ccL8gyck.o(.text+0x8ecd):emu51.cpp: undefined reference to `screen'
    /tmp/ccL8gyck.o(.text+0x8ee4):emu51.cpp: undefined reference to `textprintf'
    /tmp/ccL8gyck.o(.text+0x8ef2):emu51.cpp: undefined reference to `screen'
    /tmp/ccL8gyck.o(.text+0x8f20):emu51.cpp: undefined reference to `screen'
    /tmp/ccL8gyck.o(.text+0x8f37):emu51.cpp: undefined reference to `textprintf'
    /tmp/ccL8gyck.o(.text+0x8f4b):emu51.cpp: undefined reference to `screen'
    /tmp/ccL8gyck.o(.text+0x8f5f):emu51.cpp: undefined reference to `textout'
    /tmp/ccL8gyck.o(.text+0x8f73):emu51.cpp: undefined reference to `screen'
    /tmp/ccL8gyck.o(.text+0x8f8a):emu51.cpp: undefined reference to `textout'
    /tmp/ccL8gyck.o(.text+0x8fa7):emu51.cpp: undefined reference to `screen'
    /tmp/ccL8gyck.o(.text+0x8fc5):emu51.cpp: undefined reference to `rect'
    /tmp/ccL8gyck.o(.text+0x91b5):emu51.cpp: undefined reference to `screen'
    /tmp/ccL8gyck.o(.text+0x91d8):emu51.cpp: undefined reference to `key'
    /tmp/ccL8gyck.o(.text+0x91ea):emu51.cpp: undefined reference to `key'
    /tmp/ccL8gyck.o(.text+0x91ff):emu51.cpp: undefined reference to `key'
    /tmp/ccL8gyck.o(.text+0x9214):emu51.cpp: undefined reference to `key'
    /tmp/ccL8gyck.o(.text+0x9229):emu51.cpp: undefined reference to `key'
    /tmp/ccL8gyck.o(.text+0x923e):emu51.cpp: more undefined references to `key' follow
    /tmp/ccL8gyck.o(.text+0x9a14): In function `_mangled_main()':
    emu51.cpp: undefined reference to `screen'
    /tmp/ccL8gyck.o(.text+0x9a50):emu51.cpp: undefined reference to `key'
    /tmp/ccL8gyck.o(.text+0x9a59):emu51.cpp: undefined reference to `key'
    collect2: ld returned 1 exit status
    [y4kk0@X emu51]$

    How can I resolve this problem?

     
  • NicolaGiacobbe
    NicolaGiacobbe
    2012-07-30

    use the following makefile:
    ---------start-of-makefile-----------
    emu51 : emu51.o
    g++ emu51.o -o emu51 `allegro-config -libs`

    emu51.o :       emu51.cpp
    g++ -c emu51.cpp -o emu51.o
    ---------end-of-makefile------------