diff options
author | giraffedata <giraffedata@9d0c8265-081b-0410-96cb-a4ca84ce46f8> | 2007-12-09 18:22:45 +0000 |
---|---|---|
committer | giraffedata <giraffedata@9d0c8265-081b-0410-96cb-a4ca84ce46f8> | 2007-12-09 18:22:45 +0000 |
commit | 9eda2942da8ab522c11b8c14a91fd368d11008e7 (patch) | |
tree | 491c95857554885a289a8070fd875ce53d036361 /converter/ppm/ppmtompeg | |
parent | bce598c9d7969f0637ce2e7e3a5bc696ab04d2f5 (diff) | |
download | netpbm-mirror-9eda2942da8ab522c11b8c14a91fd368d11008e7.tar.gz netpbm-mirror-9eda2942da8ab522c11b8c14a91fd368d11008e7.tar.xz netpbm-mirror-9eda2942da8ab522c11b8c14a91fd368d11008e7.zip |
remove hardcoded paths for rm, cpp
git-svn-id: http://svn.code.sf.net/p/netpbm/code/trunk@482 9d0c8265-081b-0410-96cb-a4ca84ce46f8
Diffstat (limited to 'converter/ppm/ppmtompeg')
-rw-r--r-- | converter/ppm/ppmtompeg/specifics.c | 45 |
1 files changed, 20 insertions, 25 deletions
diff --git a/converter/ppm/ppmtompeg/specifics.c b/converter/ppm/ppmtompeg/specifics.c index c7bbfb5b..38e8fc43 100644 --- a/converter/ppm/ppmtompeg/specifics.c +++ b/converter/ppm/ppmtompeg/specifics.c @@ -47,12 +47,6 @@ #include <string.h> #include "prototypes.h" -/*====================* - * System Information * - *====================*/ - -#define CPP_LOC "/lib/cpp" - /*==================* * GLOBAL VARIABLES * *==================*/ @@ -153,26 +147,27 @@ static char version = -1; * *================================================================ */ -void Specifics_Init() -{ - char command[1100]; - FILE *specificsFP; - - sprintf(command, "/bin/rm -f %s.cpp", specificsFile); - system(command); - sprintf(command, "%s -P %s %s %s.cpp", - CPP_LOC, specificsDefines, specificsFile, specificsFile); - system(command); - strcat(specificsFile, ".cpp"); - if ((specificsFP = fopen(specificsFile, "r")) == NULL) { - fprintf(stderr, "Error with specifics file, cannot open %s\n", specificsFile); - exit(1); - } - printf("Specifics file: %s\n", specificsFile); - Parse_Specifics_File(specificsFP); - sprintf(command, "/bin/rm -f %s.cpp", specificsFile); - system(command); +void +Specifics_Init() { + char command[1100]; + FILE *specificsFP; + + sprintf(command, "rm -f %s.cpp", specificsFile); + system(command); + sprintf(command, "cpp -P %s %s %s.cpp", + specificsDefines, specificsFile, specificsFile); + system(command); + strcat(specificsFile, ".cpp"); + if ((specificsFP = fopen(specificsFile, "r")) == NULL) { + fprintf(stderr, "Error with specifics file, cannot open %s\n", + specificsFile); + exit(1); + } + printf("Specifics file: %s\n", specificsFile); + Parse_Specifics_File(specificsFP); + sprintf(command, "rm -f %s.cpp", specificsFile); + system(command); } |