PRG := st-util
+DEBUG := #-DDEBUG
all: $(PRG)
%.o: ../src/%.c
gcc -O3 -g3 -Wall -Werror -c -std=gnu99 -MMD -MP \
- -fno-strict-aliasing -Wno-unused \
+ -fno-strict-aliasing -Wno-unused $(DEBUG) \
-MF"$(@:%.o=%.d)" -MT"$(@:%.o=%.d)"\
-o "$@" "$<"
return 1;
}
- //printf("recv: %s\n", packet);
+ #ifdef DEBUG
+ printf("recv: %s\n", packet);
+ #endif
char* reply = NULL;
}
if(reply) {
- //printf("send: %s\n", reply);
+ #ifdef DEBUG
+ printf("send: %s\n", reply);
+ #endif
int result = gdb_send_packet(client, reply);
if(result != 0) {