pkt-line: provide a generic reading function with options