Search Results: "tim"

4 December 2007

Romain Francoise: Shared links for 2007-12-04

Michal Čihař: Gammu test version 1.15.90

New Gammu testing versions is out. This time there are no exciting new features, I still continue in bug fixing mode and cleaning up things. Full list of changes: You can download from usual place: http://cihar.com/gammu/

Otavio Salvador: A Resume made easy

It was a very long time ago since I did my last resume and never found the energy to update (or translate it to English) so I thought it was nice to have this kind of information about myself. It was nice since it gave to me a nice impressions of events I participated and like. I’ve decided to do my resume using LaTeX (I use it for majority of my documents) and started to browse the web to find something useful to use as basis. I ended up finding Making a Resume in LaTeX and liked the final result. I then wanted to have it in English and Portuguese and them I remembered about po4a that makes that task very easy :-) I ended changing Adrew’s style to a class and writing a cuple of Makefiles to automate all this. All well done :-D I suggest that anyone interested on it to take a look on the GIT repository and also provide tips about how to improve it. I hope it’s useful to anybody else :-D

3 December 2007

Sune Vuorela: Save my laptop, save the world

I think my title is some tagline from some tv show I am not following, but anyway. Today my laptop stopped working. *GRR*. The usual: The power plug in the laptop stops working because it has been molested over the last 4 years. I haven’t planned in investing in a new laptop currently, so the alternative was fixing it. After splitting it into every little part I finally found the plug. And yes. The soldering was broken, the plug itself was broken. Needs replacement. I never bragged about my soldering skills before, but \o/ - I managed to get it removed - the only spare one I had came with 8 cm wire I now have this wire hanging out my laptop, but it is working again. Even better than before. The last weeks, I constantly needed to wiggle the powerplug. No need for that anymore. Finishing off with a big piece of warm glue to keep everything at its place. It is not beatiful, but it works:
laptoprepair.jpg I wonder for how long. It is probably time to consider saving up for a new laptop.

Michael Prokop: git[-svn] in 30 minutes

… or something like that… I planned to write a short note about how to start with using git-svn so I can provide a pointer to some of my colleagues. It turned out that git has too many nice features that you should be aware of. :) Hopefully my notes (now being a reference for myself as well, thx to gebi for all the help and feedback) are useful anyway. If you think something (more or less essential, or at least something most of us should be aware of) is missing: please feel free to mention that in the comment section of my blog entry, thanks. Disclaimer: I’m still happy with mercurial for what I - and we at grml in general - use it: linear, but anyway distributed development. git on the other hand provides some really nice features. Rebasing and branching with git is really great - so non-linear development just works. As usual: use the right tool for the right job. git is a bit complicate to use. Not only but especially in the beginning. On the other hand I’m not such a big friend of subversion. If you wanthave to use subversion (Graz University of Technology for example provides a svn service to their students and employees) but prefer to work with git instead you should be aware of git-svn. git-svn gives you bidirectional operation between subversion and git. First of all make sure you have all you might need when working with git. Make sure to use a current version of git (I’m refering to version >=1.5.3). Just execute the following command line on your Debian system to install all relevant packages:
aptitude install \
git-buildpackage git-core git-cvs git-daemon-run \
git-doc git-email git-gui git-load-dirs git-svn \
gitk gitweb qgit
Now let’s start with some general and basic configuration:
# Remove directories from the SVN tree if there
# are no files left behind, configure it globaly:
git config --global svn.rmdir=true
# Want some more global, personal git configuration?
for line in  
  user.name=Michael Prokop 
  user.email=foo@example.invalid 
  color.diff=auto 
  color.diff.new=cyan 
  color.diff.old=magenta 
  color.diff.frag=yellow 
  color.diff.meta=green 
  color.diff.commit=normal 
do
  git config --global $line
done
Check out man git-config for much more details about configuration options. First tip: set ‘g’ as an alias for git so you don’t have to type that much. I’ll write the long version in the following examples so copy/paste works for everyone. Make sure to use the short options of git itself as well: use ‘git co’ for example instead of ‘git checkout’. You can define your own aliases inside git as well - either manually in ~/.gitconfig or running something like:
git config --global alias.st status
Enough pre-configuration for now. It’s time to checkout the SVN repository:
# Check out the SVN repository and set 'svn/' as
# prefix for the branches:
git svn clone -s --prefix=svn/ \
https://svn.tugraz.at/svn/$project foobar && 
cd foobar
# Adjust svn:ignore settings within git:
git svn show-ignore >> .git/info/exclude
# List all branches:
git branch -a
# List all remote branches:
git branch -r
# Rebase your local changes against the
# latest changes in SVN (kind of 'svn up'):
git svn rebase
# Checkout a specific branch:
git checkout $branch
Ok so far? But what do we have to do if we want to work on the upstream source and are allowed to commit/push directly to the repository? Let’s see how to work on that without using branches:
# Hack:
$EDITOR foobar
# Check status
git st[atus]
# List diff:
git diff [foobar]
# Commit it with a commit message using $EDITOR:
git commit -a
# Now commit your changes (that were committed
# previously using git) to SVN, as well as
# automatically updating your working HEAD:
git svn dcommit
But what should we do if we do not have commit rights? Let’s create our own branch and send a patch via mail to upstream:
# Make a new branch:
git checkout -b mikas_demo_patch
# and hack...
$EDITOR
# Commit all changes:
git ci -a -m 'Best patch but worst commit msg ever'
# ... and prepare patch[es]:
git format-patch -s -p -n master
# Now send mail(s) either use git-send-email:
git send-email --to foo@example.invalid *.patch
# ... or if you prefer mutt instead (short zsh syntax):
for f in *.patch ; mutt -H $f
You got a mail from someone else and would like to incorporate changes from the attached patch in your repository? Just store the mail in a seperate mailbox (use save-message in mutt for example, keybinding ’s’ by default), then execute:
# Apply a [series of] patch[es] from a mailbox
git am /path/to/mailbox
Want to work on a seperate branch and rebase your work with upstream?
# First of all make sure to use recent sources...
# So pull when using plain git:
git pull -u
# .. or when using git-svn use:
git svn rebase
# Then create a new branch:
git checkout -b mika
# Hack:
$EDITOR
# Commit:
git ci -a -m 'Best patch but worst commit msg ever'
# Switch to master branch:
git checkout master
# Pull again when using plain git:
git pull -u
# .. or when using git-svn use:
git svn rebase
# Finally switch back
git checkout mika
# Now rebase it with plain git using:
git rebase origin/master
# ... or when using git-svn:
git svn rebase
# Now check out the last 5 commits:
git log -n5
Another branch-session might look like:
git co -b foo
$EDITOR
git ci -a -m 'foo changes'
git co master
git co -b bar
$EDITOR
git ci -a -m 'bar changes''
git co foo
git rebase bar
git log -n5
git st
git branch
Pfuhhh? Right. :) Now it’s time to check out another cool feature: git stash, which is just great when pulling into a dirty tree or when suffering from interrupted workflow. Demo:
git stash
git pull / fetch+rebase
$EDITOR # fix conflicts
git commit -a -m "Fix in a hurry"
git stash apply
git stash clear # unless you want to keep the stash
git reset rocks as well:
# List all recent actions:
git reflog
# Now undo the last action:
git reset --hard HEAD@ 0 
How to get rid of branches?
# Delete a branch. The branch must be fully merged:
git branch -d remove_me_branch
# Delete a branch irrespective of its index status:
git branch -D remove_me_branch
# Delete a remote branch:
git push reponame :branch
Repack a git repository to minimize its disk usage:
git pack-refs --prune
git reflog expire --all
git repack -a -d -f -l
git prune
git rerere gc
Use git cherry to find commits not merged upstream. Another really cool feature is the interactive rebasing: git rebase –interactive Make sure you are aware of gitk: Screenshot of gitk … and don’t forget to set readable fonts for gitk, like:
[ -r ~/.gitk ]   cat > ~/.gitk << EOF
set mainfont  Arial 10 
set textfont   Courier 10 
set uifont  Arial 10 bold 
EOF
If you prefer a Qt based interface check out qgit. Useful ressources:

Roland Mas: More GForge progress

I'm on a roll... Plans for the near future include continuing to clean up upstream code and maintainer scripts, making sure the installation process is as simple as possible (even for other subpackages), splitting out a few plugins into their own packages. And the big placeholders-in-prepared-SQL-queries audit I mentioned last time, but it may happen progressively rather than in one big go.

Miriam Ruiz: Software patents are buggy

Patents are the best way to improve development, and software inventors have just the natural right to their algorithms and designs. Research and Development in industry wouldn’t just work without patent protection, and technology improvements would just stop, right? Well, I’m not so sure of that. Key arguments against software patents, stolen from Pieter Hintjens’ article:

Edd Dumbill: Smartcard authentication on Linux and Mac

For various reasons, I need to secure access to some resources using two-factor authentication, and thus have been looking at smartcards. These little devices store digital keys and certificates, protected by a passphrase, and calculate digital signatures on-device. Hence the two factors: possession of the card, and knowledge of the password.This sort of scheme is widely used by government agencies and large corporations (and largely reliant on Windows, too), but I wanted to find the low cost way in for the small operator using open source.
OpenSC on Linux
The best starting point for Linux is the OpenSC project. It supports a reasonably broad array of devices, and is well supported by Linux distributions. Using command line tools you can create keys and certificates, as you would in OpenSSL for web servers and so on, and then upload them to the smartcard.Although OpenSSH source code has support for OpenSC, it is not compiled in by default in Debian and derived distributions. Unfortunately this means a bit of recompilation to get SSH supporting OpenSC. When that's done, you have an SSH implementation that can use an RSA key from your smartcard, and best of all, you can add this key to the ssh-agent like you would with regular keys. The hardwareI ordered two devices, which seemed to have the best support from OpenSC, the Axalto Cryptoflex E-Gate, and an Aladdin eToken. I got these from UsaSmartCard, who have a special section in their catalogue for Open Source compatible products. Both these cards have a USB interface built-in, I didn't want to be toting around an extra card reader in addition to the tokens themselves.
On the MacWhile both the devices worked as advertised under Linux, the experience has been a lot less fruitful under Mac OS 10.5 Leopard. There is a port of the OpenSC project for Mac OS, called SCA. The promise of the integration is great: you can use the on-device keys with apps like Safari and Mail, but there is a change in the way that the daemon responsible for talking to the smartcards (pcscd) works on Leopard, which means OpenSC won't recognise the cards.
With some fiddling, I have managed to force the Cryptoflex device to work with Mac. Unfortunately the Leopard/Darwin source for OpenSSH has diverged significantly enough from the upstream OpenSSH, that I couldn't apply the OpenSC patches. Not having ssh-agent work with the smartcard is a significant nuisance for me, as it's the easiest way to patch in the extra security to deployment processes.The Aladdin eToken just plain didn't work on Leopard. There is a report that Aladdin are working on Leopard drivers, however.I think a small number of mainly US federal smart cards will work out of the box on Leopard, though I've seen a few complaints about these on the Apple forums. It loooks unfortunately like smartcard support slipped through the net a bit. ConclusionSmartcard support is relatively straightforward on Linux. On Mac OS 10.5, it looks like some waiting is in order before things will work properly.

Christian Perrier: Arrived in BLR

I finally arrived in Bangalore. Unfortunately, alone, without suitcase, which Air India apparently managed to lose. So, it will be the first time I experience the happiness of people who don't get their luggage in an airport and have to live for a few days with nothing but the clothes they had on them while travelling. Running around in local shops to get socks or pants wasn't exactly what I planned to do here and I probably won't. So, I'll take the local stance and learn about patience, and wait. The place we're hosted at is *very* nice (B&B, probably with a few other speakers I haven't seen yet). And, it has a really good Internet connection so I feel pretty safe and can give news around. I'm currently waiting for Sam whose flight was apparently delayed (I hope *he* gets his suitcase).... I hope he won't be too much in trouble: we don't want to lose our DPL in India (maybe they want to keep him here, though).

Kartik Mistry: Debian Flyer

* Jaldhar started Debian-Intro project sometime back (I saw this as pamphlet in Indic Developer Meet in 2005!). And we wanted this for Foss.in. I created branch for Foss.in and we have it ready (only small changes, really!).

Adam Rosi-Kessel: Success as a Parent

Success as a parent is when your two year old recognizes and demands, at various times, Joni Mitchell, Paul McCartney (particular tracks), They Might Be Giants, and the White Stripes. And when she knows how to operate her own portable CD player and navigate your cell phone photo library. These are skills that the Class of 2026 is going to need.

Russell Coker: New Bonnie++ Releases

Today I released new versions of my Bonnie++ [1] benchmark. The main new feature (in both the stable 1.03b version and the experimental 1.93d version) is the ability of zcav to write to devices. The feature in question was originally written at the request of some people who had strange performance results when testing SATA disks [2]. Now I plan to focus entirely on the 1.9x branch. I have uploaded 1.03b to Debian/unstable but shortly I plan to upgrade a 1.9x version and to have Lenny include Bonnie++ 2.0x. One thing to note is that Bonnie++ in the 1.9x branch is multi-threaded which does mean that lower performance will be achieved with some combinations of OS and libc. I think that this is valid as many applications that you will care about (EG MySQL and probably all other modern database servers) will only support a threaded mode of operation (at least for the default configuration) and many other applications (EG Apache) will have a threaded option which can give performance benefits. In any case the purpose of a benchmark is not to give a high number that you can boast about, but to identify areas of performance that need improvement. So doing things that your OS might not be best optimised for is a feature! While on this topic, I will never add support for undocumented APIs to the main Bonnie++ and ZCAV programs. The 1.9x branch of Bonnie++ includes a program named getc_putc which is specifically written to test various ways of writing a byte at a time, among other things it uses getc_unlocked() and putc_unlocked() - both of which were undocumented at the time I started using them. Bonnie++ will continue using the locking versions of those functions, last time I tested it meant that the per-char IO tests in Bonnie++ on Linux gave significantly less performance than on Solaris (to the degree that it obviously wasn’t hardware). I think this is fine, everyone knows that IO one character at a time is not optimal anyway so whether your program sucks a little or a lot because of doing such things probably makes little difference.

Biella Coleman: The other AAA s

The (overpriced) Amtrak train is rapidly hurling itself north toward New York City, the vanishing light gently illuminating the first snowfall of the year. I am heading back from the American Anthropological Association annual meetings, which were held in Washington D.C this year. After a year’s hiatus, I attended to present a short version of my paper on hacker conferences, which I have pushed along further to entertain more general questions and ideas about the role of conferences in ensuring forms of solidarity among publics that are dispersed geographically. While there are other events that are far more visceral or more profoundly produce what Emile Durkheim has called collective effervescence, conferences are probably one of the most common social forms for ensuring a steady state of moral solidarity among connected but geographically dispersed groups of people. Their importance and role is often overlooked, I think, because of their sheer ubiquity (and I am sure the fact that many are held in creepy corporate hotels populated by seriously over sized & gaudy furniture where you can sit and sip your overpriced Starbuck’s coffee does not help). But it is because they are so common that I think we need to take them a little more seriously as distinctly 20th century events that combine much older elements of ritual and pilgrimage. Because I have attended so many developer and hacker conferences, which tend to be longer as well as far more more enveloping, festive, and, frankly, well executed than academic ones, I tend to think of academic conferences as tepid, lightweight versions. But as I make my way back home, I am pretty worn yet inspired from this one as I decided to sort of let go to give it my all, sleeping far less than I really should have. I usually hold back some, perhaps because most academic conferences I attend are smack in the middle of the academic year, so my mind is partially occupied with the pile of work that awaits me, somewhat depressingly, at the end of your journey. Academic conferences can also produce a fair bit of anxiety, especially for younglings like myself, given that you are performing your skills (or lack of) and ideas (or lack of) to people you respect and admire too. Perhaps it is also due to the hotel environment, which I find not only particularly uninspiring but in all honesty, sort of soul sucking, though albeit, *very* conveniently so. This time, however, I was not going to let the hotel suck any more soul out of me because I was thrilled to see friends from time’s past, had a great time on my panel on digital subjectivities, and was excited to meet new folks and talk about those topics that I spend a lot of time thinking about. I also think the proliferation of (very cute) babies among my friends and the now visible crow’s feet adorning the smiling eyes of my friends made me feel the passing of time a little more forcefully than really I wanted to. So I did my best to turn that pesky faucet of time of off so as to give way to immersion, drawing those from past into the shared nest of the present, so that I would want to see them again in the future. And in the end, that is the point: social reproduction and shouldn’t procreation be fun? I think so… Now back to that pile of work.

2 December 2007

Christine Spang: media rant

Dear Warner Brothers, As a poor hosed college student, I have spent many a month where I have not bought any movies. Finally, I got some money for my birthday and decided to buy the film March of the Penguins. However, I did not read the very fine print, and when I got home I found that it crashes mplayer, and totem will only play the previews; it is completely unable to play the feature title. I don’t want to copy this goddamn DVD, I only wanted to be able to play it on my computer since the TV room downstairs was full of LARPers at the time. However, due to your ridiculously anti-consumer copy protection, I had to borrow my roommate’s Powerbook in order to accomplish this. I don’t like Macs. I already paid you for the movie; why does my software need to pay you to play the movie? Maybe next time I will download your movie instead of paying you for it. No love, Christine

Steve Kemp: Let the bells ring out for Christmas

In the next week I intend to drop the search engine which archives content posted to Planet Debian. It appears to have very little use, except for myself, and I'm significantly better at bookmarking posts of interest these days. If you'd like to run your own copy the code is available and pretty trivial to reimplement regardless. There are only two parts: Once you've done that you'll have a database populated with blog entries, and you just need to write a little search script. ObRandom: In the time it has been running it has archived 15,464 posts!

Julien Danjou: Testing out rebuildd 0.3.0

awesome beiing in rc state, that leaves me a small amount of spare time. I decided to spend it on rebuildd. I had started the 0.3.0 version back in August, but never touched it again until now. I was afraid because I did not remember in which state I left the code repository. And, good surprise, the code was in a quite good shape! I just implemented and fixed some stuff that were reported on the BTS, and then, I only had to test it out. For that I used the servers kindly provided by TuxFamily.org: I stored the MySQL database on whisky. filled it with rebuildd-job add-quinn-diff (new feature in 0.3.0) and then started rebuildd on each node. And then I saw the 2 hosts starting to grab, lock jobs, build packages on each side. Wonderful. That just works. :-) rebuildd-job stats says that 20 % of the archive is now built in less than 24h, seems fast, cool. Bad point is that I'm building and trashing logs into /dev/null because I've no QA idea to implement right now.

Brandon Holtsclaw: Brandon s Holiday Computer Fund

I’m a developer, and my primary tool is my computer. Unfortunately, about 3 months ago, my computer died an untimely death, and I have resorted to using a pentium 200MHz machine with 256MB Ram, which lets me keep up with regular communications, but significantly slows the pace of development. As a computer is a big purchase, and represents most of what I want to receive for the holidays, I’ve set up a fundraiser so that people who wanted to help towards this gift could do so without needing to purchase the entire thing (and to avoid the all too common problem of receiving 8 video cards and no RAM). www.fundable.com allows me to accept pledges via paypal but NOT collect any unless the goal is met, so if you feel giving and pledge something, it will only be charged if the goal is met ( this is set at $250, which seems to be the minimum for a decent system, if more is collected, I can look at something better). You can read more about how fundable works from www.fundable.com/faq, and I’m more than happy to answer any questions via email, IRC, Jabber, etc.

Ian Murdock: Abundance and open source business models

Matt Asay: “[F]ocus on maximizing abundance, and then sell value around minimizing the complexity inherent in abundance.. The old model was to assume that the value was in the software itself and to therefore lock it up. It turns out, however, as Tim O’Reilly notes, that data is the real value, not bits and bytes. You don’t discover or, rather, uncover, that value until you have abundance.”

Steve Kemp: to let the insects in

My migration to mercurial is now complete. I've completed the last step, which was the migration of all the $foo-commits mailing lists. It is at times like this that I remember two things: Right now I'm using ecartis for my mailing lists, primarily because it isn't mailman. (Long story). For making archives of mbox files I'm using hypermail. The latter I intend to change as soon as I can find something else to use. It isn't attractive, but it is in the Debian archive and seems reliable. Since I was changing things around already I've centralised the list-archive making, and started using the haschanged tool to avoid rebuilding the archives i there are no new posts. That works nicely.

Thomas Girard: Fun with templates

At work we had to use two C libraries defining structures with different size but same name. Function names were different though, so we believed no symbol clash would occur. We thought if we used the headers from each library in a different compilation unit we'd be safe. But we were wrong. The code compiled fine but crashed at runtime. Why? Because we used templates within these compilation units, and this generated weak symbols with the very same name. The linker then discarded duplicate symbols, and since structure size was different we got a crash. Let's reproduce this on a small example:
/* A.h */
#ifndef A_H
#define A_H
struct Data   int an_int;  ;
#endif
/* B.h */
#ifndef B_H
#define B_H
struct Data   char a_buffer[65];  ;
#endif
/* UsingA.cpp */
#inlude "A.h"
#inlude <deque>
static std::deque<Data> a_datas;
std::size_t get_a_size()   return a_datas.size();  
/* UsingB.cpp */
#inlude "B.h"
#inlude <deque>
static std::deque<Data> b_datas;
std::size_t get_b_size()   return b_datas.size();  
/* Main.cpp */
int main(int argc, char* argv[])    return 0;  
We compile these files:
$ g++ -c -I . UsingA.cpp UsingB.cpp Main.cpp
$ g++ -o Main UsingA.o UsingB.o Main.o
and inspect what got generated in UsingA.o, choosing the call to size() to reduce the output:
$ nm -C UsingA.o   grep '::size()'
0000000000000000 W std::deque<Data, std::allocator<Data> >::size() const
Likewise in UsingB.o:
$ nm -C UsingB.o   grep '::size()'
0000000000000000 W std::deque<Data, std::allocator<Data> >::size() const
g++ has generated code for the deque we're using. That's how templates work: they get "expanded" in the compilation unit using them. So far so good. Now if we look in Main:
$ nm -C Main   grep '::size()'
0000000000400a64 W std::deque<Data, std::allocator<Data> >::size() const
we see there's only a single symbol in the resulting binary. Because the symbols are weak (see the W in nm output), g++ silently discards one version, say the version in UsingB.o. (If they were not weak, link would fail because of duplicate symbols. And every C++ program would fail to link.) Therefore any call on b_datas is likely to fail: the deque code called will not use the right definition of Data. Lesson learned: avoid data structures with the same name.

Next.

Previous.