Menu

missing _syscall5 (?)

Help
2007-02-01
2013-01-11
  • Daniel Wagner

    Daniel Wagner - 2007-02-01

    Hello,

    I'm trying to install Basilisk on a Linux machine, but I'm running into a bit of trouble.  I couldn't install the binary package, so I'm trying to build from source myself.  But make gives me the following error in sys_unix.cpp:

    ~/Desktop/BasiliskII-0.9/src/Unix% make
    c++ -I../include -I. -I../uae_cpu -DHAVE_CONFIG_H  -DOS_linux -DCPU_i386 -DDIRECT_ADDRESSING -DREGPARAM="__attribute__((regparm(3)))" -DX86_ASSEMBLY -DUNALIGNED_PROFITABLE -DOPTIMIZED_FLAGS -DFPU_X86 -D_REENTRANT -DDATADIR=\"/usr/local/share/BasiliskII\" -O2 -I/usr/include/gtk-1.2 -I/usr/include/glib-1.2 -I/usr/lib/glib/include -fomit-frame-pointer -c sys_unix.cpp -o obj/sys_unix.o
    sys_unix.cpp:36: error: ‘_llseek’ has not been declared
    sys_unix.cpp:36: error: ‘fd’ has not been declared
    sys_unix.cpp:36: error: ‘hi’ has not been declared
    sys_unix.cpp:36: error: ‘lo’ has not been declared
    sys_unix.cpp:36: error: ‘res’ has not been declared
    sys_unix.cpp:36: error: ‘wh’ has not been declared
    sys_unix.cpp:36: error: expected constructor, destructor, or type conversion before ‘;’ token
    sys_unix.cpp: In function ‘void* Sys_open(const char*, bool)’:
    sys_unix.cpp:299: error: ‘_llseek’ was not declared in this scope
    sys_unix.cpp: In function ‘size_t Sys_read(void*, void*, loff_t, size_t)’:
    sys_unix.cpp:380: error: ‘_llseek’ was not declared in this scope
    sys_unix.cpp: In function ‘size_t Sys_write(void*, void*, loff_t, size_t)’:
    sys_unix.cpp:406: error: ‘_llseek’ was not declared in this scope
    make: *** [obj/sys_unix.o] Error 1
    zsh: exit 2     make

    After looking around on the web a bit, it seems to me like <linux/unistd.h> is supposed to #define a macro called _syscall5, but... it doesn't.  I tried copying the definition from the 2.4 kernel (from http://futura.disca.upv.es/lxr/http/source/include/asm-i386/unistd.h\) to the top of sys_unix.cpp.  This also doesn't work; gcc complains that there is an "unsatisfiable constraint" in the assembly code that this creates.  (I don't understand assembly well enough to debug this myself, unfortunately...)

    Does anybody have any clues?  Or, if you have an i386 header with _syscall5 defined in it, care to share with me? =P

    Thanks,
    ~d

     
    • Matthew Hauck

      Matthew Hauck - 2007-07-10

      I have the exact same problem. Has anybody solved this yet? I am running Ubuntu 7.04. Can't seem to find any one else that has had this problem.

       
  • $yntax88

    $yntax88 - 2010-12-13

    I also have this problem under Slackware 13.1.  Has anyone found anything about it yet?

    I have tried modifying the Makefile in several ways that have helped others with similar issues but the error continues.  Here is exactly what I get when trying to compile:

    c++ -I../include -I. -lstdc++ -I../uae_cpu -DHAVE_CONFIG_H  -DOS_linux -DCPU_i386 -DDIRECT_ADDRESSING -DREGPARAM="__attribute__((regparm(3)))" -DX86_ASSEMBLY -DUNALIGNED_PROFITABLE -DOPTIMIZED_FLAGS -DFPU_X86 -D_REENTRANT -DDATADIR=\"/usr/local/share/BasiliskII\" -O2 -I/usr/include/gtk-1.2 -I/usr/include/glib-1.2 -I/usr/lib/glib/include -fomit-frame-pointer -c sys_unix.cpp -o obj/sys_unix.o
    sys_unix.cpp:36: error: '_llseek' has not been declared
    sys_unix.cpp:36: error: 'fd' has not been declared
    sys_unix.cpp:36: error: 'hi' has not been declared
    sys_unix.cpp:36: error: 'lo' has not been declared
    sys_unix.cpp:36: error: 'res' has not been declared
    sys_unix.cpp:36: error: 'wh' has not been declared
    sys_unix.cpp:36: error: expected constructor, destructor, or type conversion before ';' token
    sys_unix.cpp: In function 'void* Sys_open(const char*, bool)':
    sys_unix.cpp:299: error: '_llseek' was not declared in this scope
    sys_unix.cpp: In function 'size_t Sys_read(void*, void*, loff_t, size_t)':
    sys_unix.cpp:380: error: '_llseek' was not declared in this scope
    sys_unix.cpp: In function 'size_t Sys_write(void*, void*, loff_t, size_t)':
    sys_unix.cpp:406: error: '_llseek' was not declared in this scope
    

    And here is my PATH:

    /usr/local/bin:/usr/bin:/bin:/usr/games:/usr/lib/java/bin:/usr/lib/kde4/libexec:/usr/lib/qt/bin:/usr/share/texmf/bin:.:/usr/include:/usr/include/linux
    
     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.