From 2a94aac83ab7c9e216650a2e7f19467a804ba8ec Mon Sep 17 00:00:00 2001
From: Paul Elliott <pelliott@blackpatchpanel.com>
Date: Sat, 18 Feb 2012 12:00:03 -0600
Subject: replace builtin static swe with external shared swe

 Replace maitreya's builtin static swe with external shared
 library swe provided by an external package.
  "4.13 Convenience copies of code" from Debian Policy Manual
 clearly states:
 "Some software packages include in their distribution convenience
 copies of code from other software packages, generally so that users
 compiling from source don't have to download multiple
 packages. Debian packages should not make use of these convenience
 copies unless the included package is explicitly intended to be used
 in this way.[29] If the included code is already in the Debian
 archive in the form of a library, the Debian packaging should ensure
 that binary packages reference the libraries already in Debian and
 the convenience copy is not used. If the included code is not already
 in Debian, it should be packaged separately as a prerequisite if
 possible."
Forwarded: https://sourceforge.net/tracker/?func=detail&aid=3483971&group_id=96371&atid=614571
---
 configure.in            |    1 -
 src/Makefile.am         |    2 +-
 src/base/Makefile.am    |    2 +-
 src/base/Makefile.in    |    2 +-
 src/gui/Makefile.am     |    4 ++--
 src/jyotish/Makefile.am |    4 ++--
 6 files changed, 7 insertions(+), 8 deletions(-)

diff --git a/configure.in b/configure.in
index 796bb8d..ee592cf 100644
--- a/configure.in
+++ b/configure.in
@@ -81,7 +81,6 @@ AC_OUTPUT( Makefile po/Makefile.in
 	debian/Makefile
 	src/Makefile
 	src/base/Makefile
-	src/swe/Makefile
 	src/jyotish/Makefile
 	src/gui/Makefile
 	src/pics/Makefile
diff --git a/src/Makefile.am b/src/Makefile.am
index 89b490c..b2a2848 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -1,5 +1,5 @@
 
-SUBDIRS = swe base jyotish dialogs pdf gui locations pics icons fonts xml 
+SUBDIRS = base jyotish dialogs pdf gui locations pics icons fonts xml 
 
 EXTRA_DIST = Makefile.win 
 
diff --git a/src/base/Makefile.am b/src/base/Makefile.am
index 823f2a9..00c6749 100644
--- a/src/base/Makefile.am
+++ b/src/base/Makefile.am
@@ -1,4 +1,4 @@
-INCLUDES = -I. -I../swe -I../pics
+INCLUDES = -I. -I../pics
 
 AM_CPPFLAGS = $(WX_CPPFLAGS) -Wall -DSTRICT 
 
diff --git a/src/base/Makefile.in b/src/base/Makefile.in
index 519871c..704677d 100644
--- a/src/base/Makefile.in
+++ b/src/base/Makefile.in
@@ -215,7 +215,7 @@ target_alias = @target_alias@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
-INCLUDES = -I. -I../swe -I../pics
+INCLUDES = -I. -I../pics
 
 # Remove this when gimp writes xpm like const *char
 AM_CPPFLAGS = $(WX_CPPFLAGS) -Wall -DSTRICT -Wno-write-strings
diff --git a/src/gui/Makefile.am b/src/gui/Makefile.am
index 88efe54..7f5cdfd 100644
--- a/src/gui/Makefile.am
+++ b/src/gui/Makefile.am
@@ -21,8 +21,8 @@ maitreya6_bin_SOURCES = ApplicationWindow.cpp ApplicationWindow.h AshtakaVargaVi
 	YogaEditor.cpp YogaEditor.h YogaView.cpp YogaView.h 
 
 
-maitreya6_bin_LDADD = ../jyotish/libjyotish.a ../base/libmaitreya_base.a ../swe/libswe.a \
-	../dialogs/libmaitreya_dialogs.a ../pdf/libmaitreya_pdf.a $(WX_LIBS) -lm 
+maitreya6_bin_LDADD = ../jyotish/libjyotish.a ../base/libmaitreya_base.a  \
+	../dialogs/libmaitreya_dialogs.a ../pdf/libmaitreya_pdf.a $(WX_LIBS) -lswe -lm 
 
 all-am: maitreya6
 
diff --git a/src/jyotish/Makefile.am b/src/jyotish/Makefile.am
index 816ecab..8f37729 100644
--- a/src/jyotish/Makefile.am
+++ b/src/jyotish/Makefile.am
@@ -4,7 +4,7 @@ AM_CPPFLAGS = $(WX_CPPFLAGS) -Wall -DSTRICT
 
 bin_PROGRAMS = maitreya_textclient
 maitreya_textclient_SOURCES = textclient.cpp
-maitreya_textclient_LDADD = libjyotish.a ../base/libmaitreya_base.a ../swe/libswe.a  $(WX_LIBS)
+maitreya_textclient_LDADD = libjyotish.a ../base/libmaitreya_base.a   $(WX_LIBS) -lswe -lm
 
 all-am:
 	test -L locations.dat || ln -s ../locations/locations.dat
@@ -45,7 +45,7 @@ clean:
 	rm -f maitreya_textclient
 	rm -f locations.dat
 
-	
+
 EXTRA_DIST = Makefile.win jyotish.vcproj textclient.vcproj MdlParser.h*
 
 
