Comments (6)
Ok, using GCC 6.2 for both libmustache and pecl/mustache fixes the issue (build + test sutie ok with PHP 5.6/7.0/7.1/7.2)
So fixed on my side by
- https://git.remirepo.net/cgit/rpms/lib/libmustache.git/commit/?id=18e92a27903816b6db19122eb03ddcfb8c29afdd
- https://git.remirepo.net/cgit/rpms/lib/libmustache.git/commit/?id=18e92a27903816b6db19122eb03ddcfb8c29afdd
Closing as very specific to build environment
from php-mustache.
@remicollet I notice I have that error if libmustache is compiled with gcc 4.8, but php-mustache is compiled with gcc 6.2:
FROM centos:7
RUN rm -f /var/lib/rpm/__* && rpm --rebuilddb -v -v && yum clean all
RUN sed -i s/enabled=1/enabled=0/g /etc/yum/pluginconf.d/fastestmirror.conf
RUN yum install -y centos-release-scl
RUN yum install -y yum install devtoolset-6-gcc*
RUN yum install -y php php-devel autoconf automake libtool make m4 git file
RUN yum install -y gcc gcc-c++
RUN gcc --version && \
git clone https://github.com/jbboehr/libmustache.git /libmustache && \
cd /libmustache && \
autoreconf -fiv && \
./configure --without-mustache-spec && \
make clean all install
RUN source scl_source enable devtoolset-6 && \
gcc --version && \
git clone https://github.com/jbboehr/php-mustache.git /php-mustache && \
cd /php-mustache && \
phpize && \
./configure --enable-mustache && \
make clean all
RUN echo "source scl_source enable devtoolset-6 && cd /php-mustache && make test" > /entry.sh && \
chmod +x /entry.sh
CMD "bash" "/entry.sh"
vs
FROM centos:7
RUN rm -f /var/lib/rpm/__* && rpm --rebuilddb -v -v && yum clean all
RUN sed -i s/enabled=1/enabled=0/g /etc/yum/pluginconf.d/fastestmirror.conf
RUN yum install -y centos-release-scl
RUN yum install -y yum install devtoolset-6-gcc*
RUN yum install -y php php-devel autoconf automake libtool make m4 git file
RUN source scl_source enable devtoolset-6 && \
gcc --version && \
git clone https://github.com/jbboehr/libmustache.git /libmustache && \
cd /libmustache && \
autoreconf -fiv && \
./configure --without-mustache-spec && \
make clean all install
RUN source scl_source enable devtoolset-6 && \
gcc --version && \
git clone https://github.com/jbboehr/php-mustache.git /php-mustache && \
cd /php-mustache && \
phpize && \
./configure --enable-mustache && \
make clean all
RUN echo "source scl_source enable devtoolset-6 && cd /php-mustache && make test" > /entry.sh && \
chmod +x /entry.sh
CMD "bash" "/entry.sh"
from php-mustache.
I assume there is some issue with usage of std::unordered_map
in the library vs extension being compiled under different versions of gcc.
from php-mustache.
@remicollet let me know if compiling libmustache and php-mustache with the same version of gcc works for you, and whether or not it's possible to do that for your packaging needs.
I believe ensuring an object is both created and destroyed in code compiled by a particular version of gcc (meaning an object created in php-mustache
would need to also be destroyed in php-mustache
), might be a possible workaround, but it seems dangerous using two different versions to compile parts of the code.
from php-mustache.
whether or not it's possible to do that for your packaging needs.
The issue is that only php 7.1/7.2 are built with gcc 6.2 (which give some perf improvement)
So changing gcc version used for libmustaphe will result in other issue for 5.6/7.0
IIRC, I have tried to build both libmustache and pecl/mustache with 6.2... without success, will try again
from php-mustache.
Perfect!
from php-mustache.
Related Issues (18)
- What's licence for code
- Code coverage HOT 1
- Can't store MustacheTemplate in APC HOT 22
- PHP7: php-mustache do not pass "make test" (segfaults) HOT 12
- Segmentation fault when $data contains objects HOT 7
- Error when building HOT 1
- Allow ArrayAccess for partials HOT 5
- Improve install instructions HOT 4
- Question: Is it possible to extract or access comment data? HOT 7
- crash when HTML is inside tags HOT 3
- Segfault on Fedora 28 HOT 3
- Error compiling on OS X HOT 2
- Deprecate and/or remove VM HOT 2
- pecl install error HOT 3
- PHP 7.4 support
- Memory Leak with PHP-CLI HOT 4
- Test against PHP7 HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from php-mustache.