Kan inte kompilera någonting [Debian]

Permalänk
Medlem

Kan inte kompilera någonting [Debian]

Hej! Jag installerade debian sarge på en kompis server, men nu lyckas jag inte kompilera några program alls.
Jag har installerat gcc och make med
apt-get install gcc
apt-get install make

Fick detta felmeddelande när jag försökte kompilera moon-buggy:

debian:~/moon-buggy-1.0# ./configure
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for gawk... no
checking for mawk... mawk
checking whether make sets $(MAKE)... yes
checking build system type... i686-pc-linux-gnulibc1
checking host system type... i686-pc-linux-gnulibc1
checking for gcc... gcc
checking for C compiler default output file name... configure: error: C compiler cannot create executables
See `config.log' for more details.
debian:~/moon-buggy-1.0#

I config.log står det här:

This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.

It was created by moon-buggy configure 1.0, which was
generated by GNU Autoconf 2.59. Invocation command line was

$ ./configure

## --------- ##
## Platform. ##
## --------- ##

hostname = debian
uname -m = i686
uname -r = 2.4.27-1-386
uname -s = Linux
uname -v = #1 Wed Dec 1 19:43:08 JST 2004

/usr/bin/uname -p = unknown
/bin/uname -X = unknown

/bin/arch = i686
/usr/bin/arch -k = unknown
/usr/convex/getsysinfo = unknown
hostinfo = unknown
/bin/machine = unknown
/usr/bin/oslevel = unknown
/bin/universe = unknown

PATH: /usr/local/sbin
PATH: /usr/local/bin
PATH: /usr/sbin
PATH: /usr/bin
PATH: /sbin
PATH: /bin
PATH: /usr/bin/X11

## ----------- ##
## Core tests. ##
## ----------- ##

configure:1372: checking for a BSD-compatible install
configure:1427: result: /usr/bin/install -c
configure:1438: checking whether build environment is sane
configure:1481: result: yes
configure:1546: checking for gawk
configure:1575: result: no
configure:1546: checking for mawk
configure:1562: found /usr/bin/mawk
configure:1572: result: mawk
configure:1582: checking whether make sets $(MAKE)
configure:1602: result: yes
configure:1779: checking build system type
configure:1797: result: i686-pc-linux-gnulibc1
configure:1805: checking host system type
configure:1819: result: i686-pc-linux-gnulibc1
configure:1898: checking for gcc
configure:1914: found /usr/bin/gcc
configure:1924: result: gcc
configure:2168: checking for C compiler version
configure:2171: gcc --version </dev/null >&5
gcc (GCC) 3.3.4 (Debian 1:3.3.4-13)
Copyright (C) 2003 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

configure:2174: $? = 0
configure:2176: gcc -v </dev/null >&5
Reading specs from /usr/lib/gcc-lib/i486-linux/3.3.4/specs
Configured with: ../src/configure -v --enable-languages=c,c++,java,f77,pascal,objc,ada,treelang --prefix=/usr --mandir=/usr/share/man --infodir=/usr/share/info --with-gxx-include-dir=/usr/include/c++/3.3 --enable-shared --with-system-zlib --enable-nls --without-included-gettext --enable-__cxa_atexit --enable-clocale=gnu --enable-debug --enable-java-gc=boehm --enable-java-awt=xlib --enable-objc-gc i486-linux
Thread model: posix
gcc version 3.3.4 (Debian 1:3.3.4-13)
configure:2179: $? = 0
configure:2181: gcc -V </dev/null >&5
gcc: `-V' option must have argument
configure:2184: $? = 1
configure:2207: checking for C compiler default output file name
configure:2210: gcc conftest.c >&5
/usr/bin/ld: crt1.o: No such file: No such file or directory
collect2: ld returned 1 exit status
configure:2213: $? = 1
configure: failed program was:
| /* confdefs.h. */
|
| #define PACKAGE_NAME "moon-buggy"
| #define PACKAGE_TARNAME "moon-buggy"
| #define PACKAGE_VERSION "1.0"
| #define PACKAGE_STRING "moon-buggy 1.0"
| #define PACKAGE_BUGREPORT "voss@seehuhn.de"
| #define PACKAGE "moon-buggy"
| #define VERSION "1.0"
| #define _XOPEN_SOURCE 1
| /* end confdefs.h. */
|
| int
| main ()
| {
|
| ;
| return 0;
| }
configure:2252: error: C compiler cannot create executables
See `config.log' for more details.

## ---------------- ##
## Cache variables. ##
## ---------------- ##

ac_cv_build=i686-pc-linux-gnulibc1
ac_cv_build_alias=i686-pc-linux-gnulibc1
ac_cv_env_CC_set=
ac_cv_env_CC_value=
ac_cv_env_CFLAGS_set=
ac_cv_env_CFLAGS_value=
ac_cv_env_CPPFLAGS_set=
ac_cv_env_CPPFLAGS_value=
ac_cv_env_CPP_set=
ac_cv_env_CPP_value=
ac_cv_env_LDFLAGS_set=
ac_cv_env_LDFLAGS_value=
ac_cv_env_build_alias_set=
ac_cv_env_build_alias_value=
ac_cv_env_host_alias_set=
ac_cv_env_host_alias_value=
ac_cv_env_target_alias_set=
ac_cv_env_target_alias_value=
ac_cv_host=i686-pc-linux-gnulibc1
ac_cv_host_alias=i686-pc-linux-gnulibc1
ac_cv_path_install='/usr/bin/install -c'
ac_cv_prog_AWK=mawk
ac_cv_prog_ac_ct_CC=gcc
ac_cv_prog_make_make_set=yes

## ----------------- ##
## Output variables. ##
## ----------------- ##

ACLOCAL='${SHELL} /root/moon-buggy-1.0/missing --run aclocal-1.9'
AMDEPBACKSLASH=''
AMDEP_FALSE=''
AMDEP_TRUE=''
AMTAR='${SHELL} /root/moon-buggy-1.0/missing --run tar'
AUTOCONF='${SHELL} /root/moon-buggy-1.0/missing --run autoconf'
AUTOHEADER='${SHELL} /root/moon-buggy-1.0/missing --run autoheader'
AUTOMAKE='${SHELL} /root/moon-buggy-1.0/missing --run automake-1.9'
AWK='mawk'
CC='gcc'
CCDEPMODE=''
CFLAGS=''
CPP=''
CPPFLAGS=''
CURSES_INCLUDEDIR=''
CURSES_LIBS=''
CYGPATH_W='echo'
DEFS=''
DEPDIR=''
ECHO_C=''
ECHO_N='-n'
ECHO_T=''
EGREP=''
EXEEXT=''
GAMEGROUP=''
INSTALL_DATA='${INSTALL} -m 644'
INSTALL_PROGRAM='${INSTALL}'
INSTALL_SCRIPT='${INSTALL}'
INSTALL_STRIP_PROGRAM='${SHELL} $(install_sh) -c -s'
LDFLAGS=''
LIBOBJS=''
LIBS=''
LTLIBOBJS=''
MAKEINFO='${SHELL} /root/moon-buggy-1.0/missing --run makeinfo'
OBJEXT=''
PACKAGE='moon-buggy'
PACKAGE_BUGREPORT='voss@seehuhn.de'
PACKAGE_NAME='moon-buggy'
PACKAGE_STRING='moon-buggy 1.0'
PACKAGE_TARNAME='moon-buggy'
PACKAGE_VERSION='1.0'
PATH_SEPARATOR=':'
SET_MAKE=''
SHELL='/bin/sh'
STRIP=''
VERSION='1.0'
ac_ct_CC='gcc'
ac_ct_STRIP=''
am__fastdepCC_FALSE=''
am__fastdepCC_TRUE=''
am__include=''
am__leading_dot='.'
am__quote=''
am__tar='${AMTAR} chof - "$$tardir"'
am__untar='${AMTAR} xf -'
bindir='${exec_prefix}/bin'
build='i686-pc-linux-gnulibc1'
build_alias=''
build_cpu='i686'
build_os='linux-gnulibc1'
build_vendor='pc'
datadir='${prefix}/share'
exec_prefix='NONE'
host='i686-pc-linux-gnulibc1'
host_alias=''
host_cpu='i686'
host_os='linux-gnulibc1'
host_vendor='pc'
includedir='${prefix}/include'
infodir='${prefix}/info'
install_sh='/root/moon-buggy-1.0/install-sh'
libdir='${exec_prefix}/lib'
libexecdir='${exec_prefix}/libexec'
localstatedir='${prefix}/var'
mandir='${prefix}/man'
mkdir_p='mkdir -p --'
oldincludedir='/usr/include'
prefix='NONE'
program_transform_name='s,x,x,'
sbindir='${exec_prefix}/sbin'
sharedstatedir='${prefix}/com'
short_getopt_FALSE=''
short_getopt_TRUE=''
sysconfdir='${prefix}/etc'
target_alias=''

## ----------- ##
## confdefs.h. ##
## ----------- ##

#define PACKAGE "moon-buggy"
#define PACKAGE_BUGREPORT "voss@seehuhn.de"
#define PACKAGE_NAME "moon-buggy"
#define PACKAGE_STRING "moon-buggy 1.0"
#define PACKAGE_TARNAME "moon-buggy"
#define PACKAGE_VERSION "1.0"
#define VERSION "1.0"
#define _XOPEN_SOURCE 1

configure: exit 77

Vad är fel?

Visa signatur

iBook G4 1.33GHz, 1024 MB, 40GB + 160, Mac OS X 10.4

Permalänk
Medlem

Prova att installera paketet g++ också.

# apt-get install g++

Permalänk
Medlem

Nu kom den lite längre, men lyckades ändå inte helt :/

debian:~/moon-buggy-1.0# ./configure
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for gawk... no
checking for mawk... mawk
checking whether make sets $(MAKE)... yes
checking build system type... i686-pc-linux-gnu
checking host system type... i686-pc-linux-gnu
checking for gcc... gcc
checking for C compiler default output file name... a.out
checking whether the C compiler works... yes
checking whether we are cross compiling... no
checking for suffix of executables...
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ANSI C... none needed
checking for style of include used by make... GNU
checking dependency style of gcc... gcc3
checking for modf in -lm... yes
checking how to run the C preprocessor... gcc -E
checking for egrep... grep -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking for curses preprocessor flags... none
checking curses.h usability... no
checking curses.h presence... no
checking for curses.h... no
checking ncurses.h usability... no
checking ncurses.h presence... no
checking for ncurses.h... no
checking ncurses/ncurses.h usability... no
checking ncurses/ncurses.h presence... no
checking for ncurses/ncurses.h... no
checking ncurses/curses.h usability... no
checking ncurses/curses.h presence... no
checking for ncurses/curses.h... no
checking how to include the curses header file... unknown
configure: WARNING: no curses header found, try --with-curses-header
checking for initscr in -lcurses... no
checking for initscr in -lncurses... no
checking for curses linker flags... unknown
configure: WARNING: curses library not found, try --with-curses-libs
checking for ANSI C header files... (cached) yes
checking getopt.h usability... yes
checking getopt.h presence... yes
checking for getopt.h... yes
checking errno.h usability... yes
checking errno.h presence... yes
checking for errno.h... yes
checking locale.h usability... yes
checking locale.h presence... yes
checking for locale.h... yes
checking termios.h usability... yes
checking termios.h presence... yes
checking for termios.h... yes
checking for fd_set... yes, found in sys/select.h
checking for an ANSI C-conforming const... yes
checking for uid_t in sys/types.h... yes
checking for size_t... yes
checking return type of signal handlers... void
checking for fclean... no
checking for ftruncate... yes
checking for getopt_long... yes
checking for setreuid... yes
checking for setlocale... yes
configure: creating ./config.status
config.status: creating Makefile
config.status: creating config.h
config.status: config.h is unchanged
config.status: executing depfiles commands

sen när jag körde make:

debian:~/moon-buggy-1.0# make
make all-am
make[1]: Entering directory `/root/moon-buggy-1.0'
if gcc -DHAVE_CONFIG_H -I. -I. -I. -g -O2 -MT main.o -MD -MP -MF ".deps/main.Tpo" -c -o main.o main.c; \
then mv -f ".deps/main.Tpo" ".deps/main.Po"; else rm -f ".deps/main.Tpo"; exit 1; fi
I fil inkluderad från main.c:24:
moon-buggy.h:20:23: curses.h: Filen eller katalogen finns inte
In file included from main.c:24:
moon-buggy.h:28: error: parsningsfel before '*' token
moon-buggy.h:28: varning: data definition has no type or storage class
main.c:30: error: parsningsfel before '*' token
main.c:30: varning: data definition has no type or storage class
main.c: I funktion `print_hint':
main.c:54: error: `COLS' undeclared (first use in this function)
main.c:54: error: (Each undeclared identifier is reported only once
main.c:54: error: for each function it appears in.)
main.c:62: error: `LINES' undeclared (first use in this function)
main.c: I funktion `allocate_windows':
main.c:103: error: `LINES' undeclared (first use in this function)
main.c:103: varning: tilldelning skapar pekare från heltal utan typkonvertering
main.c:104: error: `TRUE' undeclared (first use in this function)
main.c:105: error: `FALSE' undeclared (first use in this function)
main.c:107: varning: tilldelning skapar pekare från heltal utan typkonvertering
main.c:111: varning: tilldelning skapar pekare från heltal utan typkonvertering
make[1]: *** [main.o] Fel 1
make[1]: Leaving directory `/root/moon-buggy-1.0'
make: *** [all] Fel 2

verkar ha nåt med curses att göra, men jag vet inte vad jag ska skaffa för att få det att funka..

Visa signatur

iBook G4 1.33GHz, 1024 MB, 40GB + 160, Mac OS X 10.4

Permalänk
Medlem

Du har nog inte ncurses-dev installerat.
apt-get install ncurses-dev

Permalänk
Medlem

Tack! nu funkar det!

Visa signatur

iBook G4 1.33GHz, 1024 MB, 40GB + 160, Mac OS X 10.4