summaryrefslogtreecommitdiff
path: root/databases/grass6/files
diff options
context:
space:
mode:
Diffstat (limited to 'databases/grass6/files')
-rw-r--r--databases/grass6/files/patch-Makefile35
-rw-r--r--databases/grass6/files/patch-configure15
-rw-r--r--databases/grass6/files/patch-gui__wxpython__Makefile12
-rw-r--r--databases/grass6/files/patch-lib__python__ctypes__ctypesgencore__parser__preprocessor.py10
-rw-r--r--databases/grass6/files/patch-lib_ogsf_gsd__img__mpeg.c102
5 files changed, 174 insertions, 0 deletions
diff --git a/databases/grass6/files/patch-Makefile b/databases/grass6/files/patch-Makefile
new file mode 100644
index 000000000000..4e565a3ca78a
--- /dev/null
+++ b/databases/grass6/files/patch-Makefile
@@ -0,0 +1,35 @@
+--- Makefile.orig 2014-12-16 22:11:04 UTC
++++ Makefile
+@@ -240,32 +240,12 @@ install: FORCE
+ while [ ! -d $$INST_PATH ]; do \
+ INST_PATH=`dirname $$INST_PATH`; \
+ done; \
+- if [ ! -d "${INST_DIR}" -a ! -w "$$INST_PATH" ] ; then \
+- echo "ERROR: Directory $$INST_PATH is a parent directory of your"; \
+- echo " install directory ${INST_DIR} and is not writable."; \
+- echo " Perhaps you need root access."; \
+- echo " Installation aborted, exiting Make."; \
+- exit; \
+- fi; \
+- if [ -d ${INST_DIR} -a ! -w "${INST_DIR}" ] ; then \
+- echo "ERROR: Your install directory ${INST_DIR} is not writable."; \
+- echo " Perhaps you need root access."; \
+- echo " Installation aborted, exiting Make."; \
+- exit; \
+- fi; \
+ result=`echo "${INST_DIR}" | awk '{ if ($$1 ~ /grass/) print $$1 }'`; \
+ if [ "$$result" = "" ] ; then \
+ echo "WARNING: Your install directory ${INST_DIR}"; \
+ echo " does not contain the word 'grass'."; \
+ echo " It is highly recommended that the word 'grass' be part"; \
+ echo " of your install directory to avoid conflicts."; \
+- echo " Do you want to continue? [y/n]"; \
+- read ans; \
+- ans=`echo "$$ans" | tr A-Z a-z`; \
+- if [ "$$ans" != "y" ] ; then \
+- echo "Installation aborted, exiting Make."; \
+- exit; \
+- fi; \
+ fi; \
+ ${MAKE} real-install
+
diff --git a/databases/grass6/files/patch-configure b/databases/grass6/files/patch-configure
new file mode 100644
index 000000000000..7b79e2448b4c
--- /dev/null
+++ b/databases/grass6/files/patch-configure
@@ -0,0 +1,15 @@
+--- configure.orig
++++ configure
+@@ -2485,10 +2485,10 @@
+ FreeBSD-*)
+ # FreeBSD 3.* and greater have ELF.
+ SHLIB_CFLAGS="-fPIC"
+- SHLIB_LD="ld -Bshareable -x"
++ SHLIB_LD="${CC} -shared"
+ SHLIB_LD_LIBS='${LIBS}'
+ SHLIB_SUFFIX=".so"
+- LDFLAGS="-export-dynamic"
++ LDFLAGS="-Wl,--export-dynamic"
+ CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
+ LD_SEARCH_FLAGS='-rpath ${LIB_RUNTIME_DIR}'
+ if test "${GRASS_THREADS}" = "1" ; then
diff --git a/databases/grass6/files/patch-gui__wxpython__Makefile b/databases/grass6/files/patch-gui__wxpython__Makefile
new file mode 100644
index 000000000000..6495922bafbb
--- /dev/null
+++ b/databases/grass6/files/patch-gui__wxpython__Makefile
@@ -0,0 +1,12 @@
+--- gui/wxpython/Makefile.orig
++++ gui/wxpython/Makefile
+@@ -19,7 +19,8 @@
+ mapdisp modules nviz psmap vdigit wxplot)
+ DSTDIRS := $(patsubst %,$(ETCDIR)/%,compat icons scripts xml)
+
+-default: $(DSTFILES) menustrings.py
++default: $(DSTFILES)
++ -$(MAKE) menustrings.py
+ $(MAKE) parsubdirs
+
+ $(ETCDIR)/%: % | $(PYDSTDIRS) $(DSTDIRS)
diff --git a/databases/grass6/files/patch-lib__python__ctypes__ctypesgencore__parser__preprocessor.py b/databases/grass6/files/patch-lib__python__ctypes__ctypesgencore__parser__preprocessor.py
new file mode 100644
index 000000000000..b0294053e23c
--- /dev/null
+++ b/databases/grass6/files/patch-lib__python__ctypes__ctypesgencore__parser__preprocessor.py
@@ -0,0 +1,10 @@
+--- lib/python/ctypes/ctypesgencore/parser/preprocessor.py.orig
++++ lib/python/ctypes/ctypesgencore/parser/preprocessor.py
+@@ -132,6 +132,7 @@
+ if sys.platform == 'darwin':
+ cmd += " -U __BLOCKS__"
+ cmd += " -U __GNUC__"
++ cmd += " -D __GNUCLIKE_BUILTIN_STDARG"
+ cmd += " -dD"
+ for path in self.options.include_search_paths:
+ cmd += " -I%s" % path
diff --git a/databases/grass6/files/patch-lib_ogsf_gsd__img__mpeg.c b/databases/grass6/files/patch-lib_ogsf_gsd__img__mpeg.c
new file mode 100644
index 000000000000..781095185445
--- /dev/null
+++ b/databases/grass6/files/patch-lib_ogsf_gsd__img__mpeg.c
@@ -0,0 +1,102 @@
+--- lib/ogsf/gsd_img_mpeg.c.orig 2013-07-09 19:05:44 UTC
++++ lib/ogsf/gsd_img_mpeg.c
+@@ -38,7 +38,7 @@
+ #define STREAM_DURATION 5.0
+ #define STREAM_FRAME_RATE 25 /* 25 images/s */
+ #define STREAM_NB_FRAMES ((int)(STREAM_DURATION * STREAM_FRAME_RATE))
+-#define STREAM_PIX_FMT PIX_FMT_YUV420P /* default pix_fmt */
++#define STREAM_PIX_FMT AV_PIX_FMT_YUV420P /* default pix_fmt */
+
+ AVFrame *picture, *tmp_picture;
+ uint8_t *video_outbuf;
+@@ -95,11 +95,11 @@ static AVStream *add_video_stream(AVForm
+ c->time_base.num = 1;
+ c->gop_size = 12; /* emit one intra frame every twelve frames at most */
+ c->pix_fmt = STREAM_PIX_FMT;
+- if (c->codec_id == CODEC_ID_MPEG2VIDEO) {
++ if (c->codec_id == AV_CODEC_ID_MPEG2VIDEO) {
+ /* just for testing, we also add B frames */
+ c->max_b_frames = 2;
+ }
+- if (c->codec_id == CODEC_ID_MPEG1VIDEO) {
++ if (c->codec_id == AV_CODEC_ID_MPEG1VIDEO) {
+ /* Needed to avoid using macroblocks in which some coeffs overflow.
+ This does not happen with normal video, it just happens here as
+ the motion of the chroma plane does not match the luma plane. */
+@@ -138,7 +138,7 @@ static AVFrame *alloc_picture(int pix_fm
+ uint8_t *picture_buf;
+ int size;
+
+- picture = avcodec_alloc_frame();
++ picture = av_frame_alloc();
+
+ if (!picture)
+ return NULL;
+@@ -210,8 +210,8 @@ static void open_video(AVFormatContext *
+ picture is needed too. It is then converted to the required
+ output format */
+ tmp_picture = NULL;
+- if (c->pix_fmt != PIX_FMT_YUV420P) {
+- tmp_picture = alloc_picture(PIX_FMT_YUV420P, c->width, c->height);
++ if (c->pix_fmt != AV_PIX_FMT_YUV420P) {
++ tmp_picture = alloc_picture(AV_PIX_FMT_YUV420P, c->width, c->height);
+ if (!tmp_picture) {
+ G_warning(_("Unable to allocate temporary picture"));
+ return;
+@@ -227,7 +227,7 @@ static void open_video(AVFormatContext *
+ */
+ static void write_video_frame(AVFormatContext * oc, AVStream * st)
+ {
+- int out_size, ret;
++ int ret;
+ AVCodecContext *c;
+
+ c = st->codec;
+@@ -250,15 +250,17 @@ static void write_video_frame(AVFormatCo
+ ret = av_write_frame(oc, &pkt);
+ }
+ else {
+- /* encode the image */
+- out_size =
+- avcodec_encode_video(c, video_outbuf, video_outbuf_size, picture);
+- /* if zero size, it means the image was buffered */
+- if (out_size > 0) {
+- AVPacket pkt;
++ AVPacket pkt;
++ int got_packet = 0;
+
+- av_init_packet(&pkt);
++ av_init_packet(&pkt);
++ pkt.data = video_outbuf;
++ pkt.size = video_outbuf_size;
+
++ /* encode the image */
++ ret = avcodec_encode_video2(c, &pkt, picture, &got_packet);
++ /* if zero size, it means the image was buffered */
++ if (ret == 0 && got_packet && pkt.size > 0) {
+ pkt.pts =
+ av_rescale_q(c->coded_frame->pts, c->time_base,
+ st->time_base);
+@@ -269,8 +271,6 @@ static void write_video_frame(AVFormatCo
+ pkt.flags |= AV_PKT_FLAG_KEY;
+ #endif
+ pkt.stream_index = st->index;
+- pkt.data = video_outbuf;
+- pkt.size = out_size;
+
+ /* write the compressed frame in the media file */
+ ret = av_write_frame(oc, &pkt);
+@@ -362,11 +362,11 @@ int gsd_init_mpeg(const char *filename)
+ /* if you want to hardcode the codec (eg #ifdef USE_XVID)
+ this may be the place to do it (?????) */
+ #ifdef USE_XVID
+- fmt->video_codec = CODEC_ID_XVID;
++ fmt->video_codec = AV_CODEC_ID_XVID;
+ #endif
+
+ video_st = NULL;
+- if (fmt->video_codec != CODEC_ID_NONE) {
++ if (fmt->video_codec != AV_CODEC_ID_NONE) {
+ video_st =
+ add_video_stream(oc, fmt->video_codec, (r - l + 1), (t - b + 1));
+ }