Автор Тема: Вопрос по правильному написанию спеков  (Прочитано 14831 раз)

ALtNovice

  • Гость
buildreq -bi qxplayer.spec         
Выполняется(%prep): /bin/sh -e /home/kostya_hm/tmp/rpm-tmp.68951       
+ umask 022                                                           
+ /bin/mkdir -p /home/kostya_hm/RPM/BUILD                             
+ cd /home/kostya_hm/RPM/BUILD                                         
+ cd /home/kostya_hm/RPM/BUILD                                         
+ rm -rf qxplayer-0.5.4                                               
+ echo 'Source #0 (qxplayer-0.5.4.tar.bz2):'                           
Source #0 (qxplayer-0.5.4.tar.bz2):                                   
+ /bin/tar -xf -                                                       
+ /bin/gzip -dc /home/kostya_hm/RPM/SOURCES/qxplayer-0.5.4.tar.bz2     
+ cd qxplayer-0.5.4                                                   
+ /bin/chmod -c -Rf u+rwX,go-w .                                       
+ exit 0                                                               
Выполняется(%build): /bin/sh -e /home/kostya_hm/tmp/rpm-tmp.68951     
+ umask 022                                                           
+ /bin/mkdir -p /home/kostya_hm/RPM/BUILD                             
+ cd /home/kostya_hm/RPM/BUILD                                         
+ cd qxplayer-0.5.4                                                   
+ qmake-qt4 'QMAKE_CFLAGS+=-pipe -Wall -O2 -march=athlon -mtune=athlon-xp' 'QMAKE_CXXFLAGS+=-pipe -Wall -O2 -march=athlon -mtune=athlon-xp' qxplayer.pro                                                                                               
+ '[' -n '' ']'                                                                                                             
+ NPROCS=1                                                                                                                 
+ make -j1                                                                                                                 
make: Entering directory `/home/kostya_hm/RPM/BUILD/qxplayer-0.5.4'                                                         
/usr/lib/qt4/bin/uic mainimpl.ui -o build/ui/ui_mainimpl.h                                                                 
/usr/lib/qt4/bin/uic playlist.ui -o build/ui/ui_playlist.h                                                                 
/usr/lib/qt4/bin/uic metainfo.ui -o build/ui/ui_metainfo.h                                                                 
/usr/lib/qt4/bin/uic about.ui -o build/ui/ui_about.h                                                                       
/usr/lib/qt4/bin/uic eq.ui -o build/ui/ui_eq.h                                                                             
/usr/lib/qt4/bin/uic preference.ui -o build/ui/ui_preference.h                                                             
g++ -c -pipe -pipe -Wall -O2 -march=athlon -mtune=athlon-xp -Wall -W -D_REENTRANT -DQT_NO_DEBUG -DQT_GUI_LIB -DQT_NETWORK_LIB -DQT_CORE_LIB -I/usr/share/qt4/mkspecs/linux-g++ -I. -I/usr/include/qt4/QtCore -I/usr/include/qt4/QtCore -I/usr/include/qt4/QtNetwork -I/usr/include/qt4/QtNetwork -I/usr/include/qt4/QtGui -I/usr/include/qt4/QtGui -I/usr/include/qt4 -I/usr/include/taglib -Ibuild/moc -Ibuild/ui -o build/o/player.o src/player.cpp                                                           
In file included from src/player.cpp:21:                                                                                   
src/player.h:26:18: error: xine.h: No such file or directory                                                               
In file included from src/player.cpp:21:                                                                                   
src/player.h:97: error: ISO C++ forbids declaration of 'xine_t' with no type                                               
src/player.h:97: error: expected ';' before '*' token                                                                       
src/player.h:98: error: ISO C++ forbids declaration of 'xine_audio_port_t' with no type                                     
src/player.h:98: error: expected ';' before '*' token                                                                       
src/player.h:99: error: ISO C++ forbids declaration of 'xine_stream_t' with no type                                         
src/player.h:99: error: expected ';' before '*' token                                                                       
src/player.cpp: In constructor 'Player::Player(QObject*, QString)':                                                         
src/player.cpp:29: error: 'm_xine' was not declared in this scope                                                           
src/player.cpp:29: error: 'xine_new' was not declared in this scope                                                         
src/player.cpp:32: error: 'xine_init' was not declared in this scope                                                       
src/player.cpp:34: error: 'm_port' was not declared in this scope                                                           
src/player.cpp:34: error: 'xine_open_audio_driver' was not declared in this scope                                           
src/player.cpp:35: error: 'm_stream' was not declared in this scope                                                         
src/player.cpp:35: error: 'xine_stream_new' was not declared in this scope                                                 
src/player.cpp:38: error: 'XINE_PARAM_IGNORE_VIDEO' was not declared in this scope                                         
src/player.cpp:38: error: 'xine_set_param' was not declared in this scope                                                   
src/player.cpp: In destructor 'virtual Player::~Player()':                                                                 
src/player.cpp:46: error: 'm_stream' was not declared in this scope                                                         
src/player.cpp:46: error: 'XINE_PARAM_AUDIO_CLOSE_DEVICE' was not declared in this scope                                   
src/player.cpp:46: error: 'xine_set_param' was not declared in this scope                                                   
src/player.cpp:47: error: 'XINE_PARAM_AUDIO_MUTE' was not declared in this scope                                           
src/player.cpp:48: error: 'XINE_PARAM_AUDIO_VOLUME' was not declared in this scope                                         
src/player.cpp:49: error: 'xine_stop' was not declared in this scope                                                       
src/player.cpp:50: error: 'm_xine' was not declared in this scope                                                           
src/player.cpp:50: error: 'm_port' was not declared in this scope                                                           
src/player.cpp:50: error: 'xine_close_audio_driver' was not declared in this scope                                         
src/player.cpp:51: error: 'xine_exit' was not declared in this scope                                                       
src/player.cpp: In member function 'uint Player::pos()':                                                                   
src/player.cpp:60: error: 'm_stream' was not declared in this scope                                                         
src/player.cpp:60: error: 'xine_get_pos_length' was not declared in this scope                                             
src/player.cpp: In member function 'uint Player::length()':                                                                 
src/player.cpp:69: error: 'm_stream' was not declared in this scope                                                         
src/player.cpp:69: error: 'xine_get_pos_length' was not declared in this scope                                             
src/player.cpp: In member function 'bool Player::isRunning()':                                                             
src/player.cpp:75: error: 'm_stream' was not declared in this scope                                                         
src/player.cpp:75: error: 'xine_get_status' was not declared in this scope                                                 
src/player.cpp:75: error: 'XINE_STATUS_PLAY' was not declared in this scope                                                 
src/player.cpp:76: error: 'XINE_PARAM_SPEED' was not declared in this scope                                                 
src/player.cpp:76: error: 'xine_get_param' was not declared in this scope                                                   
src/player.cpp:76: error: 'XINE_SPEED_NORMAL' was not declared in this scope                                               
src/player.cpp: In member function 'bool Player::isPaused()':                                                               
src/player.cpp:83: error: 'm_stream' was not declared in this scope                                                         
src/player.cpp:83: error: 'xine_get_status' was not declared in this scope                                                 
src/player.cpp:83: error: 'XINE_STATUS_PLAY' was not declared in this scope                                                 
src/player.cpp:84: error: 'XINE_PARAM_SPEED' was not declared in this scope                                                 
src/player.cpp:84: error: 'xine_get_param' was not declared in this scope                                                   
src/player.cpp:84: error: 'XINE_SPEED_PAUSE' was not declared in this scope                                                 
src/player.cpp: In member function 'void Player::setOutputEngine(const QString&)':                                         
src/player.cpp:103: error: 'm_stream' was not declared in this scope                                                       
src/player.cpp:103: error: 'xine_stop' was not declared in this scope                                                       
src/player.cpp:104: error: 'm_xine' was not declared in this scope                                                         
src/player.cpp:104: error: 'm_port' was not declared in this scope                                                         
src/player.cpp:104: error: 'xine_close_audio_driver' was not declared in this scope                                         
src/player.cpp:105: error: 'xine_open_audio_driver' was not declared in this scope                                         
src/player.cpp:106: error: 'm_stream' was not declared in this scope                                                       
src/player.cpp:106: error: 'xine_stream_new' was not declared in this scope                                                 
src/player.cpp:107: error: 'XINE_PARAM_IGNORE_VIDEO' was not declared in this scope                                         
src/player.cpp:107: error: 'xine_set_param' was not declared in this scope                                                 
src/player.cpp: In member function 'void Player::setVol(int)':                                                             
src/player.cpp:115: error: 'm_stream' was not declared in this scope                                                       
src/player.cpp:115: error: 'XINE_PARAM_AUDIO_VOLUME' was not declared in this scope                                         
src/player.cpp:115: error: 'xine_set_param' was not declared in this scope                                                 
src/player.cpp:119: error: 'm_stream' was not declared in this scope                                                       
src/player.cpp:119: error: 'XINE_PARAM_AUDIO_VOLUME' was not declared in this scope                                         
src/player.cpp:119: error: 'xine_set_param' was not declared in this scope                                                 
src/player.cpp: In member function 'void Player::setPos(uint)':                                                             
src/player.cpp:126: error: 'm_stream' was not declared in this scope                                                       
src/player.cpp:126: error: 'xine_play' was not declared in this scope                                                       
src/player.cpp: In member function 'void Player::setTrack(const QString&)':                                                 
src/player.cpp:135: error: 'm_stream' was not declared in this scope                                                       
src/player.cpp:135: error: 'xine_open' was not declared in this scope                                                       
src/player.cpp: In member function 'void Player::play()':                                                                   
src/player.cpp:141: error: 'm_stream' was not declared in this scope                                                       
src/player.cpp:141: error: 'XINE_PARAM_SPEED' was not declared in this scope                                               
src/player.cpp:141: error: 'xine_get_param' was not declared in this scope                                                 
src/player.cpp:141: error: 'XINE_SPEED_PAUSE' was not declared in this scope                                               
src/player.cpp:143: error: 'XINE_SPEED_NORMAL' was not declared in this scope                                               
src/player.cpp:143: error: 'xine_set_param' was not declared in this scope                                                 
src/player.cpp:144: error: 'xine_play' was not declared in this scope                                                       
src/player.cpp:148: error: 'xine_play' was not declared in this scope                                                       
src/player.cpp: In member function 'void Player::stop()':                                                                   
src/player.cpp:153: error: 'm_stream' was not declared in this scope                                                       
src/player.cpp:153: error: 'XINE_PARAM_AUDIO_CLOSE_DEVICE' was not declared in this scope                                   
src/player.cpp:153: error: 'xine_set_param' was not declared in this scope                                                 
src/player.cpp:154: error: 'xine_stop' was not declared in this scope                                                       
src/player.cpp: In member function 'void Player::pause()':                                                                 
src/player.cpp:161: error: 'm_stream' was not declared in this scope                                                       
src/player.cpp:161: error: 'xine_get_status' was not declared in this scope                                                 
src/player.cpp:161: error: 'XINE_STATUS_PLAY' was not declared in this scope                                               
src/player.cpp:163: error: 'XINE_PARAM_SPEED' was not declared in this scope                                               
src/player.cpp:163: error: 'XINE_SPEED_PAUSE' was not declared in this scope                                               
src/player.cpp:163: error: 'xine_set_param' was not declared in this scope                                                 
src/player.cpp:164: error: 'XINE_PARAM_AUDIO_CLOSE_DEVICE' was not declared in this scope                                   
src/player.cpp: In member function 'void Player::mute()':                                                                   
src/player.cpp:173: error: 'm_stream' was not declared in this scope                                                       
src/player.cpp:173: error: 'XINE_PARAM_AUDIO_MUTE' was not declared in this scope                                           
src/player.cpp:173: error: 'xine_get_param' was not declared in this scope                                                 
src/player.cpp:176: error: 'xine_set_param' was not declared in this scope                                                 
src/player.cpp: In member function 'void Player::setEQ(int, int)':                                                         
src/player.cpp:189: error: 'm_stream' was not declared in this scope                                                       
src/player.cpp:189: error: 'XINE_PARAM_EQ_30HZ' was not declared in this scope                                             
src/player.cpp:189: error: 'xine_set_param' was not declared in this scope                                                 
src/player.cpp:192: error: 'XINE_PARAM_EQ_60HZ' was not declared in this scope                                             
src/player.cpp:195: error: 'XINE_PARAM_EQ_125HZ' was not declared in this scope                                             
src/player.cpp:198: error: 'XINE_PARAM_EQ_250HZ' was not declared in this scope                                             
src/player.cpp:201: error: 'XINE_PARAM_EQ_500HZ' was not declared in this scope                                             
src/player.cpp:204: error: 'XINE_PARAM_EQ_1000HZ' was not declared in this scope                                           
src/player.cpp:207: error: 'XINE_PARAM_EQ_2000HZ' was not declared in this scope                                           
src/player.cpp:210: error: 'XINE_PARAM_EQ_4000HZ' was not declared in this scope                                           
src/player.cpp:213: error: 'XINE_PARAM_EQ_8000HZ' was not declared in this scope                                           
src/player.cpp:216: error: 'XINE_PARAM_EQ_16000HZ' was not declared in this scope                                           
src/player.cpp: In member function 'void Player::setAMP(int)':                                                             
src/player.cpp:223: error: 'm_stream' was not declared in this scope
src/player.cpp:223: error: 'XINE_PARAM_AUDIO_AMP_LEVEL' was not declared in this scope
src/player.cpp:223: error: 'xine_set_param' was not declared in this scope
make: *** [build/o/player.o] Error 1
make: Leaving directory `/home/kostya_hm/RPM/BUILD/qxplayer-0.5.4'
ошибка: Неверный код возврата из /home/kostya_hm/tmp/rpm-tmp.68951 (%build)


Ошибки сборки пакетов:
    Неверный код возврата из /home/kostya_hm/tmp/rpm-tmp.68951 (%build)

полный вывод   buildreq -bi qxplayer.spec
« Последнее редактирование: 25.03.2009 22:19:45 от ALtNovice »

Drool

  • Гость
src/player.h:26:18: error: xine.h: No such file or directory

Нужны заголовочные файлы xine. Делаете
apt-cache search xine | grep devel
доустанавливаете нужное (это должна быть libxine-devel) и повторяем. Там не только она понадобится, но метод поиска нужного я указал.

ALtNovice

  • Гость
о_О

libtotem-pl-parser-devel-doc - Development documentation for Totem media player play list parser
xorg-xineramaproto-devel - X.org XineramaProto protocol headers
libXinerama-devel - The Xinerama Library and Header Files
libemotion-devel - emotion headers and development libraries
libtotem-pl-parser-devel - Development files for Totem media player play list parser
libxcb-devel - XCB Library and Header Files
libxine-devel - Заголовочные файлы для разработки под xine
xinetd-devel - Libraries and header files for developing xinetd-aware applications

make: Leaving directory `/home/kostya_hm/RPM/BUILD/qxplayer-0.5.4'
ошибка: Неверный код возврата из /home/kostya_hm/tmp/rpm-tmp.68951 (%build)
из-за этого получается?
« Последнее редактирование: 25.03.2009 22:29:54 от ALtNovice »

Drool

  • Гость
libxine-devel - Заголовочные файлы для разработки под xine

Ну дык, нужно ведь не только найти требуемое компилятору, но еще и установить его.

доустанавливаете нужное (это должна быть libxine-devel) и повторяем.

ALtNovice

  • Гость
Ещё один вопрос: как лучше формировать ярлыки?

Оффлайн ruslandh

  • Поспешай не торопясь !
  • Модератор глобальный
  • *****
  • Сообщений: 32 361
  • Учиться .... Телепатами не рождаются, ими ....
Ещё один вопрос: как лучше формировать ярлыки?
Что ?

ALtNovice

  • Гость
Ссылки на программу с расширением .desktop

Оффлайн ruslandh

  • Поспешай не торопясь !
  • Модератор глобальный
  • *****
  • Сообщений: 32 361
  • Учиться .... Телепатами не рождаются, ими ....

Drool

  • Гость
Для лоботомии прикладываю свой nosrc.rpm. Приходится переименовывать :) Интересно, а можно rpm добавить в список поддерживаемых?

Оффлайн ruslandh

  • Поспешай не торопясь !
  • Модератор глобальный
  • *****
  • Сообщений: 32 361
  • Учиться .... Телепатами не рождаются, ими ....

ALtNovice

  • Гость
Вот, что у меня получилось)

Drool

  • Гость
Вот, что у меня получилось)

Цитировать
%define      cname qxplayer
Это не нужно. Это было в спеке qutim, потому-что имя пакета и имя тарбола отличалось. Потому мантейнер и ввел переменную для имени тарбола. И дальше по тексту %cname не нужен, если есть %name.

Цитировать
mkdir -p %buildroot/%_bindir
cp bin/qxplayer %buildroot%_bindir/

Это можно заменить одной строчкой:
Цитировать
%__install -Dp -m0755 bin/%name %buildroot%_bindir/%name
Тем более, что сразу можно передать и атрибуты файла, в данном случае - 755. -Dp - создает каталоги на пути install-а.

Цитировать
mkdir -p %buildroot/%_datadir/%name
cp src/*.h %buildroot/%_datadir/%name/
cp src/*.cpp %buildroot/%_datadir/%name/
Зачем паковать это? Тем более что если и пакуются заголовочные файлы, то в подпакет %name-devel и совершенно в другой каталог.

Цитировать
cp images/{1downarrow.png,adddir.png,configure.png,kaboodleloop.png,pause.png,player_mute.png} %buildroot/%_iconsdir/
cp images/{player_start.png,remove.png,1uparrow.png,clbt.png,file.png,multimedia.png,player_bwd.png} %buildroot/%_iconsdir/
cp images/{player_pause.png,player_stop.png,save.png,about.png,clear.png,juk.png,open.png,player_end.png,player_play.png,play.png} %buildroot/%_iconsdir/

Зачем этот ужас? ;) Да еще и в %_iconsdir? Есть три каталога для иконки программы - %_miconsdir (16x16), %_niconsdir (32x32) и %_liconsdir (64x64). Вот туда и нужно класть исключительно пиктограмму программы в соответствии с размером.

Цитировать
%dir %_datadir/%name
...
%_datadir/%name/

Если уж объявили каталог принадлежащим данному пакету, то упаковку нужно нацелить потом не на него, а на его содержимое:
Цитировать
%_datadir/%name/*

Только напомню - в данном случае это не нужно в пакете.
Осталось добавить чейнчлог, удобно это делать с помощью скрипта add_changelog.

ALtNovice

  • Гость
Спасибо за комментарии. Буду исправляться) ;)

P.S по-моему Faq по теме разработка надо расширить

Вот ещё интересующий меня вопрос: .desktop файл надо делать отдельно патчем, как это сделано в qutim?
« Последнее редактирование: 26.03.2009 00:35:01 от ALtNovice »

Drool

  • Гость
Вот ещё интересующий меня вопрос: .desktop файл надо делать отдельно патчем, как это сделано в qutim?

Как угодно. Посмотрите спек от synkron.

Оффлайн ALtNovice

  • Участник
  • *
  • Сообщений: 121
Такая проблема:
checking for LUA... configure: error: Package requirements (lua5.1) were not met:
No package 'lua5.1' found

В альте этот пакет называется lua5, его версия 5.13.
Что нужно сделать, чтобы при сборке lua5 принимался за lua5.1?
Сессия сдана! Начался новый семестр...