Skip to content

Commit

Permalink
fix util/Makefile error (os-features-test-netpbm[-make]); remove TEST…
Browse files Browse the repository at this point in the history
…_NETPBM define
  • Loading branch information
dstndstn committed Jan 3, 2022
1 parent 4b227b6 commit d7855b9
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 5 deletions.
6 changes: 3 additions & 3 deletions util/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -268,7 +268,7 @@ $(INCLUDE_DIR)/os-features-config.h: os-features-test.c
@echo " NETPBM_LIB is $(NETPBM_LIB_ORIG)"
@echo "Testing netpbm..." >> os-features.log
(($(CC) -o os-features-test-netpbm \
$(CPPFLAGS) $(CFLAGS) -DTEST_NETPBM $(NETPBM_INC_ORIG) $^ $(LDFLAGS) $(NETPBM_LIB_ORIG) >> os-features.log && \
$(CPPFLAGS) $(CFLAGS) $(NETPBM_INC_ORIG) $^ $(LDFLAGS) $(NETPBM_LIB_ORIG) >> os-features.log && \
./os-features-test-netpbm >> os-features.log && \
echo "#define HAVE_NETPBM 1") \
|| echo "#define HAVE_NETPBM 0") >> $@.tmp
Expand All @@ -295,8 +295,8 @@ makefile.os-features: os-features-test.c
( \
echo "# This file is generated by util/Makefile."; \
(($(CC) -o os-features-test-netpbm-make \
$(CPPFLAGS) $(CFLAGS) -DTEST_NETPBM $(NETPBM_INC_ORIG) $^ $(LDFLAGS) $(NETPBM_LIB_ORIG) >> os-features-makefile.log && \
./os-features-test-netpbm >> os-features-makefile.log && \
$(CPPFLAGS) $(CFLAGS) $(NETPBM_INC_ORIG) $^ $(LDFLAGS) $(NETPBM_LIB_ORIG) >> os-features-makefile.log && \
./os-features-test-netpbm-make >> os-features-makefile.log && \
echo "HAVE_NETPBM := yes") \
|| (echo "# Astrometry.net didn't find netpbm; not setting HAVE_NETPBM."; \
echo "# See os-features-makefile.log for details."; \
Expand Down
2 changes: 0 additions & 2 deletions util/os-features-test.c
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
#include <stdlib.h>
#include <stdio.h>

#if defined(TEST_NETPBM)
#include <pam.h>
int main(int argc, char** args) {
struct pam img;
Expand All @@ -14,4 +13,3 @@ int main(int argc, char** args) {
printf("the answer is %i\n", img.size);
return 0;
}
#endif

0 comments on commit d7855b9

Please sign in to comment.