1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-11-05 22:43:24 +00:00
freebsd-ports/math/plplot/files/patch-aa
R. Imura 5f76ca8d6b - Support CC/CFLAGS/CXXFLAGS properly
- Support install macros
- perl -> ${PERL}
- Move install path of data files from lib/ to libdata/
- Add WWW: line into pkg/DESCR
- Fix pkg/PLIST

PR:		15918
Submitted by:	KATO Tsuguru <tkato@prontomail.ne.jp>
2000-01-14 17:35:24 +00:00

97 lines
2.4 KiB
Plaintext

--- configure.orig Wed Jun 7 04:58:50 1995
+++ configure Wed Jan 5 00:15:16 2000
@@ -1175,10 +1175,10 @@
# ----------------------------------------------------------------------------
if test "$with_gcc" = "yes"; then
- CC=gcc
- CXX=gcc
- OCC="gcc -traditional"
- CPP="gcc -E"
+ CC=$CC
+ CXX=$CXX
+ OCC="$CC -traditional"
+ CPP="$CC -E"
if test "$with_warn" = "yes"; then
SYS_FLAGS_C=-Wall
@@ -1472,13 +1472,13 @@
# ----------------------------------------------------------------------------
CC_FLAGS=\
-"-c $DBL_FLAG_C $DEBUG_FLAG_C $SYS_FLAGS_C $PROF_FLAG_C $OPT_FLAG_C"
+"-c $DBL_FLAG_C $DEBUG_FLAG_C $SYS_FLAGS_C $PROF_FLAG_C $CFLAGS"
CXX_FLAGS=\
-"-c $DBL_FLAG_CXX $DEBUG_FLAG_CXX $SYS_FLAGS_CXX $PROF_FLAG_CXX $OPT_FLAG_CXX"
+"-c $DBL_FLAG_CXX $DEBUG_FLAG_CXX $SYS_FLAGS_CXX $PROF_FLAG_CXX $CXXFLAGS"
F77_FLAGS=\
-"-c $DBL_FLAG_F $DEBUG_FLAG_F $SYS_FLAGS_F $PROF_FLAG_F $OPT_FLAG_F"
+"-c $DBL_FLAG_F $DEBUG_FLAG_F $SYS_FLAGS_F $PROF_FLAG_F $FFLAGS"
LDC_FLAGS=\
"$PROF_FLAG_LC $SYS_FLAGS_LC $DEBUG_FLAG_LC"
@@ -3062,6 +3062,20 @@
# Hmm, would be good to replace that trailing .0 with the
# compilation number or some such. Have to think about that.
;;
+ FreeBSD*|NetBSD*|OpenBSD* )
+ SHLIB_CCFLAGS="-fpic -DPIC"
+ SHLIB_CXXFLAGS="-fpic -DPIC"
+ if [ "${PORTOBJFORMAT}" = "elf" ]; then
+ SO='.so.$(MAJOR_VERSION)'
+ SHLIB_BUILD="ld -shared -soname \$@ -o"
+ SOVERSION='$(MAJOR_VERSION)'
+ else
+ SO='.so.$(MAJOR_VERSION).$(MINOR_VERSION)'
+ SHLIB_BUILD="ld -Bshareable -o"
+ SOVERSION='$(MAJOR_VERSION).$(MINOR_VERSION)'
+ fi
+ echo "$ac_t""okay" 1>&6
+ ;;
HP-UX-* )
SO=".sl"
SHLIB_F77FLAGS="+z"
@@ -4192,16 +4206,19 @@
fi
fi
if test -z "$DOC_DIR"; then
- DOC_DIR=$prefix/doc
+ DOC_DIR=$prefix/share/doc/plplot
fi
if test -z "$INFO_DIR"; then
INFO_DIR=$prefix/info
fi
if test -z "$INCLUDE_DIR"; then
- INCLUDE_DIR=$prefix/include
+ INCLUDE_DIR=$prefix/include/plplot
fi
if test -z "$DEMOS_DIR"; then
- DEMOS_DIR=$prefix/examples
+ DEMOS_DIR=$prefix/share/examples/plplot
+fi
+if test -z "$DATA_DIR"; then
+ DATA_DIR=$prefix/libdata/plplot
fi
cat >> confdefs.h <<EOF
@@ -4216,6 +4233,9 @@
#define TCL_DIR "$TCL_DIR"
EOF
+cat >> confdefs.h <<EOF
+#define DATA_DIR "$DATA_DIR"
+EOF
@@ -4449,6 +4469,7 @@
s%@INFO_DIR@%$INFO_DIR%g
s%@INCLUDE_DIR@%$INCLUDE_DIR%g
s%@DEMOS_DIR@%$DEMOS_DIR%g
+s%@DATA_DIR@%$DATA_DIR%g
s%@SHARED@%$SHARED%g
CEOF