Author Topic: [RESOLVED] Compiling Scribus1.5 on Debian Testing from the dedicated Ubuntu PPA  (Read 3524 times)

Danielsan

  • Newbie
  • *
  • Posts: 20
  • Karma: 0
  • Scribus User
Jump directly to the solution >>>



Hi All,

this is my first post, my name is Daniel and I considered myself a Scribus poweruser, as Scribus 1.5 is not yet available in Debian SID and neither in the EXPERIMENTAL repo I decided to compile it by myself but unfortunately I am blocked at the first step.

This is my error and I don't know how to resolve it:
Code: [Select]

cmake ../scribus -Wno-dev -DCMAKE_INSTALL_PREFIX:PATH=/usr/local/bin/
CMake Error at styles/CMakeLists.txt:21 (QT5_WRAP_CPP):
  Unknown CMake command "QT5_WRAP_CPP".


-- Configuring incomplete, errors occurred!
See also "/home/zagor/Compilati/scribus-1.5.0/builddir/CMakeFiles/CMakeOutput.log".
zagor@Debian-635:~/Compilati/scribus-1.5.0/builddir$ cmake ../scribus -Wno-dev -DCMAKE_INSTALL_PREFIX:PATH=/usr/local/bin/
CMake Error at styles/CMakeLists.txt:21 (QT5_WRAP_CPP):
  Unknown CMake command "QT5_WRAP_CPP".


-- Configuring incomplete, errors occurred!

However there's none: styles/CMakeLists.txt.

Attached the output log, thanks!
« Last Edit: October 23, 2015, 09:45:56 pm by Danielsan »

a.l.e

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 1296
  • Karma: 19
    • the graphics lab
Re: Issue Compiling Scribus 1.5 src on Debian Testing (Stretch)
« Reply #1 on: October 18, 2015, 10:29:05 pm »
ciao danielsan

welcome in the forum!

styles/CmakeLists.txt does exist!

http://scribus.net/websvn/filedetails.php?repname=Scribus&path=%2Ftrunk%2FScribus%2Fscribus%2Fstyles%2FCMakeLists.txt

if you really do not have it, you should try to get a fresh copy of the source code.

i'm not sure, but i would tip on a missing dependency... how did you get the list of -dev files to be installed?
which packages did you install?

ciao
a.l.e

otherwise, i would not use /usr/local/bin as a prefix ... try to make install scribus somewhere in your home and, if necessary / probably, create a symlink in /usr/local/bin to the created scribus binary. (but this is not related to your issue)

p.s.: since you're a power use, i would love to know what you do with scribus :-) ... just out of curiosity: it's always nice to hear what people do with scribus!

Danielsan

  • Newbie
  • *
  • Posts: 20
  • Karma: 0
  • Scribus User
Re: Issue Compiling Scribus 1.5 src on Debian Testing (Stretch)
« Reply #2 on: October 19, 2015, 07:24:43 am »
Hello,

I changed the destination for a local folder but I still got the same error, I followed the instruction from the BUILDING file, from the file install4.html and from this wepage: http://wiki.scribus.net/canvas/Building_SVN_versions_with_CMake; and obviusly I downloaded the latest src file from sourceforge.

I tried to figure out which were the missing dependencies but unofrtunately the documentation is not enough updated anyaway I remembered I can use alien to convert an rpm package to a deb. So in case I will try this second option.

I am not yet allowed to publish my latest works I made with Scribus and unfortunately the management eventually decided to move from open sources software to the Adobe CC, I am dealing with them to get an authorization. I have been using Scribus to create real printing ads not fake covers.
« Last Edit: October 19, 2015, 07:26:58 am by Danielsan »

a.l.e

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 1296
  • Karma: 19
    • the graphics lab
Re: Issue Compiling Scribus 1.5 src on Debian Testing (Stretch)
« Reply #3 on: October 19, 2015, 09:23:02 am »
the target was for sure not the cause of your issue :-)

can you check if you really don't have the CMakeLists.txt file mentioned above?

if it's not there, you have a faulty download.

you should remove the whole repository and to a fresh svn checkout.

if the file is there, i really think that you're missing a dependency. but, as you correctly wrote, it's not easy to know what is missing.
i can try to do a fresh debian testing setup and make a list of all the packages needed... but i doubt that i can do it this week!

if you confirm that you have that file, i will dig deeper into your make output and see what the cause could be...

ciao
a.l.e

GarryP

  • Hero Member
  • *****
  • Posts: 1408
  • Karma: 21
  • Scribus User
Re: Issue Compiling Scribus 1.5 src on Debian Testing (Stretch)
« Reply #4 on: October 19, 2015, 03:30:54 pm »
Daniel, I'm looking forward to seeing your work too. It's great to see the different things that can be achieved with Scribus. The more inspiration people get from examples the more they might want to create something of their own. I hope the management gives you authorisation to show it.

Danielsan

  • Newbie
  • *
  • Posts: 20
  • Karma: 0
  • Scribus User
Re: Issue Compiling Scribus 1.5 src on Debian Testing (Stretch)
« Reply #5 on: October 20, 2015, 08:01:25 am »
@ A.l.e.

I downloaded the scribus-1.5.0.tar.xz from source forge and installed the suggested packages from the sources above. I am not using the SVN version. I looked in the web engine search to find something but about QT5_WRAP_CPP there is almost nothing.

Attached find the cmakelists.txt available with the scribus-1.5.0.tar.xz

Thanks,

D.

a.l.e

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 1296
  • Karma: 19
    • the graphics lab
Re: Issue Compiling Scribus 1.5 src on Debian Testing (Stretch)
« Reply #6 on: October 20, 2015, 10:15:21 am »
ciao danielsan

the tar.xz you downloaded does contain the scribus/styles/CMakeLists.txt file...

it looks like a dependency problem.

do you have a list of all dependencies you have installed for scribus?

did you install the dev package for qt 5?

ciao
a.l.e

Danielsan

  • Newbie
  • *
  • Posts: 20
  • Karma: 0
  • Scribus User
Re: Issue Compiling Scribus 1.5 src on Debian Testing (Stretch)
« Reply #7 on: October 20, 2015, 06:05:08 pm »
Of course I believe to have installed all the dependencies however could you be so kind to write me which are those QT5-dev packages so I can check if someone is still missing?

Thanks!

D.

Nermander

  • Hero Member
  • *****
  • Posts: 1138
  • Karma: 15
Re: Issue Compiling Scribus 1.5 src on Debian Testing (Stretch)
« Reply #8 on: October 20, 2015, 08:35:37 pm »
Did you read this part?
http://wiki.scribus.net/canvas/Building_SVN_versions_with_CMake#Getting_and_installing_Qt5

And the sentence above that section, saying:
Quote
On Linux, for each item you have to install both the main package and the development package (for example: cairo and cairo-devel, pixman and pixman-devel, and so on). Some packages should be already installed (for example, Cairo or CUPS).



Danielsan

  • Newbie
  • *
  • Posts: 20
  • Karma: 0
  • Scribus User
Re: Issue Compiling Scribus 1.5 src on Debian Testing (Stretch)
« Reply #9 on: October 20, 2015, 09:28:52 pm »
I followed this page and I installed only the DEV version because the main packages required are already installed in my system, but probably what I missed is this:

Quote
If you have Qt4 and Qt5 installed, and/or cmake does not find Qt5, you need to specify its location with the build option -DQT_PREFIX="path-to-Qt5" (for example: -DQT_PREFIX="/home/user/Qt/5.1.1/gcc/")

I have Debian Testing since Lenny probably I have duplicate library of QT4 and QT5 (if not even QT3).


Anyway I will follow this part with more attention and probably using directly the SVN version, thanks!

Danielsan

  • Newbie
  • *
  • Posts: 20
  • Karma: 0
  • Scribus User
Re: Issue Compiling Scribus 1.5 src on Debian Testing (Stretch)
« Reply #10 on: October 21, 2015, 06:18:24 am »
Hi, I am still doing the test with the sourceforge source tar. So I tried to export the environment variable as suggested by the Scribus wiki but nothing change. Yes of course I double checked all the dependencies as well:
Code: [Select]
$ export PATH=/usr/lib/x86_64-linux-gnu/qt5/bin/:$PATH
$ cmake ../scribus -Wno-dev -DCMAKE_INSTALL_PREFIX:PATH=/usr/local/bin/
-- The C compiler identification is GNU 5.2.1
-- The CXX compiler identification is GNU 5.2.1
-- Check for working C compiler: /usr/bin/cc
-- Check for working C compiler: /usr/bin/cc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
CMake Error at styles/CMakeLists.txt:21 (QT5_WRAP_CPP):
  Unknown CMake command "QT5_WRAP_CPP".


-- Configuring incomplete, errors occurred!
See also "/home/myuser/Compilati/scribus-1.5.0/builddir/CMakeFiles/CMakeOutput.log".

I found where is the error but I am not a coder so I don't know what to do:
Code: [Select]
INCLUDE_DIRECTORIES(
${CMAKE_SOURCE_DIR}
${CMAKE_SOURCE_DIR}/scribus
${FREETYPE_INCLUDE_DIRS}
)

SET(SCRIBUS_STYLES_MOC_CLASSES
)

SET(SCRIBUS_STYLES_LIB_SOURCES
style.cpp
stylecontext.cpp
stylecontextproxy.cpp
linestyle.cpp
charstyle.cpp
paragraphstyle.cpp
tablestyle.cpp
cellstyle.cpp
)

QT5_WRAP_CPP(SCRIBUS_STYLES_MOC_SOURCES ${SCRIBUS_STYLES_MOC_CLASSES})

SET(SCRIBUS_STYLES_LIB "scribus_styles_lib")
ADD_LIBRARY(${SCRIBUS_STYLES_LIB} STATIC ${SCRIBUS_STYLES_LIB_SOURCES} ${SCRIBUS_STYLES_MOC_SOURCES})

# This is a convenience library that for linkage purposes is part of Scribus's
# main API.
SET_TARGET_PROPERTIES(${SCRIBUS_STYLES_LIB}
PROPERTIES
COMPILE_FLAGS -DCOMPILE_SCRIBUS_MAIN_APP
)

This is the line 21 which get an error:
Code: [Select]
QT5_WRAP_CPP(SCRIBUS_STYLES_MOC_SOURCES ${SCRIBUS_STYLES_MOC_CLASSES})

Nermander

  • Hero Member
  • *****
  • Posts: 1138
  • Karma: 15
Re: Issue Compiling Scribus 1.5 src on Debian Testing (Stretch)
« Reply #11 on: October 21, 2015, 08:18:55 am »
I think you should not point to the Qt5 binaries, you should point to the Qt5 source (i.e. the -devel package).

QT5_WRAP_CPP is a commande provided by the Qt5 core source package.

a.l.e

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 1296
  • Karma: 19
    • the graphics lab
Re: Issue Compiling Scribus 1.5 src on Debian Testing (Stretch)
« Reply #12 on: October 21, 2015, 09:35:32 am »
on debian testing there is nothing special to be done for installing qt5.

but you need the qt-5 dev package. at least, you probably need qtbase5-dev.

on debian testing my cmake command looks like this:

cmake -DCMAKE_INSTALL_PREFIX:PATH=/home/ale/docs/bin/scribus -DWANT_DEBUG=1 -DWANT_GUI_LANG="en_GB;de;fr;it;en" ..

you might want to add -DWANT_NOOSG=1 if osg is installed (as far as i recall, cmake or make crashe in a bad way if it finds osg... and you probably don't need it in scribus)

you don't need any QT5 path directive in the cmake.

and i'm pretty sure that there is nothing you should change in the code!
it's about getting the right packages and not putting "ill" commands in cmake...

danielsan: at this point, i think the best is an interactive session, where we try in parallel to set it up...

i can be available over lunch on http://wiki.scribus.net/canvas/Special:WebChat if you tell me that you'll be there.

----> this seems to be a bit broken, too:
if you're already on irc: get into #scribus on freenode.
otherwise on the web interface above, write the two commands:
/nick danielsan
/join #scribus
<----- sorry, i'm not in charge of that :-(

ciao
a.l.e
« Last Edit: October 21, 2015, 09:38:20 am by a.l.e »

a.l.e

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 1296
  • Karma: 19
    • the graphics lab
Re: Issue Compiling Scribus 1.5 src on Debian Testing (Stretch)
« Reply #13 on: October 21, 2015, 11:57:11 am »
danielsan, for a very different reason, i'm currently installing a debian testing vm... with a bit of luck, i will soon be able to produce a list of packages needed for compiling scribus.

Danielsan

  • Newbie
  • *
  • Posts: 20
  • Karma: 0
  • Scribus User
Re: Issue Compiling Scribus 1.5 src on Debian Testing (Stretch)
« Reply #14 on: October 21, 2015, 06:15:44 pm »
Hi, unfortunately I have very few time so we can't deal for doing any web chat session.

About the issue I found this directions from the QT5 website: http://doc.qt.io/qt-5/cmake-manual.html


And I played a bit with those hints and I was able to do few steps forward but soon I found a tons of other errors, thus, simply, what I got is the instruction to build Scribus 1.5 perhaps are not updated to work with the latest version of CMAKE, at least for the tar source hosted on sourceforge.

That's all
« Last Edit: October 22, 2015, 01:04:01 am by Danielsan »

 

palmate