User:Donnguyen: Difference between revisions

From KDE Community Wiki
No edit summary
 
(53 intermediate revisions by the same user not shown)
Line 1: Line 1:
= Building KDE/Plasma 5 on Ubuntu 14.04 LTS =
==Projects==
The aim of this guide is to help you build KDE Plasma 5 for development and/or use. These instructions are valid as of 31 Aug 2016.
===Dolphin===
[https://www.kde.org/applications/system/dolphin/development Dolphin - Development Information]


== Install a recent version of cmake ==
[https://docs.kde.org/trunk5/en/applications/dolphin/ Dolpin Handbook]
{{Input|1=<nowiki>
sudo apt-get install build-essential
wget https://cmake.org/files/v3.6/cmake-3.6.1.tar.gz
tar -zxvf cmake-3.6.1.tar.gz
cd cmake-3.6.1/
./configure
make
sudo apt-get install checkinstall
sudo checkinstall
</nowiki>}}


== Upgrade libwayland-dev and network-manager from PPA's ==
[https://github.com/KDE/dolphin Dolphin github]
Upgrade libwayland-dev and related dependencies:
{{Input|1=<nowiki>sudo add-apt-repository ppa:xorg-edgers/ppa
sudo apt-get update  
sudo apt-get install libwayland-dev
</nowiki>}}
Upgrade network-manager and related dependencies:
{{Input|1=<nowiki>sudo add-apt-repository ppa:9v-shaun-42/networkmanager 
sudo apt-get update
sudo apt-get install network-manager
</nowiki>}}
{{Tip|You may lose network connection after this step.  Reboot to fix.}}


== Install Qt 5.7.0 using installer ==
==Guides I've Written==
Download and install to default location: /opt/Qt5.7.0
[[Guidelines_and_HOWTOs/Build_from_source/Plasma 5 on Ubuntu 14.04 LTS|How to build KDE/Plasma 5 on Ubuntu 14.04 LTS]]
{{Input|1=<nowiki>sudo ./qt-opensource-linux-x64-5.7.0.run</nowiki>}}
Choose default options and include "Sources" option
{{Note|On my computer it appears to be stuck at 4%(dialog box doesn't respond), but it installs just fine if I wait.}}


== Install some build dependencies ==
[[/Building_and_using_Qt5GStreamer_on_Windows|Building and using Qt5GStreamer on Windows]]


{{Input|1=<nowiki>sudo apt-get build-dep kde-workspace qtbase5-dev</nowiki>}}
==Videos I've Made==
[https://www.youtube.com/watch?v=28Jjf5Ak6Q0 Touchscreen gestures in Linux using Touchegg]


== Build Qtwebkit ==
==KDE==
[irc://irc.kde.org/kde-devel <nowiki>#kde-devel</nowiki>]
Install dependencies for building Qtwebkit
{{Input|1=<nowiki>sudo apt-get install flex bison gperf libicu-dev libxslt-dev ruby</nowiki>}}
Install git
{{Input|1=<nowiki>sudo apt-get install git</nowiki>}}
Clone and build qtwebkit
{{Input|1=<nowiki>git clone git://code.qt.io/qt/qtwebkit.git --branch 5.7.0
mkdir qtwebkit-build
cd qtwebkit-build
/opt/Qt5.7.0/5.7/gcc_64/bin/qmake ../qtwebkit
make
sudo make install
</nowiki>}}


== Setup kdesrc-build and .kdesrc-buildrc ==
https://git.reviewboard.kde.org/dashboard/
Most of this section is taken from https://community.kde.org/Guidelines_and_HOWTOs/Build_from_source
=== Git remote prefix ===
Let's setup a "kde:" prefix for git commands. Add the following text to your ~/.gitconfig:
<syntaxhighlight lang="ini">
[url "git://anongit.kde.org/"]
  insteadOf = kde:
[url "ssh://git@git.kde.org/"]
  pushInsteadOf = kde:
</syntaxhighlight>


=== Install kdesrc-build ===
===https://bugs.kde.org/===
''kdesrc-build'' is,  a user-space package manager, it is used to compile KDE-related projects from source and installs them into a designated directory.
[https://bugs.kde.org/buglist.cgi?bug_status=CONFIRMED&order=changeddate%20DESC%2Cbug_id%20DESC&product=dolphin&query_format=advanced Confirmed dolphin bugs]


Follow the given steps to set up kdesrc-build to install KDevelop into our $HOME directory:
[https://bugs.kde.org/buglist.cgi?bug_status=UNCONFIRMED&bug_status=CONFIRMED&bug_status=ASSIGNED&bug_status=REOPENED&email2=don78colorado&emailassigned_to2=1&emailcc2=1&emailreporter2=1&emailtype2=substring&query_format=advanced Bugs related to me]
<pre>
mkdir ~/kdesrc 
cd ~/kdesrc 
git clone kde:kdesrc-build 
cd kdesrc-build 
cp kdesrc-buildrc-kf5-sample ~/.kdesrc-buildrc


# Install a symlink of kdesrc-build to a location in PATH
mkdir ~/bin 
ln -s $PWD/kdesrc-build ~/bin 
export PATH=~/bin:$PATH
</pre>


You will need to append the line <pre>export PATH=~/bin:$PATH</pre> to <pre>~/.bashrc</pre> so kdesrc-build is available in PATH whenever you open a terminal.
https://identity.kde.org/


https://lxr.kde.org


'''Configure kdesrc-build
https://phabricator.kde.org/
'''
edit<pre>~/.kdesrc-buildrc</pre> 
Replace <pre>/path/to/kdesrc-build/kf5-qt5-build-include</pre> with <pre>~/kdesrc/kdesrc-build/kf5-qt5-build-include</pre> in ~/.kdesrc-buildrc file


Add <pre>ignore-kde-structure true</pre> and <pre>make-options -jN</pre> to the global section in ~/.kdesrc-buildrc
[https://quickgit.kde.org/ KDE QuickGit]
<pre>
global 
  ...
  ignore-kde-structure true
  make-options -j5 # NOTE: 5 is the number of jobs, this should usually be (number-of-cpu-cores + 1)
  #stop-on-failure        true        # Stop kdesrc-build
  ...
end global 
</pre>


Set qtdir to output of qmake –v minus the lib
[https://github.com/kde/ KDE GitHub]
    kdedir /opt/kde-5 # Where to install KF5-based software
    qtdir /opt/Qt5.7.0/5.7/gcc_64    # Where to find Qt5
{{Remember|Make sure you have write access to the director specified by kdedir!}}


===Setup baloo section to fix compile error ===
[https://www.kde.org/standards/kxmlgui/1.0/kxmlgui.xsd KXMLGUI XSD]


{{Input|1=<nowiki>options baloo
==Links==
    cmake-options -DCMAKE_CXX_FLAGS="-lc"
===Development===
end options
[[Get_Involved/development]]
</nowiki>}}


kdesrc-build needs xml-parser-perl
[[Guidelines_and_HOWTOs/Using_Qt_Creator]]
{{Input|1=<nowiki>sudo apt-get install libxml-parser-perl</nowiki>}}


== Build plasma-desktop ==
[[Policies/Commit_Policy]]
Some more dependencies
{{Input|1=<nowiki>sudo apt-get build-dep polkit-qt-1
sudo apt-get install libgif-dev
sudo apt-get install libnm-glib-dev
sudo apt-get install "^libxcb.*" libx11-xcb-dev libglu1-mesa-dev libxrender-dev libxi-dev
sudo apt-get install libattr1-dev
sudo apt-get install liblmdb-dev
sudo apt-get install libxapian-dev
</nowiki>}}
Download and install some packages from Xenial:
{{Input|1=<nowiki>mkdir extra-deb
cd extra-deb
wget http://mirrors.kernel.org/ubuntu/pool/main/libx/libxkbcommon/libxkbcommon-dev_0.5.0-1ubuntu2_amd64.deb
wget http://mirrors.kernel.org/ubuntu/pool/main/libx/libxkbcommon/libxkbcommon0_0.5.0-1ubuntu2_amd64.deb
wget http://mirrors.kernel.org/ubuntu/pool/main/libe/libepoxy/libepoxy-dev_1.3.1-1_amd64.deb
wget http://mirrors.kernel.org/ubuntu/pool/main/libe/libepoxy/libepoxy0_1.3.1-1_amd64.deb
dpkg -i *.deb
</nowiki>}}
Build:
{{Input|1=<nowiki>kdesrc-build --include-dependencies plasma-desktop</nowiki>}}


== Build some extra applications ==
[[Guidelines_and_HOWTOs/UnitTests]]
{{Input|1=<nowiki>
kdesrc-build applications
</nowiki>}}


== Set up environment to run plasma 5 ==
===Learning===
https://techbase.kde.org/Development/Tutorials
 
===API===
https://api.kde.org/frameworks/kxmlgui/html/classKXmlGuiWindow.html
 
http://doc.qt.io/qt-5/qobject.html
 
===Qt===
[http://doc.qt.io/qt-5/qtexamplesandtutorials.html Qt Examples And Tutorials]
 
[http://doc.qt.io/ Qt Documentation]
 
===Git===
 
[[Infrastructure/Git/Recipes]]
 
[[Sysadmin/GitKdeOrgManual]]
 
[[Infrastructure/Git]]
 
[[Frameworks/Git_Workflow]]
 
[[Infrastructure/Git/Simple_Workflow]]
 
===cmake===
https://cmake.org/cmake/help/v3.6/manual/cmake-commands.7.html
 
https://api.kde.org/ecm/manual/ecm-modules.7.html
 
==Test Section==
Under User:donnguyen (outdated, just for testing) - [[/How to build KDE/Plasma 5 on Ubuntu 14.04 LTS|How to build KDE/Plasma 5 on Ubuntu 14.04 LTS]]
 
[[/first with prepending slash|Desc with slash]] - Creates it under here
 
[[first without prepending slash|Desc with no slash]] - Creates it at root
 
Testing "/Test new link" - [[/Test new link|Test new link]]
 
Testing "Special:myLanguage" - [[Special:myLanguage/Guidelines_and_HOWTOs/Build_from_source/Plasma 5 on Ubuntu 14.04 LTS|How to build KDE/Plasma 5 on Ubuntu 14.04 LTS]]

Latest revision as of 21:22, 17 April 2017