Eclipse fails to build Java Card sample projects - eclipse

I have installed the new release of Java Card Platform Development Kit, according to the following guide. This includes all the prerequisites, as well as version 3.0.5u2 of JCDK. As a heads up, I tried installing this on 2 different computers (one has Win7, the other Win10) and reinstalled everything on both.
The problem I'm encountering is that none of the sample projects will build properly. When I try to build the HelloWorld sample, for example, I get the following text printed in the build console:
[ INFO: ] Converter [v3.0.5]
[ INFO: ] Copyright (c) 1998, 2017, Oracle and/or its affiliates. All rights reserved.
[ INFO: ] conversion completed with 0 errors and 0 warnings.
[ INFO: ] Converter [v3.0.5]
[ INFO: ] Copyright (c) 1998, 2017, Oracle and/or its affiliates. All rights reserved.
[ INFO: ] conversion completed with 0 errors and 0 warnings.
Missing file containing component hashes.
usage: scriptgen [-options] -hashfile <hash file path> <cap File Path>
where options include:
-help Print this message and exit.
-o <filename> Output filename. default: stdout
-version Print version number and exit.
-nobanner Do not print banner.
-nobeginend Suppress "CAP_BEGIN", "CAP_END" APDU commands.
-package <pkgname> Package name.
While the regular console has this to say:
Executing "$JC_CLASSIC_HOME\bin/converter.bat" -debug -nobanner -out CAP JCA -classdir "$JC_CLASSIC_HOME\samples\classic_applets\HelloWorld\applet\bin" -d "$JC_CLASSIC_HOME\samples\classic_applets\HelloWorld\applet\deliverables" -exportpath "$JC_CLASSIC_HOME\api_export_files" -applet 0xA0:0x00:0x00:0x00:0x62:0x03:0x01:0x0C:0x01:0x01 com.sun.jcclassic.samples.helloworld.HelloWorld com.sun.jcclassic.samples.helloworld 0xA0:0x00:0x00:0x00:0x62:0x03:0x01:0x0C:0x01 1.0
Executing "$JC_CLASSIC_HOME\bin/scriptgen.bat" -package com.sun.jcclassic.samples.helloworld -o "$JC_CLASSIC_HOME\samples\classic_applets\HelloWorld\applet\apdu_scripts/cap-com.sun.jcclassic.samples.helloworld.script" "$JC_CLASSIC_HOME\samples\classic_applets\HelloWorld\applet\deliverables/com/sun/jcclassic/samples/helloworld/javacard/helloworld.cap"
java.io.FileNotFoundException: $JC_CLASSIC_HOME\samples\classic_applets\HelloWorld\applet\apdu_scripts\cap-com.sun.jcclassic.samples.helloworld.script (The system cannot find the file specified)
at java.io.FileInputStream.open(Native Method)
... (stack trace)
Now, I'm not 100% sure, but I think that when I had version 3.0.5u1 installed, I was able to build the sample projects.

It seems the build process of the Java Card Classic Development Kit 3.0.5u2 (jcdk) Eclipse Plugin is broken. During the build of an java card applet, three scripts located in the bin subdirectory of the jcdk installation directory are executed (if using default applet settings in eclipse):
converter.bat generating the export file *.exp
converter.bat generating cap (and jca) file
scriptgen.bat generating the script files for installing the applet to a java card.
The problem is, that scriptgen requires a hashfile containing hashes for the applet components. You can see this if you decompile the class com.sun.javacard.scriptgen.Main of tools.jar in jcdk lib folder.
This hashfile is not generated during the eclipse build process, neither is the scriptgen script called with the corresponding program option "-hashfile <hash-file>". The only workaround currently is using the jcdk tools on the console manually. Therefor you can use the output of console in eclipse and adopt it for your needs.
Example output for a simple test applet:
Executing E:\eclipse-oxygen-64bit\JCDKit_305u2\bin/converter.bat -i -debug -out EXP -classdir G:\eclipse_javacard\workspace\TestJCDKApplet\bin -d G:\eclipse_javacard\workspace\TestJCDKApplet\deliverables -exportpath E:\eclipse-oxygen-64bit\JCDKit_305u2\\api_export_files -applet 0xD0:0x00:0x00:0x00:0x01:0x01:0x01 test.jcdk.applet.TestApplet test.jcdk.applet 0xD0:0x00:0x00:0x00:0x01:0x01 1.0
Executing E:\eclipse-oxygen-64bit\JCDKit_305u2\bin/converter.bat -i -debug -out CAP JCA -classdir G:\eclipse_javacard\workspace\TestJCDKApplet\bin -d G:\eclipse_javacard\workspace\TestJCDKApplet\deliverables -exportpath E:\eclipse-oxygen-64bit\JCDKit_305u2\\api_export_files -applet 0xD0:0x00:0x00:0x00:0x01:0x01:0x01 test.jcdk.applet.TestApplet test.jcdk.applet 0xD0:0x00:0x00:0x00:0x01:0x01 1.0
Executing E:\eclipse-oxygen-64bit\JCDKit_305u2\bin/scriptgen.bat -package test.jcdk.applet -o G:\eclipse_javacard\workspace\TestJCDKApplet\apdu_scripts/cap-test.jcdk.applet.script G:\eclipse_javacard\workspace\TestJCDKApplet\deliverables/test/jcdk/applet/javacard/applet.cap
Modified to generate the required script files (listed only the last two, first two scripts do not change):
G:\eclipse_javacard\workspace\TestJCDKApplet>E:\eclipse-oxygen-64bit\JCDKit_305u2\bin\verifycap.bat -outfile applet.hash E:\eclipse-oxygen-64bit\JCDKit_305u2\api_export_files\java\lang\javacard\lang.exp E:\eclipse-oxygen-64bit\JCDKit_305u2\api_export_files\javacard\framework\javacard\framework.exp .\deliverables\test\jcdk\applet\javacard\applet.exp .\deliverables\test\jcdk\applet\javacard\applet.cap
[ INFO: ] Verifier [v3.0.5]
[ INFO: ] Copyright (c) 1998, 2017, Oracle and/or its affiliates. All rights reserved.
[ INFO: ] Verifying CAP file .\deliverables\test\jcdk\applet\javacard\applet.cap
[ INFO: ] Digest for test/jcdk/applet/javacard/Header.cap [SHA-256: 22e589e7bbb45e420c2a17d5b8abcc437c52f00ecfb15b48ed3257f87eff62f9]
[ INFO: ] Digest for test/jcdk/applet/javacard/Directory.cap [SHA-256: bc72a8594664c9720c38afab7c87b7dda894088f53faefcac548463a4186fbe9]
[ INFO: ] Digest for test/jcdk/applet/javacard/Import.cap [SHA-256: e58492b256b4af8d7f1860f18e57c5336e254a618c2518c987dcefb33db0a8d0]
[ INFO: ] Digest for test/jcdk/applet/javacard/ConstantPool.cap [SHA-256: 6c5bf615cd3746d52c815e8264b910a41a94217161862a7520087799fd03098b]
[ INFO: ] Digest for test/jcdk/applet/javacard/StaticField.cap [SHA-256: 1ec76ec50280f5d8822179bb1b268ae7c2383d9fbe4d6c2beb427090dbf53dfd]
[ INFO: ] Digest for test/jcdk/applet/javacard/RefLocation.cap [SHA-256: b2b3f5e23eee662b8c406212d5cb291959a8eeddb92e58b9a45941c0b91388be]
[ INFO: ] Digest for test/jcdk/applet/javacard/Descriptor.cap [SHA-256: 292e4bd46d836b8501a19a9ea92b1ec976eca1b4920bb03499236284d17be2d7]
[ INFO: ] Digest for test/jcdk/applet/javacard/Class.cap [SHA-256: 6c68abd77e3481a00ae2462cfc8f416ae38d4d0e4b02c685145c39d30d132526]
[ INFO: ] Digest for test/jcdk/applet/javacard/Debug.cap [SHA-256: 7341f35fee494363bb8b84e8c132399a33a0bb4d39fd9192e92be680c08019d3]
[ INFO: ] Digest for test/jcdk/applet/javacard/Method.cap [SHA-256: 651231359c6bb65fbcb0e3a49f52cee1a682ed7e97610365b374583638757365]
[ INFO: ] Digest for test/jcdk/applet/javacard/Applet.cap [SHA-256: e1de8850f009796b9b991757dd378353128e10d4bc6400e5bbd970516bf187f1]
[ INFO: ] Verification completed with 0 warnings and 0 errors.
(Note: you have to add the path to the jcdk export files used by the applet, these you can find out by activating verbose output in the java card package settings and searching the console output for referenced exp files.)
Then at lease you can generate the install script with the command:
G:\eclipse_javacard\workspace\TestJCDKApplet>E:\eclipse-oxygen-64bit\JCDKit_305u2\bin/scriptgen.bat -package test.jcdk.applet -o
G:\eclipse_javacard\workspace\TestJCDKApplet\apdu_scripts/cap-test.jcdk.applet.script G:\eclipse_javacard\workspace\TestJCDKApplet\deliverables/test/jcdk/applet/javacard/applet.cap -hashfile applet.hash
ScriptGen [v3.0.5]
Copyright (c) 1998, 2017, Oracle and/or its affiliates. All rights reserved.
APDU script file for CAP file download generated.

Related

How to compile 32bit x86 application in x86_64-w64-mingw32 gcc-8.1.0 with my *.lds file in VSCODE

I have some attribute((used, section ... )) codes, so I need modify the main.lds file.
run ld --verbose >> main.lds to generate the default main.lds file. It's 64 bits version, I need 32 bits version.
modify main.lds
OUTPUT_FORMAT(pei-i386)
.bss BLOCK(section_alignment) :
{
*(.app_init.0)
*(.app_init.1)
*(.app_init.2) ....
modify tasks.json file in vscode.
"command": "gcc.exe",
"args": [
"-g",
"-m32",
"-fshort-enums",
"${workspaceFolder}\\*.c",
"'-Wl,-Tmain.lds'",
"'-Wl,-Map=${workspaceFolder}\\obj\\${workspaceRootFolderName}.map'",
"-o", "${workspaceFolder}\\obj\\${workspaceRootFolderName}.exe",
],
then I get 32bits main.exe, but it cannot run:
Thread 1 received signal SIGSEGV, Segmentation fault.
0xffffffff in ?? ()
Did I miss something in the main.lds file?
( 1. if I don't modify main.lds and delete "-m32" in tasks.json, I can get 64bit main.exe and it run correctly. and my sections code also run correctly.
2. if I delete "'-Wl,-Tmain.lds'" in tasks.json, I can get 32bit main.exe with default lds file and it run correctly. but my sections code don't run correctly. )
need help. thank you very much.
I had resolved this problem.
gcc -m32 main.c '-Wl,--verbose' can output 32 bits version lds file contents.
this lds file is correct!

parse_vt_settings /dev/tty0 (permission denied)

I am trying to run xinit chromium-browser some_settings address:port in /home/pi/.bashrc file.
What it does in first version of "Jessie PIXEL" is open chromium browser on start up after console auto-login and opens the page address:port.
In new version of Jessie PIXEL I get the following error:
[ 513.403] X.Org X Server 1.18.4 Release Date:
2016-07-19< [ 513.403] X Protocol Version 11, Revision 0 [
513.403] Build Operating System: Linux 4.4.26-v7+ armv7l Raspbian [ 513.403] Current Operating System: Linux raspberrypi 4.4.38-v7+
!!938 SMP Thu Dec 15 15:22:21 GMT 2016 armv7l [ 513.403] Kernel command line: 8250.nr_uarts=1 dma.dmachans=0x7f35
bcm2708_fb.fbwidth=1920 bcm2708_fb.fbheight=1080
bcm2709.boardrev=0x2a02082 bcm2709.serial=0xff00$ [ 513.403]
Build Date: 11 November 2016 11:59:59AM [ 513.403] xorg-server
2:1.18.4-2+rpi1 (https://www.debian.org/support) [ 513.403]
Current version of pixman: 0.33.3 [ 513.403] Before
reporting problems, check http://wiki.x.org
to make sure that you have the latest version. [ 513.403] Markers: (--) probed, () from config file, (==) default setting,
(++) from command line, (!!) notice, (II) informational,
(WW) warning, (EE) error, (NI) not implemented, (??) unknown. [ 513.403] (==) Log file:
"/home/pi/.local/share/xorg/Xorg.0.log", Time: Fri Dec 23 09:46:08
2016 [ 513.404] (==) Using system config directory
"/usr/share/X11/xorg.conf.d" [ 513.404] (==) No Layout section.
Using the first Screen section. [ 513.404] (==) No screen
section available. Using defaults. [ 513.405] () |-->Screen
"Default Screen Section" (0) [ 513.405] () | |-->Monitor
"" [ 513.405] (==) No device specified for
screen "Default Screen Section".
Using the first device section listed. [ 513.405] () | |-->Device "Allwinner A10/A13 FBDEV" [ 513.405] (==) No monitor
specified for screen "Default Screen Section".
Using a default monitor configuration. [ 513.405] (==) Automatically adding devices [ 513.405] (==) Automatically
enabling devices [ 513.405] (==) Automatically adding GPU
devices [ 513.405] (==) Max clients allowed: 256, resource
mask: 0x1fffff [ 513.405] (WW) The directory
"/usr/share/fonts/X11/misc" does not exist. [ 513.405] Entry
deleted from font path. [ 513.405] (WW) The directory
"/usr/share/fonts/X11/cyrillic" does not exist. [ 513.405]
Entry deleted from font path. [ 513.405] (WW) The directory
"/usr/share/fonts/X11/75dpi/" does not exist. [ 513.405]
Entry deleted from font path. [ 513.405] (WW) The directory
"/usr/share/fonts/X11/75dpi" does not exist. [ 513.405]
Entry deleted from font path. [ 513.405] (==) FontPath set
to:
/usr/share/fonts/X11/100dpi/:unscaled,
/usr/share/fonts/X11/Type1,
/usr/share/fonts/X11/100dpi,
built-ins [ 513.405] (==) ModulePath set to "/usr/lib/xorg/modules" [ 513.405] (II) The server relies on
udev to provide the list of input devices.
If no devices become available, reconfigure udev or disable AutoAddDevices. [ 513.406] (II) Loader magic: 0x54d5cf20 [
513.406] (II) Module ABI versions: [ 513.406] X.Org ANSI C Emulation: 0.4 [ 513.406] X.Org Video Driver: 20.0 [
513.406] X.Org XInput driver : 22.1 [ 513.406] X.Org Server Extension : 9.0 [ 513.411] (II) systemd-logind: took
control of session /org/freedesktop/login1/session/c2 [
513.411] (II) no primary bus or device found [ 513.411] (II) LoadModule: "glx" [ 513.412] (II) Loading
/usr/lib/xorg/modules/extensions/libglx.so [ 513.416] (II)
Module glx: vendor="X.Org Foundation" [ 513.416] compiled
for 1.18.4, module version = 1.0.0 [ 513.416] ABI class:
X.Org Server Extension, version 9.0 [ 513.416] (==) AIGLX
enabled [ 513.416] (II) LoadModule: "fbturbo" [ 513.416]
(II) Loading /usr/lib/xorg/modules/drivers/fbturbo_drv.so [
513.417] (II) Module fbturbo: vendor="X.Org Foundation" [ 513.417] compiled for 1.18.4, module version = 0.5.1 [ 513.417] Module class: X.Org Video Driver [ 513.417] ABI class: X.Org Video Driver, version 20.0 [ 513.417] (II)
FBTURBO: driver for framebuffer: fbturbo [ 513.417] (EE)
Fatal server error: [ 513.417] (EE) parse_vt_settings: Cannot
open /dev/tty0 (Permission denied) [ 513.417] (EE) [
513.417] (EE) Please consult the The X.Org Foundation support
at http://wiki.x.org for help. [ 513.417] (EE) Please also check the log file at
"/home/pi/.local/share/xorg/Xorg.0.log" for additional
information. [ 513.417] (EE) [ 513.418] (WW)
xf86CloseConsole: KDSETMODE failed: Bad file descriptor [
513.418] (WW) xf86CloseConsole: VT_GETMODE failed: Bad file descriptor [ 513.419] (EE) Server terminated with error (1).
Closing log file.
Does anybody know where lies the problem?
PS If You see '*' in the log it was '**' but that is bold text
Also there is '!!' in log that was '#' but thats bold
In particular, you want to add your user to the tty group to resolve this specific issue.
gpasswd -a pi tty
where pi is your user.
I encountered the same issue.
How I solve this was:
create new user named teacher
grant all groups that pi has
cp the /etc/suders.d/010_pi-nopasswd and rename the inner username to teacher
startx and it works.
Be careful:
don't run startx in byobu, some bugs.
I found a solution:
I don't use .bashrc anymore and I fully moved to rc.local.
sudo node /home/pi/server/server.js &
xinit /usr/bin/chromium-browser --no-sandbox --window-size=1920,1080 --noerrdialogs --start-fullscreen --start-maximized --disable-notifications --disable-infobars --kiosk --incognito http://localhost:3000 -- -nocursor &
exit 0
What this does is runs node.js server on port 3000 and runs chromium on localhost:3000 with no mouse cursor and fully sized chromium browser in something like 15-20 sec time.
Now working on showing it without going blank. Still no success, HELP!
EDIT:
If chromium appears with borders use this:
xinit /usr/bin/chromium-browser --no-sandbox --window-position=0,0 --window-size=1920,1080 --noerrdialogs --disable-notifications --disable-infobars --kiosk --incognito http://localhost:3000 -- -nocursor &

Installanywhere Openjdk 1.7.0_111

i have a problem.
i'm using installanywhere for some product. (installanywhere 2014 SP1)
setting installanywhere option,
Product > JVM Settings > VM valid List : JDK_1.7+, IBM_JDK_1.7+
this option installer choose openjdk.
i'm success install in openjdk 1.7.0_65, redhat 6.x 64bit os.
but install failed in openjdk 1.7.0_111, redbat 6.x 64bit os.
error message -
===============================================================================
This Test installer (created with InstallAnywhere)
-------------------------------------------------------------------------------
Preparing CONSOLE Mode Installation...
This installer was created with an unlicensed version
of InstallAnywhere. The evaluation period has expired.
Please contact sales#flexerasoftware.com about licensing.
so, commanding [export LAX_DEBUG=true] and install.
under line debug message.
Preparing to install...
Checking for POSIX df.
Found POSIX df.
Checking tail options...
Using tail -n 1.
True location of the self extractor: /opt/Test/Test_Setup_RedHat.bin
Forcing install base (including tmp dir) to: /opt/Test/tmp
Creating installer data directory: /opt/Test/tmp/install.dir.27084
Creating installer data directory: /opt/Test/tmp/install.dir.27084/InstallerData
Gathering free-space information...
Space needed to complete the self-extraction: 16376 blocks
Available space: 242730896 blocks
Available blocks: 242730896 Needed blocks: 16376 (block = 512 bytes)
This installation does not contain a VM.
Extracting the installation resources from the installer archive...
Extracting install.zip from ./Test_Setup_RedHat.bin to /opt/Test/tmp/install.dir.27084/InstallerData/installer.zip ...
Extracting to padded done, exit code = 0
Extracting from padded to zip done, exit code = 0
Creating disk1 data directory: /opt/Test/tmp/install.dir.27084/InstallerData/Disk1
Creating instdata data directory: /opt/Test/tmp/install.dir.27084/InstallerData/Disk1/InstData
Extracting resources from ./Test_Setup_RedHat.bin to /opt/Test/tmp/install.dir.27084/InstallerData/Disk1/InstData/Resource1.zip ...
Extracting done, exit code = 0
Configuring the installer for this system's environment...
[7m========= Analyzing UNIX Environment =================================[0m
Setting UNIX (linux) flavor specifics.
Importing UNIX environment into LAX properties.
Checking for POSIX awk.
[7m========= Analyzing LAX ==============================================[0m
LAX found............................ OK.
LAX properties read.................. OK.
[7m========= Finding VM =================================================[0m
[1mValid VM types.......................... JDK_1.7+, IBM_JDK_1.7+[0m
[1mExpanded Valid VM types................. JDK_1.7+, IBM_JDK_1.7+ [0m
Found jvmspecs.properties
JVM Spec Build Option Specified Without VM
Searching without JVM specs
Searching without JVM specs
[1mWARNING! No valid lax.nl.current.vm available.[0m
/usr/xpg4/bin:/usr/local/bin:/bin:/usr/bin:/usr/local/sbin:/usr/sbin:/sbin:/var/cfengine/bin:/bin:/usr/bin:/sbin:/usr/sbin:/usr/local/bin
[1mSearching for VMs in PATH:[0m
Looking in:............................. /usr/xpg4/bin
Looking in:............................. /usr/local/bin
Looking in:............................. /bin
Looking in:............................. /usr/bin
Found VM:............................. /usr/bin/java
Version:............................. 1.7.0_111
Looking in:............................. /usr/local/sbin
Looking in:............................. /usr/sbin
Looking in:............................. /sbin
Looking in:............................. /var/cfengine/bin
Looking in:............................. /bin
Looking in:............................. /usr/bin
Found VM:............................. /usr/bin/java
Version:............................. 1.7.0_111
Looking in:............................. /sbin
Looking in:............................. /usr/sbin
Looking in:............................. /usr/local/bin
checking: "1.7.0_111" against "JDK_1.7+,": failed (wrong version)
checking: "1.7.0_111" against "JDK_1.7+,": failed (wrong version)
checking: "1.7.0_111" against "IBM_JDK_1.7+": passed
[1m Using VM:............................. /usr/lib/jvm/jre-1.7.0-openjdk.x86_64/bin/java[0m
[7m========= Virtual Machine Options ====================================[0m
LAX properties incorporated............. OK.
classpath............................... "/opt/Test/tmp/install.dir.27084/InstallerData:/opt/Test/tmp/install.dir.27084/InstallerData/installer.zip"
main class.............................. "com.zerog.ia.installer.Main"
.lax file path.......................... "/opt/Test/tmp/install.dir.27084/temp.lax"
user directory.......................... "/opt/Test/tmp/install.dir.27084"
stdout to............................... "console"
sterr to................................ "console"
install directory....................... ""
JIT..................................... none
option (verify)......................... off
option (verbosity)...................... none
option (garbage collection extent)...... none
option (garbage collection thread)...... none
option (native stack max size).......... none
option (java stack max size)............ none
option (java heap max size)............. 50331648
option (java heap initial size)......... 16777216
option (lax.nl.java.option.additional).. none
[7m========= Display settings ===========================================[0m
X display............................... not set
[1mWARNING: This shell's DISPLAY variable has not been set.
This installer is configured to run in GUI and will probably
fail. Try running this installer in console or silent mode,
or on another UNIX host which has the DISPLAY variable set,
if the installer unexpectedly fails.[0m
UI mode................................. gui
Launching installer...
[7m========= VM Command Line ============================================[0m
[1moptions:[0m
[7mCLASSPATH:[0m/opt/Test/tmp/install.dir.27084/InstallerData:/opt/Test/tmp/install.dir.27084/InstallerData/installer.zip:
[7m========= Forking JAVA =============================================[0m
OpenJDK 64-Bit Server VM warning: Insufficient space for shared memory file:
27084
Try using the -Djava.io.tmpdir= option to select an alternate temp location.
===============================================================================
This Test installer (created with InstallAnywhere)
-------------------------------------------------------------------------------
Preparing CONSOLE Mode Installation...
This installer was created with an unlicensed version
of InstallAnywhere. The evaluation period has expired.
Please contact sales#flexerasoftware.com about licensing.
what should i do? success running open jdk 1.7.0_65, but open jdk 1.7.0_111 failed.
CentOS 6.2 and OpenJDK1.7.0_111 running success.

Segfault on mongodb extension 1.1.2/1.1.3-dev with PHP 7 FPM under gentoo

I am heaving a strange problem under gentoo. Mongodb extension is working fine in apache2 and cli, but fpm fails to start:
/etc/init.d/php-fpm restart
* Testing PHP FastCGI Process Manager configuration ...
[30-Jan-2016 13:59:47] NOTICE: configuration file /etc/php/fpm-php7.0/php-fpm.conf test is successful
zend_mm_heap corrupted [ !! ]
php -v
PHP 7.0.2-pl5-gentoo (cli) (built: Jan 30 2016 13:16:21) ( ZTS )
Copyright (c) 1997-2015 The PHP Group
Zend Engine v3.0.0, Copyright (c) 1998-2015 Zend Technologies
with Zend OPcache v7.0.6-dev, Copyright (c) 1999-2015, by Zend Technologies
Here is the info from cli:
php -i|grep mongo
mongodb
mongodb support => enabled
mongodb version => 1.1.3-dev
mongodb stability => devel
libmongoc version => 1.3.1-dev
mongodb.debug => no value => no value
I even compiled mongodb without sasl but the result is the same.
Mongodb extension was manually compiled like this(my system is x86_64):
git clone https://github.com/mongodb/mongo-php-driver.git
cd mongo-php-driver; git submodule sync && git submodule update --init
Run phpize:
phpize --clean
phpize
Remove the aclocal.m4 file:
rm aclocal.m4
Run aclocal and autoconf:
aclocal
autoconf
Now configure, make and install the package:
./configure --without-mongodb_sasl (i tried with and without this)
make
make install
add extension=mongodb.so in php.ini: /etc/php/fpm-php7.0/php.ini
restart php-fpm: /etc/init.d/php-fpm restart
The strangest thing is that if i start php-fpm process with gdb to backtrace the extensions works.
gdb -q /usr/lib/php7.0/bin/php-fpm
Reading symbols from /usr/lib/php7.0/bin/php-fpm...(no debugging symbols found)...done.
(gdb) set args --pid /run/php-fpm.pid --fpm-config /etc/php/fpm-php7.0/php-fpm.conf -c /etc/php/fpm-php7.0/
(gdb) run
Starting program: /usr/lib64/php7.0/bin/php-fpm --pid /run/php-fpm.pid --fpm-config /etc/php/fpm-php7.0/php-fpm.conf -c /etc/php/fpm-php7.0/
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib64/libthread_db.so.1".
[Inferior 1 (process 4075) exited normally]
(gdb)
Any help is apreciated
For the sake of the lazy googler, this is fixed in version 1.1.5 of the php-mongodb-driver

I am getting the following error after installing Pint-OS and trying to run multiple alarm. I am using bochs as emulator. Any possible work around?

Prototype mismatch: sub main::SIGVTALRM () vs none at /home/abhijay/pintos-os/pintos/src/utils/pintos line 934.
Constant subroutine SIGVTALRM redefined at /home/abhijay/pintos-os/pintos/src/utils/pintos line 926.
warning: can't find squish-pty, so terminal input will fail
bochs -q
========================================================================
Bochs x86 Emulator 2.4.6
Build from CVS snapshot, on February 22, 2011
Compiled at Jun 8 2013, 05:16:04
========================================================================
00000000000i[ ] LTDL_LIBRARY_PATH not set. using compile time default '/usr/lib/bochs/plugins'
00000000000i[ ] BXSHARE not set. using compile time default '/usr/share/bochs'
00000000000i[ ] reading configuration from bochsrc.txt
00000000000e[ ] user_shortcut: old-style syntax detected
00000000000i[ ] lt_dlhandle is 0x37ed0c0
00000000000i[PLGIN] loaded plugin libbx_x.so
00000000000i[ ] installing x module as the Bochs GUI
00000000000i[ ] using log file bochsout.txt
bochs-bin: symbol lookup error: /usr/lib/bochs/plugins/libbx_x.so: undefined symbol: XpmCreatePixmapFromData
Any workaround for this? I have installed build-essentials and bochs simulator.
You have to just go to the file /home/abhijay/pintos-os/pintos/src/utils/pintos and comment out the whole function SIGVTALRM () .It should work fine.