1 /* upackddir - extracts files from PackdDir archives 2 * Copyright (C) 2003-2004 Fabio Bonelli <fabiobonelli@libero.it> 3 4 * This program is free software; you can redistribute it and/or modify 5 * it under the terms of the GNU General Public License as published by 6 * the Free Software Foundation; either version 2 of the License, or 7 * (at your option) any later version. 8 9 * This program is distributed in the hope that it will be useful, 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 * GNU General Public License for more details. 13 14 * You should have received a copy of the GNU General Public License 15 * along with this program; if not, write to the Free Software 16 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ 17 18 /* $Id: log.h,v 1.4 2004/01/13 16:50:23 fabiob Exp $ */ 19 20 #ifndef _LOG_H 21 #define _LOG_H 22 23 #include <stdio.h> 24 25 #define LOG_DEBUG 0 26 #define LOG_VERBOSE 1 27 #define LOG_NORMAL 2 28 #define LOG_QUIET 3 29 30 #define DEFAULT_LOGLEVEL LOG_NORMAL 31 32 #define LOG(x, ...) \ 33 do { /* if ((l) >= DEFAULT_LOGLEVEL) */ \ 34 fprintf(stderr, "upackddir: " x); \ 35 } \ 36 while (0) 37 38 #define LOGF(x, ...) \ 39 do { /* if ((l) >= DEFAULT_LOGLEVEL) */ \ 40 fprintf(stderr, "upackddir: " x , __VA_ARGS__); \ 41 } \ 42 while (0) 43 44 #endif /* !_LOG_H */ 45