Установка tar.gz?

Форум предназначен для новичков. В нем предполагается рассматривать вопросы, которые встают на первых этапах освоения Linux
Аватара пользователя
Llama
Неотъемлемая часть форума
Сообщения: 9749
Зарегистрирован: 06 фев 2002, 11:40
Откуда: Менск

Сообщение Llama »

Al, ну значит данная программа компилируется иным образом, читаем README или INSTALL
Опыт растет прямо пропорционально выведенному из строя оборудованию

Al
Интересующийся
Сообщения: 45
Зарегистрирован: 22 май 2006, 13:29

Сообщение Al »

Llama писал(а):Al, ну значит данная программа компилируется иным образом, читаем README или INSTALL
Написано, что:
./configure
make
make install
The install is quite simple, so that currently there is no automatic install.

#*#*#*#*#*#
#*# 1 #*#
extract the archive, what you apparently already did ;-)

#*#*#*#*#*#
#*# 2 #*#
you need the source of your current running kernel.
/lib/modules/`uname -r`/build/include needs to point at it. if you're not sure if it points
to the righ kernel just type: ls -la /lib/modules/`uname -r`/build if its the correct kernel
source all is ok. ;-)

#*#*#*#*#*#
#*# 3 #*#
make

Depending on your config of the gcc, you get non or many warnings, but even if you get
some, only one is in the cdemu module. e.g. on a Suse 8.2 with the suse standard kernel source
extracted to /usr/src/linux/ (/lib/modules/`uname -r`/build/ points to that) it looks this way.

************************************************************
In file included from /usr/src/linux/include/linux/tqueue.h:19,
from /usr/src/linux/include/linux/aio.h:4,
from /usr/src/linux/include/linux/fs.h:201,
from /usr/src/linux/include/linux/capability.h:17,
from /usr/src/linux/include/linux/binfmts.h:5,
from /usr/src/linux/include/linux/sched.h:10,
from cdemu.c:68:
/usr/src/linux/include/asm/system.h: In function `__set_64bit_var':
/usr/src/linux/include/asm/system.h:189: warning: dereferencing type-punned pointer will break strict-aliasing rules
/usr/src/linux/include/asm/system.h:189: warning: dereferencing type-punned pointer will break strict-aliasing rules
In file included from cdemu.c:70:
/usr/src/linux/include/linux/file.h: In function `fcheck_files':
/usr/src/linux/include/linux/file.h:37: warning: comparison between signed and unsigned
/usr/src/linux/include/linux/file.h: In function `fcheck':
/usr/src/linux/include/linux/file.h:50: warning: comparison between signed and unsigned
/usr/src/linux/include/linux/file.h: In function `__put_unused_fd':
/usr/src/linux/include/linux/file.h:62: warning: comparison between signed and unsigned
In file included from /usr/src/linux/include/linux/blk.h:4,
from cdemu.c:75:
/usr/src/linux/include/linux/blkdev.h: In function `blk_queue_bounce':
/usr/src/linux/include/linux/blkdev.h:212: warning: comparison between signed and unsigned
/usr/src/linux/include/linux/blkdev.h: In function `blk_finished_io':
/usr/src/linux/include/linux/blkdev.h:348: warning: comparison between signed and unsigned
cdemu.c: In function `ce_findtrack':
cdemu.c:241: warning: comparison between signed and unsigned

************************************************************

if you get an error message (not a warning) like

cdemu.c: In function `ce_transfer':
cdemu.c:***: too few arguments to function `do_generic_file_read'

you most likely have a new redhat kernel.

you just need to change one line in the module source

search for this 2 lines
do_generic_file_read(vc->vc_backing_file, &position,
&desc, vc_read_actor);

and add a ",0" to the second line
&desc, vc_read_actor, 0);


and as root

#*#*#*#*#*#
#*# 4 #*#
make install

#*#*#*#*#*#
#*# 5 #*#
now we can load the kernel module just with typing

modprobe cdemu

no message should be given by this command

for you Debian users (maybe others), you might have to run `update-modules` first

#*#*#*#*#*#
#*# 6 #*#
after the install you just need to call cdemu to get the help screen of the userspace program

if you're using devfs, then nodes will show up in /dev/cdemu/ automagically. if you're using
udev, you might want to add this to /etc/udev/rules.d/99cdemu:
KERNEL="cdemu[0-9]*", NAME="cdemu/%n"
otherwise you'll get a bunch of nodes showing up in /dev/ instead of /dev/cdemu/

ps: Any bug reports, comments, feature requests wished.
Suse 10.1

sergei_d
Неотъемлемая часть форума
Сообщения: 222
Зарегистрирован: 05 авг 2004, 21:26

Сообщение sergei_d »

Al писал(а): Другой пример - cdemu. ./configure, make, make install не работают:
Так тут вроде и нету configure, судя по картинке? В таком случае, читаем файлы INSTALL, README.

Configure -- это не системная команда, а скрипт в каталоге с исходниками программы. Если его нету, то сборка осуществляется как-то по-другому.

Makefile там есть, значит, make должен работать, если всё в нём правильно.

Аватара пользователя
Mr. Anderson
Неотъемлемая часть форума
Сообщения: 373
Зарегистрирован: 10 окт 2005, 14:35

Сообщение Mr. Anderson »

ну и где там присутствует ./configure-make-make install? по-моему, все описано шаг за шагом. а tar.gz - это не тип, программ, а просто архив, упакованный архиваторами tar и gzip...
LMD / DML

Аватара пользователя
phaoost
Неотъемлемая часть форума
Сообщения: 289
Зарегистрирован: 12 янв 2005, 01:22
Откуда: Minsk
Контактная информация:

Сообщение phaoost »

Al, иногда конфигурационный скрипт может называться по-другому (bootstrap, setup, etc.) - его задача сгенерить Makefile. без успешной генерации make не заработает. в пакете есть документация - README, INSTALL, иногда тоже по-другому (например, Build) - там как правило даются инструкции по сборке. иногда даже просто Makefile идёт и его нужно поправить самому ручками под конкретный дистрибутив.
cheers,
phaoost.

Аватара пользователя
red f0x
Неотъемлемая часть форума
Сообщения: 338
Зарегистрирован: 08 мар 2004, 01:41

Сообщение red f0x »

phaoost писал(а):bootstrap, setup, etc.
bootstrap в GNU-autotools - как правило, создаёт симлинки на нек-е файлы (стандартные текстовики и скриптики, configure из configure.in, если память мне не изменяет с кем-то - прямо сейчас нет возможности проверить)... А Makefile по-любому генерируется из темплейта Makefile.in через configure.
Ну какая работа со строками может быть в языке, название которого является не строкой, а символом? (c) Sergue E. Leontiev

Ответить