From 0b02847989970a190c2cfaec4d1abaa1f616284a Mon Sep 17 00:00:00 2001 From: "Steinar H. Gunderson" Date: Sat, 3 Jan 2009 11:15:43 +0100 Subject: [PATCH] Rename input.h to bitsource.h (and friends). --- Makefile | 14 +++++++------- input.c => bitsource.c | 2 +- input.h => bitsource.h | 6 +++--- input_test.c => bitsource_test.c | 2 +- dehuff.h | 2 +- 5 files changed, 13 insertions(+), 13 deletions(-) rename input.c => bitsource.c (98%) rename input.h => bitsource.h (97%) rename input_test.c => bitsource_test.c (99%) diff --git a/Makefile b/Makefile index 2adef55..4784dce 100644 --- a/Makefile +++ b/Makefile @@ -8,11 +8,11 @@ UNSTUFF_TEST_OBJS=unstuff.o unstuff_test.o unstuff_test: $(UNSTUFF_TEST_OBJS) $(CC) $(LDFLAGS) -o $@ $(UNSTUFF_TEST_OBJS) -INPUT_TEST_OBJS=input.o input_test.o -input_test: $(INPUT_TEST_OBJS) - $(CC) $(LDFLAGS) -o $@ $(INPUT_TEST_OBJS) +BITSOURCE_TEST_OBJS=bitsource.o bitsource_test.o +bitsource_test: $(BITSOURCE_TEST_OBJS) + $(CC) $(LDFLAGS) -o $@ $(BITSOURCE_TEST_OBJS) -DEHUFF_TEST_OBJS=dehuff.o input.o dehuff_test.o +DEHUFF_TEST_OBJS=dehuff.o bitsource.o dehuff_test.o dehuff_test: $(DEHUFF_TEST_OBJS) $(CC) $(LDFLAGS) -o $@ $(DEHUFF_TEST_OBJS) @@ -20,15 +20,15 @@ BYTESOURCE_TEST_OBJS=bytesource.o choice.o unstuff.o bytesource_test.o bytesource_test: $(BYTESOURCE_TEST_OBJS) $(CC) $(LDFLAGS) -o $@ $(BYTESOURCE_TEST_OBJS) -tests: unstuff_test input_test dehuff_test bytesource_test +tests: unstuff_test bitsource_test dehuff_test bytesource_test clean: $(RM) $(UNSTUFF_TEST_OBJS) unstuff_test - $(RM) $(INPUT_TEST_OBJS) input_test + $(RM) $(BITSOURCE_TEST_OBJS) bitsource_test $(RM) $(DEHUFF_TEST_OBJS) dehuff_test $(RM) $(DEHUFF_TEST_OBJS) bytesource_test test: tests ./unstuff_test - ./input_test + ./bitsource_test ./dehuff_test ./bytesource_test diff --git a/input.c b/bitsource.c similarity index 98% rename from input.c rename to bitsource.c index 6c4630f..72b143b 100644 --- a/input.c +++ b/bitsource.c @@ -3,7 +3,7 @@ #include #include -#include "input.h" +#include "bitsource.h" #define MARKER_CHAR 0xff #define STUFF_MARKER 0x00 diff --git a/input.h b/bitsource.h similarity index 97% rename from input.h rename to bitsource.h index 19315e5..e5bdd28 100644 --- a/input.h +++ b/bitsource.h @@ -1,5 +1,5 @@ -#ifndef _INPUT_H -#define _INPUT_H 1 +#ifndef _BITSOURCE_H +#define _BITSOURCE_H 1 #include #include @@ -93,4 +93,4 @@ static inline unsigned peek_bits(struct bit_source* source, unsigned num_bits) return (source->bits >> (BITRESERVOIR_SIZE - num_bits)); } -#endif /* !defined(_INPUT_H) */ +#endif /* !defined(_BITSOURCE_H) */ diff --git a/input_test.c b/bitsource_test.c similarity index 99% rename from input_test.c rename to bitsource_test.c index 57fae74..2b5217f 100644 --- a/input_test.c +++ b/bitsource_test.c @@ -4,7 +4,7 @@ #include #include -#include "input.h" +#include "bitsource.h" struct custom_read_userdata { uint8_t* bytes; diff --git a/dehuff.h b/dehuff.h index 3d3d8c5..728c623 100644 --- a/dehuff.h +++ b/dehuff.h @@ -6,7 +6,7 @@ #include #include "bytesource.h" -#include "input.h" +#include "bitsource.h" // About 99% of all Huffman codes are <= 8 bits long (see codelen.txt), // and it's what libjpeg uses. Thus, it seems like a reasonable size. -- 2.39.2