diff --git a/Packages/Alpha_shapes_2/demo/Alpha_shapes_2/makefile b/Packages/Alpha_shapes_2/demo/Alpha_shapes_2/makefile index 57be9171caa..c1224aab198 100644 --- a/Packages/Alpha_shapes_2/demo/Alpha_shapes_2/makefile +++ b/Packages/Alpha_shapes_2/demo/Alpha_shapes_2/makefile @@ -14,32 +14,36 @@ include $(CGAL_MAKEFILE) # rajouter CGAL_LOCAL_CXXFLAGS si on veut les packages de Local CXXFLAGS = $(CGAL_CXXFLAGS) \ + $(LONG_NAME_PROBLEM_CXXFLAGS) # -DDEBUG for display additionnal info -# -O2 supported +# -O2 supported iff long names are not a problem (on Linux, or with +# the gnu "binutils") #---------------------------------------------------------------------# # linker flags #---------------------------------------------------------------------# -LDFLAGS = $(CGAL_WINDOW_LIBPATH) \ - $(CGAL_WINDOW_LDFLAGS) +LIBPATH = $(CGAL_LIBPATH) + +LDFLAGS = $(CGAL_WINDOW_LDFLAGS) \ + $(LONG_NAME_PROBLEM_LDFLAGS) #---------------------------------------------------------------------# # target entries #---------------------------------------------------------------------# -all: demo_alpha demo_weight +all: demo_alpha$(EXE_EXT) demo_weight$(EXE_EXT) -demo_alpha: demo_alpha$(OBJ_EXT) - $(CGAL_CXX) $(LIBPATH) $(EXE_OPT) -o demo_alpha demo_alpha$(OBJ_EXT) $(CGAL_WINDOW_LDFLAGS) +demo_alpha$(EXE_EXT): demo_alpha$(OBJ_EXT) + $(CGAL_CXX) $(LIBPATH) $(EXE_OPT)demo_alpha demo_alpha$(OBJ_EXT) $(LDFLAGS) -demo_weight: demo_weight$(OBJ_EXT) - $(CGAL_CXX) $(LIBPATH) $(EXE_OPT) -o demo_weight demo_weight$(OBJ_EXT) $(CGAL_WINDOW_LDFLAGS) +demo_weight$(EXE_EXT): demo_weight$(OBJ_EXT) + $(CGAL_CXX) $(LIBPATH) $(EXE_OPT)demo_weight demo_weight$(OBJ_EXT) $(LDFLAGS) clean: \rm -f *.o *.obj *.exe \ - demo_alpha demo_weight \ + demo_alpha$(EXE_EXT) demo_weight$(EXE_EXT) \ core @@ -48,7 +52,7 @@ clean: #---------------------------------------------------------------------# .C$(OBJ_EXT): - $(CGAL_CXX) $(CXXFLAGS) -c $< + $(CGAL_CXX) $(CXXFLAGS) $(OBJ_OPT) $< diff --git a/Packages/Alpha_shapes_2/examples/Alpha_shapes_2/Makefile b/Packages/Alpha_shapes_2/examples/Alpha_shapes_2/Makefile index e736b55e80e..23a3bd7cd2c 100644 --- a/Packages/Alpha_shapes_2/examples/Alpha_shapes_2/Makefile +++ b/Packages/Alpha_shapes_2/examples/Alpha_shapes_2/Makefile @@ -41,32 +41,34 @@ CXXFLAGS = -I$(HOME)/Cgal-2.0/To_submit/Alpha_shapes_2/include \ #---------------------------------------------------------------------# # linker flags #---------------------------------------------------------------------# -LDFLAGS = $(CGAL_WINDOW_LIBPATH) \ - $(CGAL_WINDOW_LDFLAGS) + +LIBPATH = $(CGAL_LIBPATH) + +LDFLAGS = $(CGAL_WINDOW_LDFLAGS) #---------------------------------------------------------------------# # target entries #---------------------------------------------------------------------# -all: example_alpha example_weight +all: example_alpha$(EXE_EXT) example_weight$(EXE_EXT) -example_alpha: example_alpha.o - $(CGAL_CXX) -o example_alpha example_alpha.o $(LDFLAGS) +example_alpha$(EXE_EXT): example_alpha$(OBJ_EXT) + $(CGAL_CXX) $(LIBPATH) $(EXE_OPT)example_alpha example_alpha$(OBJ_EXT) $(LDFLAGS) -example_weight: example_weight.o - $(CGAL_CXX) -o example_weight example_weight.o $(LDFLAGS) +example_weight$(EXE_EXT): example_weight$(OBJ_EXT) + $(CGAL_CXX) $(LIBPATH) $(EXE_OPT)example_weight example_weight$(OBJ_EXT) $(LDFLAGS) clean: \rm -f *.o *.obj *.exe \ - example_alpha example_weight \ + example_alpha$(EXE_EXT) example_weight$(EXE_EXT) \ core #---------------------------------------------------------------------# # suffix rules #---------------------------------------------------------------------# -.C.o: - $(CGAL_CXX) $(CXXFLAGS) -c $< +.C$(OBJ_EXT): + $(CGAL_CXX) $(CXXFLAGS) $(OBJ_OPT) $< diff --git a/Packages/Alpha_shapes_2/examples/Alpha_shapes_2/example_alpha.C b/Packages/Alpha_shapes_2/examples/Alpha_shapes_2/example_alpha.C index 8e30ab9d650..df3c5281b09 100644 --- a/Packages/Alpha_shapes_2/examples/Alpha_shapes_2/example_alpha.C +++ b/Packages/Alpha_shapes_2/examples/Alpha_shapes_2/example_alpha.C @@ -28,9 +28,19 @@ correspondant a l'Alpha Shape. #include #include - - +//Choose the better number type as possible +#ifdef CGAL_USE_LEDA +#include +typedef leda_integer coord_type; +#else//CGAL_USE_LEDA +#ifdef CGAL_USE_GMP +#include +typedef CGAL::Gmpz coord_type; +#else//CGAL_USE_GMP +#include typedef double coord_type; +#endif//CGAL_USE_GMP +#endif//CGAL_USE_LEDA typedef CGAL::Cartesian CRep; diff --git a/Packages/Alpha_shapes_2/examples/Alpha_shapes_2/example_weight.C b/Packages/Alpha_shapes_2/examples/Alpha_shapes_2/example_weight.C index 153bba1f32c..e0febc9cfe8 100644 --- a/Packages/Alpha_shapes_2/examples/Alpha_shapes_2/example_weight.C +++ b/Packages/Alpha_shapes_2/examples/Alpha_shapes_2/example_weight.C @@ -31,7 +31,19 @@ correspondant a l'Alpha Shape ponderee. #include #include -typedef int coord_type; +//Choose the better number type as possible +#ifdef CGAL_USE_LEDA +#include +typedef leda_integer coord_type; +#else//CGAL_USE_LEDA +#ifdef CGAL_USE_GMP +#include +typedef CGAL::Gmpz coord_type; +#else//CGAL_USE_GMP +#include +typedef double coord_type; +#endif//CGAL_USE_GMP +#endif//CGAL_USE_LEDA typedef CGAL::Cartesian CRep; typedef CGAL::Point_2 Point_base; diff --git a/Packages/Alpha_shapes_2/include/CGAL/predicates/in_smallest_orthogonalcircle_ftC2.h b/Packages/Alpha_shapes_2/include/CGAL/predicates/in_smallest_orthogonalcircle_ftC2.h index 64a790957bb..9d9db9f49f4 100644 --- a/Packages/Alpha_shapes_2/include/CGAL/predicates/in_smallest_orthogonalcircle_ftC2.h +++ b/Packages/Alpha_shapes_2/include/CGAL/predicates/in_smallest_orthogonalcircle_ftC2.h @@ -45,8 +45,8 @@ in_smallest_orthogonalcircleC2(const FT &px, const FT &py, const FT &pw, FT dty = ty-qy; FT dpz = square(dpx)+square(dpy); - return Bounded_side (sign(-(square(dtx)+square(dty)-tw+qw)*dpz - +(dpz-pw+qw)*(dpx*dtx+dpy*dty))); + return Bounded_side (sign(-(square(dtx)+square(dty)-tw+qw)*dpz + +(dpz-pw+qw)*(dpx*dtx+dpy*dty))); } //------------------------------------------------------------------- diff --git a/Packages/Alpha_shapes_2/test/Alpha_shapes_2/Makefile b/Packages/Alpha_shapes_2/test/Alpha_shapes_2/Makefile index a005b6d881e..342504b2658 100644 --- a/Packages/Alpha_shapes_2/test/Alpha_shapes_2/Makefile +++ b/Packages/Alpha_shapes_2/test/Alpha_shapes_2/Makefile @@ -41,32 +41,34 @@ CXXFLAGS = -I$(HOME)/Cgal-2.0/To_submit/Alpha_shapes_2/include \ #---------------------------------------------------------------------# # linker flags #---------------------------------------------------------------------# -LDFLAGS = $(CGAL_WINDOW_LIBPATH) \ - $(CGAL_WINDOW_LDFLAGS) + +LIBPATH = $(CGAL_LIBPATH) + +LDFLAGS = $(CGAL_WINDOW_LDFLAGS) #---------------------------------------------------------------------# # target entries #---------------------------------------------------------------------# -all: test_alpha test_weight +all: test_alpha$(EXE_EXT) test_weight$(EXE_EXT) -test_alpha: test_alpha.o - $(CGAL_CXX) -o test_alpha test_alpha.o $(LDFLAGS) +test_alpha$(EXE_EXT): test_alpha$(OBJ_EXT) + $(CGAL_CXX) $(LIBPATH) $(EXE_OPT)test_alpha test_alpha$(OBJ_EXT) $(LDFLAGS) -test_weight: test_weight.o - $(CGAL_CXX) -o test_weight test_weight.o $(LDFLAGS) +test_weight$(EXE_EXT): test_weight$(OBJ_EXT) + $(CGAL_CXX) $(LIBPATH) $(EXE_OPT)test_weight test_weight$(OBJ_EXT) $(LDFLAGS) clean: \rm -f *.o *.obj *.exe \ - test_alpha test_weight \ + test_alpha$(EXE_EXT) test_weight$(EXE_EXT) \ core #---------------------------------------------------------------------# # suffix rules #---------------------------------------------------------------------# -.C.o: - $(CGAL_CXX) $(CXXFLAGS) -c $< +.C$(OBJ_EXT): + $(CGAL_CXX) $(CXXFLAGS) $(OBJ_OPT) $< diff --git a/Packages/Alpha_shapes_2/test/Alpha_shapes_2/test_alpha.C b/Packages/Alpha_shapes_2/test/Alpha_shapes_2/test_alpha.C index 8e30ab9d650..df3c5281b09 100644 --- a/Packages/Alpha_shapes_2/test/Alpha_shapes_2/test_alpha.C +++ b/Packages/Alpha_shapes_2/test/Alpha_shapes_2/test_alpha.C @@ -28,9 +28,19 @@ correspondant a l'Alpha Shape. #include #include - - +//Choose the better number type as possible +#ifdef CGAL_USE_LEDA +#include +typedef leda_integer coord_type; +#else//CGAL_USE_LEDA +#ifdef CGAL_USE_GMP +#include +typedef CGAL::Gmpz coord_type; +#else//CGAL_USE_GMP +#include typedef double coord_type; +#endif//CGAL_USE_GMP +#endif//CGAL_USE_LEDA typedef CGAL::Cartesian CRep; diff --git a/Packages/Alpha_shapes_2/test/Alpha_shapes_2/test_weight.C b/Packages/Alpha_shapes_2/test/Alpha_shapes_2/test_weight.C index 153bba1f32c..e0febc9cfe8 100644 --- a/Packages/Alpha_shapes_2/test/Alpha_shapes_2/test_weight.C +++ b/Packages/Alpha_shapes_2/test/Alpha_shapes_2/test_weight.C @@ -31,7 +31,19 @@ correspondant a l'Alpha Shape ponderee. #include #include -typedef int coord_type; +//Choose the better number type as possible +#ifdef CGAL_USE_LEDA +#include +typedef leda_integer coord_type; +#else//CGAL_USE_LEDA +#ifdef CGAL_USE_GMP +#include +typedef CGAL::Gmpz coord_type; +#else//CGAL_USE_GMP +#include +typedef double coord_type; +#endif//CGAL_USE_GMP +#endif//CGAL_USE_LEDA typedef CGAL::Cartesian CRep; typedef CGAL::Point_2 Point_base; diff --git a/Packages/Alpha_shapes_2/version b/Packages/Alpha_shapes_2/version index 5fccccef5dd..3527a09c678 100644 --- a/Packages/Alpha_shapes_2/version +++ b/Packages/Alpha_shapes_2/version @@ -1 +1 @@ -4.2 ( 8 Dec 1999) +4.5 (14 Dec 1999)