انجمن‌های فارسی اوبونتو

کمک و پشتیبانی => نصب، راه‌اندازی و بروزآوری => نویسنده: emab در 22 اسفند 1388، 07:26 ب‌ظ

عنوان: [حل شد] پیام خطا در نصب برنامه از روی سورس
ارسال شده توسط: emab در 22 اسفند 1388، 07:26 ب‌ظ
سلام
من سه تا برنامه به اسم های dxf2g و ace و hp2xx رو خواستم از روی سورس نصب کنم، اما بعد از زدن دستور make با خطاهای زیر مواجه شدم. کسی می تونه کمک کنه؟ برای پروژه لازم دارم ممنون میشم کسی کمک کنه!
build-essentials رو هم نصب کردم!!!

dxf2g
omid@omid-laptop:~$ cd dxf2G-1.0.4/
omid@omid-laptop:~/dxf2G-1.0.4$ make
gcc -o dxf2G -v -g -lm  -Wall   dxf2G.c
Using built-in specs.
Target: i486-linux-gnu
Configured with: ../src/configure -v --with-pkgversion='Ubuntu 4.4.1-4ubuntu9' --with-bugurl=file:///usr/share/doc/gcc-4.4/README.Bugs --enable-languages=c,c++,fortran,objc,obj-c++ --prefix=/usr --enable-shared --enable-multiarch --enable-linker-build-id --with-system-zlib --libexecdir=/usr/lib --without-included-gettext --enable-threads=posix --with-gxx-include-dir=/usr/include/c++/4.4 --program-suffix=-4.4 --enable-nls --enable-clocale=gnu --enable-libstdcxx-debug --enable-objc-gc --enable-targets=all --disable-werror --with-arch-32=i486 --with-tune=generic --enable-checking=release --build=i486-linux-gnu --host=i486-linux-gnu --target=i486-linux-gnu
Thread model: posix
gcc version 4.4.1 (Ubuntu 4.4.1-4ubuntu9)
COLLECT_GCC_OPTIONS='-o' 'dxf2G' '-v' '-g' '-Wall' '-mtune=generic' '-march=i486'
 /usr/lib/gcc/i486-linux-gnu/4.4.1/cc1 -quiet -v dxf2G.c -D_FORTIFY_SOURCE=2 -quiet -dumpbase dxf2G.c -mtune=generic -march=i486 -auxbase dxf2G -g -Wall -version -fstack-protector -o /tmp/ccUg2S8S.s
ignoring nonexistent directory "/usr/local/include/i486-linux-gnu"
ignoring nonexistent directory "/usr/lib/gcc/i486-linux-gnu/4.4.1/../../../../i486-linux-gnu/include"
ignoring nonexistent directory "/usr/include/i486-linux-gnu"
#include "..." search starts here:
#include <...> search starts here:
 /usr/local/include
 /usr/lib/gcc/i486-linux-gnu/4.4.1/include
 /usr/lib/gcc/i486-linux-gnu/4.4.1/include-fixed
 /usr/include
End of search list.
GNU C (Ubuntu 4.4.1-4ubuntu9) version 4.4.1 (i486-linux-gnu)
compiled by GNU C version 4.4.1, GMP version 4.3.1, MPFR version 2.4.1-p2.
GGC heuristics: --param ggc-min-expand=97 --param ggc-min-heapsize=127109
Compiler executable checksum: 8f30a5fdc2c06e07cc337ee4c8f69ccf
dxf2G.c:91: error: conflicting types for ‘round’
dxf2G.c: In function ‘main’:
dxf2G.c:253: warning: assignment makes integer from pointer without a cast
dxf2G.c: In function ‘crea_file_ordinato’:
dxf2G.c:565: warning: passing argument 1 of ‘scanf’ from incompatible pointer type
/usr/include/stdio.h:428: note: expected ‘const char * __restrict__’ but argument is of type ‘struct FILE *’
dxf2G.c:578: warning: implicit declaration of function ‘fcloseall’
dxf2G.c: In function ‘taglia’:
dxf2G.c:1263: warning: assignment makes integer from pointer without a cast
dxf2G.c:1268: warning: assignment makes integer from pointer without a cast
dxf2G.c:1251: warning: unused variable ‘tasto’
dxf2G.c: At top level:
dxf2G.c:1415: error: conflicting types for ‘round’
dxf2G.c: In function ‘print_screen’:
dxf2G.c:2472: warning: assignment makes integer from pointer without a cast
make: *** [dxf2G] Error 1

hp2xx
omid@omid-laptop:~/hp2xx-3.4.4$ make
cd sources; make
make[1]: Entering directory `/home/omid/hp2xx-3.4.4/sources'
gcc -O2 -g -I/usr/X11R6/include -DUNIX -DHAS_UNIX_X11   -DEPSON -DPNG -DTIF -DJPG -Wall -pedantic -Wuninitialized -Wunused -Wreturn-type -Wmissing-prototypes -Wstrict-prototypes   -I.              -c -o to_x11.o to_x11.c
to_x11.c:47:22: error: X11/Xlib.h: No such file or directory
to_x11.c:48:23: error: X11/Xutil.h: No such file or directory
to_x11.c:66: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘*’ token
to_x11.c:68: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘XRoot’
to_x11.c:69: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘*’ token
to_x11.c:71: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘XGcWin’
to_x11.c:72: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘XWin’
to_x11.c:75: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘Xcol’
to_x11.c:76: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘def_clut’
to_x11.c:94: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘WaitEvent’
to_x11.c: In function ‘win_open’:
to_x11.c:109: error: ‘XSizeHints’ undeclared (first use in this function)
to_x11.c:109: error: (Each undeclared identifier is reported only once
to_x11.c:109: error: for each function it appears in.)
to_x11.c:109: error: expected ‘;’ before ‘Hints’
to_x11.c:110: warning: ISO C90 forbids mixed declarations and code
to_x11.c:111: error: ‘XSetWindowAttributes’ undeclared (first use in this function)
to_x11.c:111: error: expected ‘;’ before ‘WinAttr’
to_x11.c:112: error: ‘XEvent’ undeclared (first use in this function)
to_x11.c:112: error: expected ‘;’ before ‘Event’
to_x11.c:113: warning: ISO C90 forbids mixed declarations and code
to_x11.c:129: error: ‘XDisplay’ undeclared (first use in this function)
to_x11.c:129: error: ‘Display’ undeclared (first use in this function)
to_x11.c:129: error: expected expression before ‘)’ token
to_x11.c:136: warning: implicit declaration of function ‘DefaultScreen’
to_x11.c:137: error: ‘XRoot’ undeclared (first use in this function)
to_x11.c:137: warning: implicit declaration of function ‘RootWindow’
to_x11.c:138: error: ‘XVisual’ undeclared (first use in this function)
to_x11.c:138: warning: implicit declaration of function ‘DefaultVisual’
to_x11.c:139: error: ‘XGcWin’ undeclared (first use in this function)
to_x11.c:139: warning: implicit declaration of function ‘DefaultGC’
to_x11.c:141: warning: implicit declaration of function ‘WidthOfScreen’
to_x11.c:141: warning: implicit declaration of function ‘ScreenOfDisplay’
to_x11.c:142: warning: implicit declaration of function ‘HeightOfScreen’
to_x11.c:157: error: ‘WinAttr’ undeclared (first use in this function)
to_x11.c:157: warning: implicit declaration of function ‘WhitePixel’
to_x11.c:159: error: ‘Always’ undeclared (first use in this function)
to_x11.c:161: error: ‘CWBackPixel’ undeclared (first use in this function)
to_x11.c:161: error: ‘CWBorderPixel’ undeclared (first use in this function)
to_x11.c:161: error: ‘CWBackingStore’ undeclared (first use in this function)
to_x11.c:167: error: ‘XWin’ undeclared (first use in this function)
to_x11.c:167: warning: implicit declaration of function ‘XCreateWindow’
to_x11.c:170: error: ‘CopyFromParent’ undeclared (first use in this function)
to_x11.c:170: error: ‘Visual’ undeclared (first use in this function)
to_x11.c:170: error: expected expression before ‘)’ token
to_x11.c:177: error: ‘Hints’ undeclared (first use in this function)
to_x11.c:177: error: ‘PSize’ undeclared (first use in this function)
to_x11.c:177: error: ‘PMinSize’ undeclared (first use in this function)
to_x11.c:177: error: ‘PMaxSize’ undeclared (first use in this function)
to_x11.c:177: error: ‘USPosition’ undeclared (first use in this function)
to_x11.c:183: warning: implicit declaration of function ‘XSetStandardProperties’
to_x11.c:190: error: ‘def_clut’ undeclared (first use in this function)
to_x11.c:190: warning: implicit declaration of function ‘DefaultColormap’
to_x11.c:191: warning: implicit declaration of function ‘DefaultDepth’
to_x11.c:193: warning: implicit declaration of function ‘BlackPixel’
to_x11.c:208: warning: implicit declaration of function ‘XParseColor’
to_x11.c:208: error: ‘Xcol’ undeclared (first use in this function)
to_x11.c:209: warning: implicit declaration of function ‘XAllocColor’
to_x11.c:236: warning: implicit declaration of function ‘XSetState’
to_x11.c:237: error: ‘GXcopy’ undeclared (first use in this function)
to_x11.c:237: error: ‘AllPlanes’ undeclared (first use in this function)
to_x11.c:243: warning: implicit declaration of function ‘XSelectInput’
to_x11.c:244: error: ‘ExposureMask’ undeclared (first use in this function)
to_x11.c:244: error: ‘KeyPressMask’ undeclared (first use in this function)
to_x11.c:244: error: ‘VisibilityChangeMask’ undeclared (first use in this function)
to_x11.c:245: error: ‘ButtonPressMask’ undeclared (first use in this function)
to_x11.c:245: error: ‘ButtonReleaseMask’ undeclared (first use in this function)
to_x11.c:250: warning: implicit declaration of function ‘XMapWindow’
to_x11.c:252: warning: implicit declaration of function ‘XNextEvent’
to_x11.c:252: error: ‘Event’ undeclared (first use in this function)
to_x11.c:254: error: ‘Expose’ undeclared (first use in this function)
to_x11.c:254: error: ‘VisibilityNotify’ undeclared (first use in this function)
to_x11.c:107: warning: unused variable ‘DisplayName’
to_x11.c: In function ‘win_close’:
to_x11.c:269: warning: implicit declaration of function ‘XDestroyWindow’
to_x11.c:269: error: ‘XDisplay’ undeclared (first use in this function)
to_x11.c:269: error: ‘XWin’ undeclared (first use in this function)
to_x11.c:270: warning: implicit declaration of function ‘XCloseDisplay’
to_x11.c: In function ‘PicBuf_to_X11’:
to_x11.c:321: warning: implicit declaration of function ‘XSetForeground’
to_x11.c:321: error: ‘XDisplay’ undeclared (first use in this function)
to_x11.c:321: error: ‘XGcWin’ undeclared (first use in this function)
to_x11.c:335: warning: implicit declaration of function ‘XDrawPoint’
to_x11.c:335: error: ‘XWin’ undeclared (first use in this function)
to_x11.c:342: error: ‘WaitEvent’ undeclared (first use in this function)
to_x11.c:343: error: ‘ButtonPress’ undeclared (first use in this function)
to_x11.c:344: error: ‘Button1’ undeclared (first use in this function)
to_x11.c:348: error: ‘Button2’ undeclared (first use in this function)
to_x11.c:384: error: ‘Button3’ undeclared (first use in this function)
to_x11.c:388: error: ‘ButtonRelease’ undeclared (first use in this function)
to_x11.c:399: warning: implicit declaration of function ‘XFillRectangle’
to_x11.c:417: error: ‘KeyPress’ undeclared (first use in this function)
make[1]: *** [to_x11.o] Error 1
make[1]: Leaving directory `/home/omid/hp2xx-3.4.4/sources'
make: *** [all] Error 2


ace
omid@omid-laptop:~/ACE V4.0 beta/Source$ make
make: *** No targets specified and no makefile found.  Stop.

با تشکر
عنوان: پاسخ به: پیام خطا در نصب برنامه از روی سورس
ارسال شده توسط: علی قنواتیان در 22 اسفند 1388، 08:27 ب‌ظ
سلام هموطن؛
احتمالا مشکل این برنامه‌تون این هستش که از تابع round که در کتابخانه رزرو شده استفاده می‌کنه. من سورسش رو دستکاری کردم و تابع round رو با the_round عوض کردم و ظاهرا مشکلش حل شد.

این لینک بسته‌ی اصلاح شده هستش:
http://dark-sun303.persiangig.com/dx2fG/dxf2G-1.0.4%28beta%20fix%29.tar.gz (http://dark-sun303.persiangig.com/dx2fG/dxf2G-1.0.4%28beta%20fix%29.tar.gz)

با همین روشی که اینجا نوشتین پیش برین، ایشالله جواب می‌ده
 ;)

- راستی اگه مشکل برطرف شد، یادتون نره یک (حل شد) به عنوان تاپیک اضافه کنین.
عنوان: پاسخ به: پیام خطا در نصب برنامه از روی سورس
ارسال شده توسط: emab در 23 اسفند 1388، 09:50 ق‌ظ
 \\:D/
ممنون، دقیقا مشکلش همین بود و حل شد.
دستتون درد نکنه!
من فکر کنم بد نیست به عنوان باگ به نویسندگان کدش گزارش بدیم، نظرتون چیه؟
عنوان: پاسخ به: [حل شد] پیام خطا در نصب برنامه از روی سورس
ارسال شده توسط: علی قنواتیان در 23 اسفند 1388، 08:14 ب‌ظ
ای ول! خوشحال شدم هموطن  8)
فکر بدی نیست... مطمئن نبودم که مشکل اینجوری حل می‌شه. خب حالا که دو نفر شدیم زورمون بیشتره
 ;)
من بهشون ایمیل زدم، ولی همونطور که دیدی سایتشون خیلی داغونه! فقط امیدوارم هنوز توسعه‌ش بدن
 ;)