[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: [RFR] man://manpages-de/getopt.3.2




Diese Manpage gehört zu den etwas fetteren Exemplaren:

33K PO, 84 (88) Strings, 356 Zeilen Manpage.
Hier jetzt das zweite von drei Häppchen:
12K für 126 Zeilen Ausgabe.

Mit der üblichen Bitte,
   Martin


#. type: TP
#, no-wrap
msgid "I<name>"
msgstr "I<name>"

#. type: Plain text
msgid "is the name of the long option."
msgstr "ist der Name der langen Option."

#. type: TP
#, no-wrap
msgid "I<has_arg>"
msgstr "I<has_arg>"

#. type: Plain text
msgid ""
"is: B<no_argument> (or 0) if the option does not take an argument; "
"B<required_argument> (or 1) if the option requires an argument; or "
"B<optional_argument> (or 2) if the option takes an optional argument."
msgstr ""
"ist: B<no_argument> (oder 0) falls die Option kein Argument erwartet, "
"B<required_argument> (oder 1) falls die Option ein Argument benötigt oder "
"B<optional_argument> (oder 2) falls die Option ein optionales Argument "
"erwartet."

#. type: TP
#, no-wrap
msgid "I<flag>"
msgstr "I<flag>"

#. type: Plain text
msgid ""
"specifies how results are returned for a long option.  If I<flag> is NULL, "
"then B<getopt_long>()  returns I<val>.  (For example, the calling program "
"may set I<val> to the equivalent short option character.)  Otherwise, "
"B<getopt_long>()  returns 0, and I<flag> points to a variable which is set "
"to I<val> if the option is found, but left unchanged if the option is not "
"found."
msgstr ""
"gibt an, wie für eine lange Option Ergebnisse zurückgegeben werden. Falls "
"I<flag> NULL ist, dann gibt B<getopt_long>() I<val> zurück. (Zum Beispiel "
"kann das aufrufende Programm I<val> auf das Zeichen der äquivalenten "
"Kurzoption setzen.) Anderenfalls gibt B<getopt_long>() 0 zurück und I<flag> "
"zeigt auf eine Variable, die auf I<val> gesetzt wird, falls die Option "
"gefunden wird, und die unverändert gelassen wird, falls die Option nicht "
"gefunden wird."

#. type: TP
#, no-wrap
msgid "I<val>"
msgstr "I<val> "

#. type: Plain text
msgid ""
"is the value to return, or to load into the variable pointed to by I<flag>."
msgstr ""
"ist der Wert, der zurückzugeben oder in die Variable zu laden ist, auf die "
"I<flag> zeigt."

#. type: Plain text
msgid "The last element of the array has to be filled with zeros."
msgstr "Das letzte Element des Feldes muss mit Nullen gefüllt werden."

# s/wird/ist/?
#. type: Plain text
msgid ""
"If I<longindex> is not NULL, it points to a variable which is set to the "
"index of the long option relative to I<longopts>."
msgstr ""
"Falls I<longindex> nicht B<NULL> ist, zeigt er auf eine Variable, welche auf "
"den Index der langen Option relativ zu I<longopts> gesetzt wird."

#. type: Plain text
msgid ""
"B<getopt_long_only>()  is like B<getopt_long>(), but \\(aq-\\(aq as well as "
"\"--\" can indicate a long option.  If an option that starts with \\(aq-"
"\\(aq (not \"--\") doesn't match a long option, but does match a short "
"option, it is parsed as a short option instead."
msgstr ""
"B<getopt_long_only>() ist wie B<getopt_long>(), jedoch kann \\(aq-\\(aq "
"ebenso wie "
"»--« eine lange Option anzeigen. Falls eine Option, die mit \\(aq-\\(aq "
"anfängt (nicht »--«), zu keiner langen Option passt, jedoch zu einer kurzen "
"Option, so wird sie wie eine kurze Option behandelt."

#. type: SH
#, no-wrap
msgid "RETURN VALUE"
msgstr "RÃ?CKGABEWERT"

#. type: Plain text
msgid ""
"If an option was successfully found, then B<getopt>()  returns the option "
"character.  If all command-line options have been parsed, then B<getopt>()  "
"returns -1.  If B<getopt>()  encounters an option character that was not in "
"I<optstring>, then \\(aq?\\(aq is returned.  If B<getopt>()  encounters an "
"option with a missing argument, then the return value depends on the first "
"character in I<optstring>: if it is \\(aq:\\(aq, then \\(aq:\\(aq is "
"returned; otherwise \\(aq?\\(aq is returned."
msgstr ""
"Falls eine Option erfolgreich gefunden wurde, gibt B<getopt>() das "
"Optionszeichen zurück. Falls alle Befehlszeilenargumente erfolgreich "
"ausgewertet wurden, gibt B<getopt>() -1 zurück. Falls B<getopt>() ein "
"Optionszeichen antrifft, das nicht in I<optstring> enthalten war, wird "
"\\(aq?\\(aq zurückgegeben. Falls B<getopt>() auf eine Option trifft, der ein "
"Argument fehlt, hängt der Rückgabewert vom ersten Zeichen in I<optstring>ab: "
"Falls es ein \\(aq:\\(aq ist, wird \\(aq:\\(aq zurückgegeben; anderenfalls "
"\\(aq?\\(aq."

#. type: Plain text
msgid ""
"B<getopt_long>()  and B<getopt_long_only>()  also return the option "
"character when a short option is recognized.  For a long option, they return "
"I<val> if I<flag> is NULL, and 0 otherwise.  Error and -1 returns are the "
"same as for B<getopt>(), plus \\(aq?\\(aq for an ambiguous match or an "
"extraneous parameter."
msgstr ""
"B<getopt_long>() und B<getopt_long_only>() geben auch das Optionszeichen "
"zurück, wenn eine kurze Option gefunden wurde. Für eine lange Option geben "
"sie I<val> zurück, wenn I<flag> B<NULL> ist, anderenfalls 0.  Fehler- und "
"-1-Rückgaben sind wie bei B<getopt>(), zusätzlich jedoch \\(aq-\\(aq für eine "
"unzureichende �bereinstimmung oder einen überzähligen Parameter."

#. type: SH
#, no-wrap
msgid "ENVIRONMENT"
msgstr "UMGEBUNGSVARIABLEN"

#. type: TP
#, no-wrap
msgid "B<POSIXLY_CORRECT>"
msgstr "B<POSIXLY_CORRECT>"

#. type: Plain text
msgid ""
"If this is set, then option processing stops as soon as a nonoption argument "
"is encountered."
msgstr ""
"Falls dies gesetzt ist, dann stoppt die Optionsbearbeitung, sobald ein "
"Argument auftritt, das keine Option ist."

#. type: TP
#, no-wrap
msgid "B<_E<lt>PIDE<gt>_GNU_nonoption_argv_flags_>"
msgstr "B<_E<lt>PIDE<gt>_GNU_nonoption_argv_flags_>"

#. type: Plain text
msgid ""
"This variable was used by B<bash>(1)  2.0 to communicate to glibc which "
"arguments are the results of wildcard expansion and so should not be "
"considered as options.  This behavior was removed in B<bash>(1)  version "
"2.01, but the support remains in glibc."
msgstr ""
"Diese Variable wurde von der B<bash>(1)-Version 2.0 genutzt, um der Glibc zu "
"kommunizieren, welche Argumente Ergebnis der Ersetzung von Platzhaltern und "
"somit nicht als Optionen anzusehen sind. Dieses Verhalten wurde in der B<bash>"
"(1)-Version "
"2.01 entfernt, wird aber weiterhin von der Glibc unterstützt."

#. type: SH
#, no-wrap
msgid "CONFORMING TO"
msgstr "KONFORM ZU"

#. type: TP
#, no-wrap
msgid "B<getopt>():"
msgstr "B<getopt>():"

# FIXME: use of we
#. type: Plain text
msgid ""
"POSIX.2 and POSIX.1-2001, provided the environment variable "
"B<POSIXLY_CORRECT> is set.  Otherwise, the elements of I<argv> aren't really "
"const, because we permute them.  We pretend they're const in the prototype "
"to be compatible with other systems."
msgstr ""
"POSIX.2 und POSIX.1-2001, vorausgesetzt, die Umgebungsvariable "
"POSIXLY_CORRECT ist gesetzt.  "
"Anderenfalls sind die Elemente von I<argv> nicht wirklich konstant, da wir "
"sie vertauschen.  Wir geben im Prototypen vor, sie seien konstant, um "
"kompatibel zu anderen Systemen zu sein."

#. type: Plain text
msgid ""
"The use of \\(aq+\\(aq and \\(aq-\\(aq in I<optstring> is a GNU extension."
msgstr ""
"Die Verwendung von \\(aq+\\(aq und \\(aq-\\(aq in I<optstring> ist eine GNU-"
"Erweiterung."

#. type: Plain text
msgid ""
"On some older implementations, B<getopt>()  was declared in I<E<lt>stdio."
"hE<gt>>.  SUSv1 permitted the declaration to appear in either I<E<lt>unistd."
"hE<gt>> or I<E<lt>stdio.hE<gt>>.  POSIX.1-2001 marked the use of "
"I<E<lt>stdio.hE<gt>> for this purpose as LEGACY.  POSIX.1-2001 does not "
"allow the declaration to appear in I<E<lt>stdio.hE<gt>>."
msgstr ""
"In einigen älteren Implementierungen wurde B<getopt>() in I<E<lt>stdio."
"hE<gt>> deklariert. SUSv1 gestattete die Deklaration entweder in I<E<lt>"
"unistd."
"hE<gt>> oder I<E<lt>stdio.hE<gt>>. POSIX.1-2001 kennzeichnete die Verwendung "
"von "
"I<E<lt>stdio.hE<gt>> zu diesem Zweck als LEGACY. POSIX.1-2001 gestattet "
"nicht, dass diese Deklaration in I<E<lt>stdio.hE<gt>> enthalten ist."

#. type: TP
#, no-wrap
msgid "B<getopt_long>() and B<getopt_long_only>():"
msgstr "B<getopt_long>() und B<getopt_long_only>():"

# Holpert etwas.
#. type: Plain text
msgid "These functions are GNU extensions."
msgstr "Diese Funktionen sind GNU-Erweiterungen."

#. type: SH
#, no-wrap
msgid "NOTES"
msgstr "ANMERKUNGEN"

#. type: Plain text
msgid ""
"A program that scans multiple argument vectors, or rescans the same vector "
"more than once, and wants to make use of GNU extensions such as \\(aq+\\(aq "
"and \\(aq-\\(aq at the start of I<optstring>, or changes the value of "
"B<POSIXLY_CORRECT> between scans, must reinitialize B<getopt>()  by "
"resetting I<optind> to 0, rather than the traditional value of 1.  "
"(Resetting to 0 forces the invocation of an internal initialization routine "
"that rechecks B<POSIXLY_CORRECT> and checks for GNU extensions in "
"I<optstring>.)"
msgstr ""
"Ein Programm, das mehrere Argumentvektoren oder denselben Argumentvektor "
"mehrfach auswertet und GNU-Erweiterungen wie beispielsweise \\(aq+\\(aq und "
"\\(aq-\\(aq am Anfang von I<optstring> nutzen möchte oder zwischen den "
"Auswertungen den Wert von B<POSIXLY_CORRECT> ändert, muss B<getopt>() neu "
"initialisieren, indem es I<optind> auf 0 statt des traditionellen Wertes 1 "
"setzt. (Das Rücksetzen auf 0 erzwingt den Aufruf einer internen "
"Initialisierungsroutine, die erneut B<POSIXLY_CORRECT> prüft und in I<"
"optstring> nach GNU-Erweiterungen sucht.)"

#. type: SH
#, no-wrap
msgid "BUGS"
msgstr "FEHLER"

#. type: Plain text
msgid ""
"The POSIX.2 specification of B<getopt>()  has a technical error described in "
"POSIX.2 Interpretation 150.  The GNU implementation (and probably all other "
"implementations) implements the correct behavior rather than that specified."
msgstr ""
"Die POSIX.2-Spezifikation von B<getopt>() enthält einen technischen Fehler, "
"der in der POSIX.2-Interpretation 150 beschrieben ist. Die GNU-"
"Implementierung (und wahrscheinlich alle anderen Implementierungen) "
"implementieren das korrekte Verhalten statt des spezifizierten."

#. type: SH
#, no-wrap
msgid "EXAMPLE"
msgstr "BEISPIEL"

#. type: Plain text
msgid ""
"The following trivial example program uses B<getopt>()  to handle two "
"program options: I<-n>, with no associated value; and I<-t val>, which "
"expects an associated value."
msgstr ""
"Das folgende triviale Beispielprogramm verwendet B<getopt>(), um zwei "
"Programmoptionen zu verarbeiten: I<-n> ohne zugehörigen Wert und I<-t Wert>, "
"der einen zugehörigen Wert erwartet."

#. type: Plain text
#, no-wrap
msgid ""
"#include E<lt>unistd.hE<gt>\n"
"#include E<lt>stdlib.hE<gt>\n"
"#include E<lt>stdio.hE<gt>\n"
msgstr ""
"#include E<lt>unistd.hE<gt>\n"
"#include E<lt>stdlib.hE<gt>\n"
"#include E<lt>stdio.hE<gt>\n"

#. type: Plain text
#, no-wrap
msgid ""
"int\n"
"main(int argc, char *argv[])\n"
"{\n"
"    int flags, opt;\n"
"    int nsecs, tfnd;\n"
msgstr ""
"int\n"
"main(int argc, char *argv[])\n"
"{\n"
"    int flags, opt;\n"
"    int nsecs, tfnd;\n"

# nsecs übersetzen ?
##  Ende von Teil 2 der formatierten Ausgabe: Zeile 246
#. type: Plain text
#, no-wrap
msgid ""
"    nsecs = 0;\n"
"    tfnd = 0;\n"
"    flags = 0;\n"
"    while ((opt = getopt(argc, argv, \"nt:\")) != -1) {\n"
"        switch (opt) {\n"
"        case \\(aqn\\(aq:\n"
"            flags = 1;\n"
"            break;\n"
"        case \\(aqt\\(aq:\n"
"            nsecs = atoi(optarg);\n"
"            tfnd = 1;\n"
"            break;\n"
"        default: /* \\(aq?\\(aq */\n"
"            fprintf(stderr, \"Usage: %s [-t nsecs] [-n] name\\en\",\n"
"                    argv[0]);\n"
"            exit(EXIT_FAILURE);\n"
"        }\n"
"    }\n"
msgstr ""
"    nsecs = 0;\n"
"    tfnd = 0;\n"
"    flags = 0;\n"
"    while ((opt = getopt(argc, argv, \"nt:\")) != -1) {\n"
"        switch (opt) {\n"
"        case \\(aqn\\(aq:\n"
"            flags = 1;\n"
"            break;\n"
"        case \\(aqt\\(aq:\n"
"            nsecs = atoi(optarg);\n"
"            tfnd = 1;\n"
"            break;\n"
"        default: /* \\(aq?\\(aq */\n"
"            fprintf(stderr, \"Verwendung: %s [-t nsecs] [-n] Name\\en\",\n"
"                    argv[0]);\n"
"            exit(EXIT_FAILURE);\n"
"        }\n"
"    }\n"

Reply to: