diff options
author | Martin Wilke <miwi@FreeBSD.org> | 2014-05-17 08:42:00 +0000 |
---|---|---|
committer | Martin Wilke <miwi@FreeBSD.org> | 2014-05-17 08:42:00 +0000 |
commit | 8721a01043f89cf33522b8c9479a0e497cb95cb1 (patch) | |
tree | e420c140198051fd5fcd6f34341ca377ac2de33c | |
parent | 8f96df49daf2293a806533d82d5180b3b4518338 (diff) | |
download | ports-8721a01043f89cf33522b8c9479a0e497cb95cb1.tar.gz ports-8721a01043f89cf33522b8c9479a0e497cb95cb1.zip |
Notes
-rw-r--r-- | x11-clocks/glclock/Makefile | 47 | ||||
-rw-r--r-- | x11-clocks/glclock/files/patch-MString.H | 34 | ||||
-rw-r--r-- | x11-clocks/glclock/files/patch-MString.cpp | 12 | ||||
-rw-r--r-- | x11-clocks/glclock/files/patch-makefile | 15 |
4 files changed, 61 insertions, 47 deletions
diff --git a/x11-clocks/glclock/Makefile b/x11-clocks/glclock/Makefile index c53a60d66885..2042b3b19faf 100644 --- a/x11-clocks/glclock/Makefile +++ b/x11-clocks/glclock/Makefile @@ -13,37 +13,46 @@ COMMENT= OpenGL spinning pocket watch demo and benchmark utility USE_XORG= xi xmu xext x11 USE_GL= gl glu glut MAKEFILE= makefile -MAKE_ARGS= CC="${CXX}" LN="${CXX}" OPT="${OPT}" \ - INCLUDE_PATH="-I${LOCALBASE}/include" \ - LIB_PATH="-L${LOCALBASE}/lib" -OPT= -DIMAGE_PATH="\\\"${PREFIX}/lib/X11/glclock/\\\"" \ - ${CFLAGS} +CFLAGS+= -DIMAGE_PATH="\\\"${PREFIX}/lib/X11/glclock/\\\"" -PROGRAMS= glclock glclockmark +PLIST_FILES= ${PROGRAMS:S,^,bin/,} ${SCRIPTS:S,^,bin/,} \ + ${TEXTURES:S,^,lib/X11/glclock/,} +PLIST_DIRS= lib/X11/glclock +OPTIONS_DEFINE= OPTIMIZED_CFLAGS + +OPTIMIZED_CFLAGS_CFLAGS=\ + -O3 -fexpensive-optimizations -ffast-math \ + -fomit-frame-pointer -fforce-mem -fforce-addr + +PROGRAMS= glclock glclockmark SCRIPTS= chromeclock chromeclock_L crystalclock crystalclock_L \ glclock_L glclockmark_ALL marbleclock marbleclock_L \ metalclock metalclock_L mwclock mwclock_L woodclock \ woodclock_L - TEXTURES= light.ppm marble.ppm sky.ppm wood.ppm detail.pgm \ detail2.pgm detail_b.pgm filter.pgm -PLIST_FILES= ${PROGRAMS:S,^,bin/,} ${SCRIPTS:S,^,bin/,} \ - ${TEXTURES:S,^,lib/X11/glclock/,} -PLIST_DIRS= lib/X11/glclock - -OPTIONS_DEFINE= OPTIMIZED_CFLAGS - -OPTIMIZED_CFLAGS_CFLAGS= -O3 -fexpensive-optimizations \ - -ffast-math -fomit-frame-pointer -fforce-mem -fforce-addr +post-patch: + @${REINPLACE_CMD} -e \ + 's|g\+\+|$${CXX}| ; \ + s|-O2|$${CXXFLAGS}| ; \ + s|/usr/X11R6|$${LOCALBASE}|' ${WRKSRC}/${MAKEFILE} do-install: - ${INSTALL_PROGRAM} ${PROGRAMS:S,^,${WRKSRC}/,} ${STAGEDIR}${PREFIX}/bin - ${INSTALL_SCRIPT} ${SCRIPTS:S,^,${WRKSRC}/,} ${STAGEDIR}${PREFIX}/bin +.for i in ${PROGRAMS} + (cd ${WRKSRC} && ${INSTALL_PROGRAM} ${i} \ + ${STAGEDIR}${PREFIX}/bin) +.endfor +.for i in ${SCRIPTS} + (cd ${WRKSRC} && ${INSTALL_SCRIPT} ${i} \ + ${STAGEDIR}${PREFIX}/bin) +.endfor @${MKDIR} ${STAGEDIR}${PREFIX}/lib/X11/glclock - ${INSTALL_DATA} ${TEXTURES:S,^,${WRKSRC}/,} \ - ${STAGEDIR}${PREFIX}/lib/X11/glclock +.for i in ${TEXTURES} + (cd ${WRKSRC} && ${INSTALL_DATA} ${i} \ + ${STAGEDIR}${PREFIX}/lib/X11/glclock) +.endfor .include <bsd.port.mk> diff --git a/x11-clocks/glclock/files/patch-MString.H b/x11-clocks/glclock/files/patch-MString.H index dc45ba8df70c..a64f02735c5d 100644 --- a/x11-clocks/glclock/files/patch-MString.H +++ b/x11-clocks/glclock/files/patch-MString.H @@ -1,5 +1,5 @@ ---- MString.H.orig Thu Jun 22 16:58:26 2000 -+++ MString.H Sun Oct 1 22:32:31 2006 +--- MString.H.orig 2000-06-22 23:58:26.000000000 +0900 ++++ MString.H 2014-04-01 01:01:42.000000000 +0900 @@ -66,7 +66,7 @@ #ifndef ___STRING_H___ #define ___STRING_H___ @@ -17,14 +17,22 @@ //#define STRING_DEBUG -@@ -407,6 +408,10 @@ - friend String& Cut(String s) ; - friend String& Cut(const char *s) ; - } ; -+ -+String Mid(String, int, int) ; -+String Left(const String&, int) ; -+String Right(const String&, int) ; - - // 整数から String へ - String IntToString(int i) ; +@@ -307,15 +308,15 @@ + + // m 文字目から n 文字 + String& Mid(int m, int n = 1) ; +- friend String Mid(String s, int m, int n = 1) ; ++ friend String Mid(String s, int m, int n) ; + + // 左から n 文字 + String& Left(int n = 1) ; +- friend String Left(const String& s, int n = 1) ; ++ friend String Left(const String& s, int n) ; + + // 右から n 文字 + String& Right(int n = 1) ; +- friend String Right(const String& s, int n = 1) ; ++ friend String Right(const String& s, int n) ; + + String FileDirectory() const ; + String FileNamePart() const ; diff --git a/x11-clocks/glclock/files/patch-MString.cpp b/x11-clocks/glclock/files/patch-MString.cpp new file mode 100644 index 000000000000..f43b3a283105 --- /dev/null +++ b/x11-clocks/glclock/files/patch-MString.cpp @@ -0,0 +1,12 @@ +--- MString.cpp.orig ++++ MString.cpp +@@ -1,6 +1,9 @@ + + #include "MString.H" + ++String Left(const String &, int); ++String Mid(String, int, int); ++String Right(const String &, int); + + // コンストラクタ + String::String(int n) diff --git a/x11-clocks/glclock/files/patch-makefile b/x11-clocks/glclock/files/patch-makefile deleted file mode 100644 index 82ce366bb6a1..000000000000 --- a/x11-clocks/glclock/files/patch-makefile +++ /dev/null @@ -1,15 +0,0 @@ ---- makefile.orig Sun Jun 18 16:37:40 2000 -+++ makefile Sun Oct 1 20:39:39 2006 -@@ -11,9 +11,9 @@ - TARGET_MARK = glclockmark - - -- COMPILER = g++ -c -- LINKER = g++ -- OPT = -O2 -+ COMPILER = $(CXX) -c -+ LINKER = $(CXX) -+ OPT = $(CFLAGS) - - INCLUDE_PATH = -I/usr/X11R6/include - LIB_PATH = -L/usr/X11R6/lib |