1 /* gEDA - GPL Electronic Design Automation
2 * gschlas - gEDA Load and Save
3 * Copyright (C) 2002-2010 Ales Hvezda
4 * Copyright (C) 2002-2010 gEDA Contributors (see ChangeLog for details)
6 * This program is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation; either version 2 of the License, or
9 * (at your option) any later version.
11 * This program is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details.
16 * You should have received a copy of the GNU General Public License
17 * along with this program; if not, write to the Free Software
18 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
31 #include <libgeda/libgeda.h>
33 #include "../include/globals.h"
34 #include "../include/prototype.h"
36 #ifdef HAVE_LIBDMALLOC
40 #define OPTIONS "hqveu"
42 #ifndef OPTARG_IN_UNISTD
50 printf("Usage: %s [OPTIONS] filename1 ... filenameN\n", cmd
);
51 printf(" -e Embed all components/pictures\n");
52 printf(" -u Unembed all components/pictures\n");
53 printf(" -q Quiet mode\n");
54 printf(" -v Verbose mode on\n");
55 printf(" -h This message\n");
60 int parse_commandline(int argc
, char *argv
[])
64 while ((ch
= getopt(argc
, argv
, OPTIONS
)) != -1) {
98 if (embed_mode
&& unembed_mode
) {
100 "Cannot specify both -e and -u at the same time (ignoring both flags)\n");
102 unembed_mode
= FALSE
;