summaryrefslogtreecommitdiff
path: root/HACKING
diff options
context:
space:
mode:
Diffstat (limited to 'HACKING')
-rw-r--r--HACKING314
1 files changed, 0 insertions, 314 deletions
diff --git a/HACKING b/HACKING
deleted file mode 100644
index fa37825c..00000000
--- a/HACKING
+++ /dev/null
@@ -1,314 +0,0 @@
-====== Midori - Contribute ======
-
-**This document is licensed under the LGPL 2.1.**
-
-====== Check out the sources ======
-
-git clone https://github.com/midori-browser/core.git
-
-The development **master** (trunk, tip) is the latest iteration of the next release. Browse it online and look for other branches.
-
-//The code used to be hosted at lp:midori and git.xfce.org/apps/midori respectively.//
-
-Keep your copy updated:
-
-git pull --rebase
-====== Join IRC chat rooms ======
-
-Join irc://irc.freenode.net/midori #midori on Freenode https://kiwiirc.com/client/irc.freenode.net/midori or use webchat to talk about Midori, discuss bugs and new ideas.
-====== Contribute other than touching code ======
-
- * https://github.com/midori-browser/core/issues Go through problem reports and check Unconfirmed bugs or those lacking information and mark any duplicates you spot
- * https://www.bountysource.com/#trackers/130181-midori Add a bounty for a feature or bug you'd like to support
- * https://translations.launchpad.net/midori/trunk/+pots/trunk Translate to your own language
- * https://github.com/eustasy/midori-browser.org/issues Report website bugs
- * Write http://wiki.xfce.org/midori/tutorial your own extension - granted that's code, too, but maybe a little easier than hacking the core.
-
-====== Documentation resources ======
-
- * https://wiki.gnome.org/Projects/Vala/Tutorial Vala Tutorial
- * http://midori-browser.org/docs/api/vala/midori/ Midori Vala Docs
- * http://midori-browser.org/docs/api/c/html/ Midori C Docs
-
-====== Build the code ======
-
-mkdir _build
-cd _build
-cmake -DCMAKE_INSTALL_PREFIX=/usr ..
-make
-sudo make install
-
-
-//Advanced Tip: Pass "-G Ninja" to cmake to use http://martine.github.io/ninja/ Ninja instead of make (usually packaged as ninja or ninja-build).//
-
-You can build Midori using another C Compiler for example Clang. Just
-add -DCMAKE_C_COMPILER=/path/to/compiler to the cmake arguments.
-Then you can build following your normal procedure. Like this:
-cmake -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_C_COMPILER=/usr/bin/clang ..
-make
-
-Midori can be **run without being installed**.
-
-_build/midori
-
-====== Testing ======
-
-===== Unit tests =====
-
-You'll want to **unit test** the code if you're testing a new version or contributed your own changes:
-
-xvfb-run make check
-
-===== Manual checklist =====
-
-* Browser window starts up normally, with optional URL(s) on the command line
-* Tabs have icons, a close button if there's more than one and can be switched
-* Urlbar suggests from typed search or URL, completes from history and highlights key
-* Private data can be cleared
-* Shortcuts window shows most important hotkeys
-* Download button lists on-going and finished downloads
-* javascript:alert("test"), javascript:confirm("test") and javascript:input("test") work
-* Websites can (un)toggle fullscreen mode
-
-====== Debugging issues ======
-
-Testing an installed release may reveal crashers or memory corruption which require investigating from a local build and obtaining a stacktrace (backtrace, crash log).
-
-gdb _build/midori
-run
-…
-bt
-
-
-If the problem is a warning, not a crash GLib has a handy feature
-
-env G_DEBUG=all gdb _build/midori
-
-On Windows you can open the folder where Midori is installed and double-click gdb.exe. A black command line window should appear.
-
-file midori.exe
-run
-…
-bt
-
-To verify a regression you might need to revert a particular change:
-
-
-# Revert only d54c7e45
-git revert d54c7e45
-
-====== Coding style and quality ======
-
-Midori code should in general have:
-
- * 4 space indentation, no tabs
- * Between 80 to 120 columns
- * Use // or /* */ style comments
- * Call variables //animal// and //animal_shelter// instead of <del>camelCase</del>
- * Keep a space between functions/ keywords and round parentheses
- * Prefer //new Gtk.Widget ()// over //using Gtk; new Widget ()//
- * Midori and GLib namespaces should be omitted
- * Don't use //private// specifiers (which is the default)
- * Stick to standard Vala-style curly parentheses on the same line
- * Cuddled //} else {// and //} catch (Error error) {//
-
-====== Committing code ======
-
-Tell Git your name if you haven't yet
- git config user.email "<email@address>"
- git config user.name "Real Name"
-
-See what you did so far
- git diff
-
-Get an overview of changed and new files
- git status -u
-
-Add new files, move/ rename or delete
- git add FILENAME
- mv OLDFILE NEWFILE
- rm FILENAME
-
-Commit all current changes, selected interactively
- git commit -p -v
-
-If you have one or more related bug reports you should mention them in the commit message. Once these commits are merged the bug will automatically be closed and the commit log shows clickable links to the reports.
- Fixes: #123
-
-If you've done several commits
- git log
-
-In the case you committed something wrong or want to ammend it:
- git reset --soft HEAD^
-
-If you end up with unrelated debugging code or other patches in the current changes, it's sometimes handy to temporarily clean up. //This may be seen as git's version of bzr shelve.//
- git stash save
- git commit -p -v
- git stash apply
-
-Remember to keep your branch updated:
- git pull --rebase
-
-As a general rule of thumb, ''git COMMAND --help'' gives you an explanation of any command and ''git --help -a'' lists all available commands.
-
-====== Push proposed changes ======
-
-If you haven't yet, https://github.com/settings/keys check that GitHub has your SSH key - you can create an SSH key with **Passwords and Keys** aka **Seahorse** or ''ssh-keygen -t rsa'' - and specify Host github.com with User git in your SSH config.
-
-To make your own changes, just **fork** the project on GitHub, add your patch(es) and **push it under your username** on GitHub and you can **propose it for merging into master**. This will automatically request a **review from other developers** who can then comment on it and provide feedback.
-
-====== Backwards compatibility ======
-As of Midori 0.5.4 the formula is:
- * Required dependencies need to be available on the previous stable https://apps.fedoraproject.org/packages/s/webkit Fedora and http://packages.ubuntu.com/search?suite=quantal&keywords=webkit&searchon=names Ubuntu
- * For reference http://openports.se/www/webkit OpenBSD
- * Windows XP through 8 are to date ABI compatible, all dependencies are included
-
-^ package ^ F17 (2012-05-29) ^ U 12.10 (2012-10-18) ^
-| glib2 | 2.32.4 | 2.34.0 |
-| vala | 0.16.1 | 0.16 |
-| gtk3 | 3.4.4 | 3.6.0 |
-| gtk2 | 2.24.13 | 2.24.13 |
-| soup | 2.38.1 | 2.40 |
-| webkit | 1.8.3-1.fc17 | 1.10.0-0ubuntu1 |
-
-====== Midori for Windows ======
-
-===== For Linux developers =====
-==== Dependencies ====
-Midori for Windows is compiled on a Linux host and MinGW stack. For the current build Fedora 18 packages are used. Packages needed are listed below:
-
-yum install gcc vala intltool
-
-For a native build
-yum install libsoup-devel webkitgtk3-devel sqlite-devel
-
-For cross-compilation
-yum install mingw{32,64}-webkitgtk3 mingw{32,64}-glib-networking mingw{32,64}-gdb mingw{32,64}-gstreamer-plugins-good
-
-Packages needed when assembling the archive
- yum install faenza-icon-theme p7zip mingw32-nsis greybird-gtk3-theme
-
-Installing those should get you the packages needed to successfully build and develop Midori for Win32.
-==== Building ====
-For 32-bit builds:
-
-mkdir _mingw32
-cd _mingw32
-mingw32-cmake .. -DCMAKE_INSTALL_PREFIX=/usr/i686-w64-mingw32/sys-root/mingw -DCMAKE_VERBOSE_MAKEFILE=0
-make
-sudo make install
-
-For 64-bit builds:
-
-mkdir _mingw64
-cd _mingw64
-mingw64-cmake .. -DCMAKE_INSTALL_PREFIX=/usr/x86_64-w64-mingw32/sys-root/mingw -DCMAKE_VERBOSE_MAKEFILE=0
-make
-sudo make install
-
-Once built and tested you can assemble the Midori archive with a helper script
-32-bit build:
-env MINGW_PREFIX="/usr/i686-w64-mingw32/sys-root/mingw" ./win32/makedist/makedist.midori
-64-bit build:
-env MINGW_PREFIX="/usr/x86_64-w64-mingw32/sys-root/mingw/" ./win32/makedist/makedist.midori x64
-===== Testing =====
-For testing your changes unfortuantely a real system is needed because Midori and WebKitGTK+ don't work properly under Wine. Even if it works some problems are not visible when using Wine, but are present when running under a real Windows system and vice versa.
-
-One way around it is to virtualize Windows on a Linux host and mount your MinGW directories as a network drive or shared folder.
-
-===== For Windows developers =====
-Rough list of prerequisites for building with MinGW on Windows
-
-If in doubt whether to get 32 or 64 bit versions use 32 bit ones, they are more
-universal and tend to be less broken.
-
-
-==== MinGW compiler ====
-Compiler should match the one that was used to build packages ideally.
-
- * We will user *mingw64 rubenvb* release
- * Lastest stable release is gcc 4.8.0
-
-[[http://sourceforge.net/projects/mingw-w64/files/Toolchains%20targetting
-%20Win64/Personal%20Builds/rubenvb/gcc-4.8-release/|Releases]]
-
-[[http://sourceforge.net/projects/mingw-w64/files/Toolchains%20targetting
-%20Win64/Personal%20Builds/rubenvb/gcc-4.8-release/x86_64-w64-mingw32-gcc-4.8.0-
-win32_rubenvb.7z/download|Download]]
-
-
-==== 7zip ====
-We will need 7zip to extract various archives
-
-http://www.7-zip.org/download.html Homepage
-
-
-http://downloads.sourceforge.net/sevenzip/7z920.exe 32bit Installer
-
-
-==== Python3 (to extract rpms) ====
-We will need python3 to use download-mingw-rpm.py script.
-If you don't plan to use it you can safely skip this step.
-
-We get python3, whatever is the lastes stable release.
-
-http://www.python.org/download/releases/3.3.5 Releases
-
-http://www.python.org/downloads/release/python-335/ Download
-
-http://www.python.org/ftp/python/3.3.5/python-3.3.5.amd64.msi Installer
-
-Install Python and be sure to check "addd python.exe to path" installer checkbox.
-
-==== download-mingw-rpm.py ====
-We get download-mingw-rpm.py script from github. It uses Python3 and should fetch and
-unpack rpm files for us.
-
-[[https://github.com/mkbosmans/download-mingw-rpm/blob/master/download-
-mingw-rpm.py|View Script]]
-
-[[https://github.com/mkbosmans/download-mingw-rpm/raw/master/download-
-mingw-rpm.py|Download Script]]
-
-Usage:
-
- * Launch cmd.exe
- * Navigate to folder where the script was saved
- * Make sure that python can access 7z.exe
- * Run command and wait, it should extract the packages into your current directory
-
-c:\Python33\python.exe download-mingw-rpm.py -u http://ftp.wsisiz.edu.pl/pub/linux/fedora/linux/updates/18/i386/ --deps mingw32-webkitgtk mingw32-glib-networking mingw32-gdb mingw32-gstreamer-plugins-good
-
-[[http://dl.fedoraproject.org/pub/fedora/linux/releases/18/Everything/i386/os/Packages
-/m/|Fedora 18 packages]]
-
-The above URL for some reason does not work with the script.
-
-==== MSYS ====
-Msys contains shell and some small utilities
-
-[[http://sourceforge.net/projects/mingw-w64/files/External%20binary
-%20packages%20%28Win64%20hosted%29/MSYS%20%2832-bit%29/MSYS-20111123.zip/download|Download]]
-
-
-==== CMake ====
-http://www.cmake.org/cmake/resources/software.html Homepage
-http://www.cmake.org/files/v2.8/cmake-2.8.12.2-win32-x86.exe Installer
-
-When installing check the installer checkbox "add to path"
-
-
-==== Vala ====
-http://ftp.gnome.org/pub/gnome/sources/vala/0.20/vala-0.20.0.tar.xz Source
-
-==== Globbing it all together ====
-
-Extracted rpms msys and mingw packages should form uniform unix like folder.
-You use msys.bat to launch a shell
-
-====== Jargon ======
- * freeze: a period of bug fixes only eg. 4/2 cycle means 4 weeks of features and 2 weeks to focus on resolving existing problems
- * PR: pull request, a branch proposed for review, analogous to MR (merge request) with Bazaar
- * ninja: an internal tab, usually empty label, used for taking screenshots
- * fortress: user of an ancient release like 0.4.3 as found on Raspberry Pie, Debian, Ubuntu
- * katze, sokoke, tabby: legacy API names and coincidentally cat breeds