summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobin H. Johnson <robbat2@gentoo.org>2015-08-08 13:49:04 -0700
committerRobin H. Johnson <robbat2@gentoo.org>2015-08-08 17:38:18 -0700
commit56bd759df1d0c750a065b8c845e93d5dfa6b549d (patch)
tree3f91093cdb475e565ae857f1c5a7fd339e2d781e /sci-astronomy/sofa_c/files
downloadgentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.gz
gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.bz2
gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.zip
proj/gentoo: Initial commit
This commit represents a new era for Gentoo: Storing the gentoo-x86 tree in Git, as converted from CVS. This commit is the start of the NEW history. Any historical data is intended to be grafted onto this point. Creation process: 1. Take final CVS checkout snapshot 2. Remove ALL ChangeLog* files 3. Transform all Manifests to thin 4. Remove empty Manifests 5. Convert all stale $Header$/$Id$ CVS keywords to non-expanded Git $Id$ 5.1. Do not touch files with -kb/-ko keyword flags. Signed-off-by: Robin H. Johnson <robbat2@gentoo.org> X-Thanks: Alec Warner <antarus@gentoo.org> - did the GSoC 2006 migration tests X-Thanks: Robin H. Johnson <robbat2@gentoo.org> - infra guy, herding this project X-Thanks: Nguyen Thai Ngoc Duy <pclouds@gentoo.org> - Former Gentoo developer, wrote Git features for the migration X-Thanks: Brian Harring <ferringb@gentoo.org> - wrote much python to improve cvs2svn X-Thanks: Rich Freeman <rich0@gentoo.org> - validation scripts X-Thanks: Patrick Lauer <patrick@gentoo.org> - Gentoo dev, running new 2014 work in migration X-Thanks: Michał Górny <mgorny@gentoo.org> - scripts, QA, nagging X-Thanks: All of other Gentoo developers - many ideas and lots of paint on the bikeshed
Diffstat (limited to 'sci-astronomy/sofa_c/files')
-rw-r--r--sci-astronomy/sofa_c/files/sofa_c-makefile.patch113
1 files changed, 113 insertions, 0 deletions
diff --git a/sci-astronomy/sofa_c/files/sofa_c-makefile.patch b/sci-astronomy/sofa_c/files/sofa_c-makefile.patch
new file mode 100644
index 000000000000..b992d401d3fa
--- /dev/null
+++ b/sci-astronomy/sofa_c/files/sofa_c-makefile.patch
@@ -0,0 +1,113 @@
+--- makefile.orig 2013-05-22 20:51:58.398491342 +0000
++++ makefile 2013-05-22 21:05:52.055466710 +0000
+@@ -49,7 +49,7 @@
+
+ # Specify the installation home directory.
+
+-INSTALL_DIR = $(HOME)
++INSTALL_DIR = $(DESTDIR)/usr
+
+ # Specify the installation directory for the library.
+
+@@ -63,9 +63,10 @@
+ # of your preferred C compiler (CCOMPC) and compilation flags (CFLAGF
+ # for functions, CFLAGX for executables) here.
+
+-CCOMPC = gcc
+-CFLAGF = -c -pedantic -Wall -W -O
+-CFLAGX = -pedantic -Wall -W -O
++CCOMPC = $(CC)
++CFLAGF = -c -pedantic -Wall -W -fPIC $(CFLAGS)
++CFLAGX = -pedantic -Wall -W $(CFLAGS)
++
+
+ #----YOU SHOULDN'T HAVE TO MODIFY ANYTHING BELOW THIS LINE---------
+
+@@ -80,6 +81,12 @@
+ SOFA_LIB_NAME = libsofa_c.a
+ SOFA_LIB = $(SOFA_LIB_DIR)$(SOFA_LIB_NAME)
+
++
++# Name the SOFA/C library in its source and target locations.
++
++SOFA_SHLIB_NAME = libsofa_c.so
++SOFA_SHLIB = $(SOFA_LIB_DIR)$(SOFA_SHLIB_NAME)
++
+ # Name the SOFA/C testbed in its source and target locations.
+
+ SOFA_TEST_NAME = t_sofa_c.c
+@@ -88,7 +95,7 @@
+ # Name the SOFA/C includes in their source and target locations.
+
+ SOFA_INC_NAMES = sofa.h sofam.h
+-SOFA_INC = $(SOFA_INC_DIR)sofa.h $(SOFA_INC_DIR)sofam.h
++SOFA_INC = $(SOFA_INC_NAMES:%=$(SOFA_INC_DIR)%)
+
+ # The list of SOFA/C library object files.
+ SOFA_OBS = iauA2af.o \
+@@ -285,29 +292,32 @@
+ #-----------------------------------------------------------------------
+
+ # Build (but do not install) the library.
+-all : $(SOFA_LIB_NAME)
++all : $(SOFA_SHLIB_NAME)
+ -@ echo ""
+ -@ echo "*** Now type 'make test'" \
+ " to install the library and run tests ***"
+ -@ echo ""
+
+ # Install the library and header files.
+-install $(SOFA_LIB) : $(INSTALL_DIRS) $(SOFA_LIB_NAME) $(SOFA_INC)
+- cp $(SOFA_LIB_NAME) $(SOFA_LIB_DIR)
++install: $(INSTALL_DIRS) $(SOFA_SHLIB_NAME) $(SOFA_INC)
++ cp $(SOFA_SHLIB_NAME).0.0 $(SOFA_LIB_DIR)
++ ln -s $(SOFA_SHLIB_NAME).0.0 $(SOFA_SHLIB).0
++ ln -s $(SOFA_SHLIB_NAME).0 $(SOFA_SHLIB)
+
+ # Deinstall the library and header files.
+ deinstall:
+- rm -f $(SOFA_LIB) $(SOFA_INC)
++ rm -f $(SOFA_LIB) $(SOFA_SHLIB)* $(SOFA_INC)
+
+ # Test the build.
+ check: $(SOFA_TEST_NAME) $(SOFA_INC_NAMES) $(SOFA_LIB_NAME)
+- $(CCOMPC) $(CFLAGX) $(SOFA_TEST_NAME) $(SOFA_LIB_NAME) \
++ $(CCOMPC) $(CFLAGX) $(SOFA_TEST_NAME) $(SOFA_SHLIB_NAME).0.0 \
+ -lm -o $(SOFA_TEST)
+- ./$(SOFA_TEST)
+- rm -f $(SOFA_TEST)
++ ln -s $(SOFA_SHLIB_NAME).0.0 $(SOFA_SHLIB_NAME).0
++ LD_LIBRARY_PATH="$(LD_LIBRARY_PATH):." ./$(SOFA_TEST)
++ rm -f $(SOFA_TEST) $(SOFA_SHLIB_NAME).0
+
+ # Test the installed library.
+-installcheck test: $(SOFA_TEST_NAME) $(SOFA_INC) $(SOFA_LIB)
++installcheck: $(SOFA_TEST_NAME) $(SOFA_INC) $(SOFA_LIB)
+ $(CCOMPC) $(CFLAGX) $(SOFA_TEST_NAME) -I$(SOFA_INC_DIR) \
+ -L$(SOFA_LIB_DIR) -lsofa_c -lm -o $(SOFA_TEST)
+ ./$(SOFA_TEST)
+@@ -315,11 +325,11 @@
+
+ # Local clean up.
+ clean realclean:
+- rm -f $(SOFA_OBS) $(SOFA_LIB_NAME)
++ rm -f $(SOFA_OBS) $(SOFA_LIB_NAME) $(SOFA_SHLIB_NAME)
+
+ # Clean up and deinstall.
+ distclean:
+- rm -f $(SOFA_OBS) $(SOFA_LIB_NAME) $(SOFA_INC) $(SOFA_LIB)
++ rm -f $(SOFA_OBS) $(SOFA_LIB_NAME) $(SOFA_INC) $(SOFA_LIB) $(SOFA_SHLIB_NAME)
+
+ # Create the installation directories if not already present.
+ $(INSTALL_DIRS):
+@@ -329,6 +339,10 @@
+ $(SOFA_LIB_NAME): $(SOFA_OBS)
+ ar ru $(SOFA_LIB_NAME) $?
+
++$(SOFA_SHLIB_NAME): $(SOFA_OBS)
++ $(CC) $(LDFLAGS) -shared -Wl,-soname,$(SOFA_SHLIB_NAME).0 -lm -o $(SOFA_SHLIB_NAME).0.0 $?
++
++
+ # Install the header files.
+ $(SOFA_INC) : $(INSTALL_DIRS) $(SOFA_INC_NAMES)
+ cp $(SOFA_INC_NAMES) $(SOFA_INC_DIR)