Skip to content

Commit

Permalink
close to have the memory leak plugged
Browse files Browse the repository at this point in the history
git-svn-id: https://cowfish.unh.edu/projects/schwehr/trunk/src/libais@13670 a19cddd1-5311-0410-bb07-9ca93daf0f0b
  • Loading branch information
schwehr committed May 9, 2010
1 parent a600287 commit 7601f5d
Show file tree
Hide file tree
Showing 6 changed files with 216 additions and 146 deletions.
18 changes: 13 additions & 5 deletions Makefile
@@ -1,10 +1,12 @@
VERSION:=${shell cat VERSION}

CXXFLAGS :=
#CXXFLAGS += -O3 -funroll-loops -fexpensive-optimizations -DNDEBUG
#CXXFLAGS += -ffast-math

CXXFLAGS := -g3 -O0
CXXFLAGS += -D_GLIBCXX_DEBUG
#CXXFLAGS := -g3 -O0
CXXFLAGS := -g3 -O2
#CXXFLAGS += -D_GLIBCXX_DEBUG # Appears broken
CXXFLAGS += -Wall
CXXFLAGS += -Wimplicit
CXXFLAGS += -pedantic
Expand Down Expand Up @@ -54,8 +56,8 @@ tar:

# Remove the NDEBUG that python tries to use
python2:
CFLAGS="-m32 -O3 -funroll-loops -fexpensive-optimizations -ffast-math" /sw/bin/python2.6 setup.py build
# CFLAGS="-m32 -O0 -g -D_GLIBCXX_DEBUG -UNDEBUG" /sw/bin/python2.6 setup.py build
CFLAGS="-m32 -O0 -g -UNDEBUG" /sw/bin/python2.6 setup.py build
# CFLAGS="-m32 -O3 -funroll-loops -fexpensive-optimizations -ffast-math" /sw/bin/python2.6 setup.py build

python3:
CFLAGS="-m32 -O0 -g -D_GLIBCXX_DEBUG -UNDEBUG" /sw/bin/python3 setup.py build
Expand All @@ -71,11 +73,16 @@ clean:
#.cpp.o:
# ${CXX} -c $< ${CXXFLAGS}

test_libais: ${OBJS} test_libais.cpp
test_libais: ${OBJS} test_libais.cpp ais.h
@echo SRCS: ${SRCS}
@echo OBJS: ${OBJS}
${CXX} -o $@ ${OBJS} test_libais.cpp ${CXXFLAGS}

ais_decode_normed: ${OBJS} ais_decode_normed.o ais.h
@echo SRCS: ${SRCS}
@echo OBJS: ${OBJS}
${CXX} -o $@ ${OBJS} ais_decode_normed.o ${CXXFLAGS}

# Hard coded depends
ais.o: ais.h
ais123.o: ais.h
Expand All @@ -87,3 +94,4 @@ ais18.o: ais.h
ais19.o: ais.h
ais_py.o: ais.h
test_libais.o: ais.h

1 change: 1 addition & 0 deletions ais.h
Expand Up @@ -6,6 +6,7 @@
#include <string>
#include <cassert>
#include <vector>
#include <cstring>

#include <iostream> // for checkpoint

Expand Down
1 change: 0 additions & 1 deletion ais1_2_3.cpp
Expand Up @@ -8,7 +8,6 @@
#include <cassert>
#include <cmath>


Ais1_2_3::Ais1_2_3(const char *nmea_payload) {
assert(nmea_payload);
init();
Expand Down

0 comments on commit 7601f5d

Please sign in to comment.