This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision Next revision Both sides next revision | ||
wiki:development:nxlibs-repository [2011/12/27 16:33] sunweaver [Importing the old sources] |
wiki:development:nxlibs-repository [2012/02/28 12:12] morty Some more formatting fixes |
||
---|---|---|---|
Line 11: | Line 11: | ||
The old sources were downloaded by brute force from the nomachine download server: | The old sources were downloaded by brute force from the nomachine download server: | ||
- | + | <file bash getnx.sh> | |
- | | + | wget http:// |
- | | + | wget http:// |
- | | + | wget http:// |
- | | + | wget http:// |
- | | + | wget http:// |
- | | + | wget http:// |
- | | + | wget http:// |
- | | + | wget http:// |
- | | + | wget http:// |
- | | + | wget http:// |
- | | + | wget http:// |
- | | + | wget http:// |
- | | + | wget http:// |
- | | + | wget http:// |
- | | + | wget http:// |
- | | + | wget http:// |
- | | + | wget http:// |
- | | + | wget http:// |
- | | + | wget http:// |
- | | + | wget http:// |
- | | + | wget http:// |
- | | + | wget http:// |
- | | + | wget http:// |
- | | + | wget http:// |
- | | + | wget http:// |
- | | + | wget http:// |
- | | + | wget http:// |
- | | + | wget http:// |
- | | + | wget http:// |
- | | + | wget http:// |
- | | + | wget http:// |
- | | + | wget http:// |
- | | + | wget http:// |
- | | + | wget http:// |
- | | + | wget http:// |
- | | + | wget http:// |
- | | + | wget http:// |
- | | + | wget http:// |
- | | + | wget http:// |
- | | + | wget http:// |
- | | + | wget http:// |
- | | + | wget http:// |
- | | + | wget http:// |
- | | + | wget http:// |
- | | + | wget http:// |
- | | + | wget http:// |
- | | + | wget http:// |
- | | + | wget http:// |
- | | + | wget http:// |
- | | + | wget http:// |
- | | + | wget http:// |
+ | </ | ||
These sources are then unpacked in a temporary directory '' | These sources are then unpacked in a temporary directory '' | ||
- | + | <file bash extractnx.sh> | |
- | | + | #!/bin/bash |
- | | + | mkdir t; cd t; |
- | | + | for p in nxcomp{, |
- | | + | for f in ../ |
+ | done | ||
+ | </ | ||
Now clone the nx-libs repo: | Now clone the nx-libs repo: | ||
- | git clone git:// | + | <code bash> |
+ | git clone git:// | ||
+ | </ | ||
there, for each new submodule, create a new branch. as an example, here for the nxcomp branch: | there, for each new submodule, create a new branch. as an example, here for the nxcomp branch: | ||
- | git checkout -b nxcomp a840692edc9c6d19cd7c057f68e39c7d95eb767d | + | <code bash> |
+ | git checkout -b nxcomp a840692edc9c6d19cd7c057f68e39c7d95eb767d | ||
+ | </ | ||
| | ||
- | NB: the commit a840692edc9c6d19cd7c057f68e39c7d95eb767d is the very first commit in the repository. It contains an empty tree as content and is common for all branches in '' | + | NB: the commit |
We now import the sources using the [[http:// | We now import the sources using the [[http:// | ||
+ | <file bash git-load-dirs.sh> | ||
wc=../ | wc=../ | ||
l=`ls -d nxcomp-*(/ | l=`ls -d nxcomp-*(/ | ||
for f in $l; do (cd $wc; git reset --hard ; git clean -dfx); git_load_dirs -w $wc $f; done | for f in $l; do (cd $wc; git reset --hard ; git clean -dfx); git_load_dirs -w $wc $f; done | ||
+ | </ | ||
Now the nxcomp sources have been imported in the ' | Now the nxcomp sources have been imported in the ' | ||
Line 93: | Line 101: | ||
- How to import pristine-tar data. Note that the git-import-orig dir strips the first directory member. This is usually sensible for sensible projects, but not for NX, which expects the sources to be unpacked in a very precise manner. Therefore, we need to pretty clumsily work with temporary subdirectories to capture this right. I have not investigated yet how to integrate this with pristine-tar | - How to import pristine-tar data. Note that the git-import-orig dir strips the first directory member. This is usually sensible for sensible projects, but not for NX, which expects the sources to be unpacked in a very precise manner. Therefore, we need to pretty clumsily work with temporary subdirectories to capture this right. I have not investigated yet how to integrate this with pristine-tar | ||
+ | - Mike writes: after struggling with pristine-tar for more than a day now... I have reported a [[http:// | ||
+ | |||
+ | |||
+ | ===== Editing patches using quilt ===== | ||
+ | ==== Configure quilt ==== | ||
+ | add to ~/.bashrc | ||
+ | < | ||
+ | alias dquilt=" | ||
+ | </ | ||
+ | |||
+ | create ~/ | ||
+ | < | ||
+ | d=. ; while [ ! -d $d/debian -a `readlink -e $d` != / ]; do d=$d/..; done | ||
+ | if [ -d $d/debian ] && [ -z $QUILT_PATCHES ]; then | ||
+ | # if in Debian packaging tree with unset $QUILT_PATCHES | ||
+ | QUILT_PATCHES=" | ||
+ | QUILT_PATCH_OPTS=" | ||
+ | QUILT_DIFF_ARGS=" | ||
+ | QUILT_REFRESH_ARGS=" | ||
+ | QUILT_COLORS=" | ||
+ | if ! [ -d $d/ | ||
+ | fi | ||
+ | </ | ||
+ | ==== modifying patches ==== | ||
+ | get a source tree from git | ||
+ | < | ||
+ | git clone ssh:// | ||
+ | cd nx-libs | ||
+ | </ | ||
+ | apply patches until you find patch you want to edit | ||
+ | < | ||
+ | dquilt push | ||
+ | </ | ||
+ | edit files you want to change | ||
+ | if you want to add new files to patch, you can make it with command: | ||
+ | < | ||
+ | dquilt add <new file> | ||
+ | </ | ||
+ | after you are finished with editting, apply changes to patch | ||
+ | < | ||
+ | dquilt refresh --strip-trailing-whitespace | ||
+ | </ | ||
+ | revoke all patches with | ||
+ | < | ||
+ | dquilt pop -a | ||
+ | </ | ||
+ | check your changes with "git status" | ||
+ | < | ||
+ | * Update patch: 202_nx-x11_enable-xinerama.full.patch, | ||
+ | < | ||
+ | </ | ||
+ | commit your changes with " | ||
+ | ==== Create new patch ==== | ||
+ | apply paches until you reach the code state where you want to begin with your new patch | ||
+ | < | ||
+ | dquilt push | ||
+ | </ | ||
+ | create new patch NUMBER_NXCOMPONENT_DESCRIPTION.full.patch, | ||
+ | < | ||
+ | dquilt new 203_nxagent_disable-rootless-exit.full.patch | ||
+ | </ | ||
+ | add files, which you want to patch with | ||
+ | < | ||
+ | dquilt add DATEINAME | ||
+ | </ | ||
+ | edit files, you want to patch and save the changes | ||
+ | < | ||
+ | dquilt refresh | ||
+ | </ | ||
+ | revoke all patches with | ||
+ | < | ||
+ | dquilt pop -a | ||
+ | </ | ||
+ | check your changes with "git status" | ||
+ | < | ||
+ | * Create patch: 203_nxagent_disable-rootless-exit.full.patch, | ||
+ | < | ||
+ | </ | ||
+ | commit your changes with " |