Code Monkey home page Code Monkey logo

stefanocasazza / ulib Goto Github PK

View Code? Open in Web Editor NEW
947.0 947.0 109.0 20.59 MB

C++ application development framework, to help developers create and deploy applications quickly and simply

License: GNU Lesser General Public License v3.0

Shell 8.89% Makefile 8.79% C 27.75% C++ 46.18% Awk 0.06% LLVM 0.01% CSS 0.66% HTML 0.80% JavaScript 1.19% Python 0.06% XSLT 0.11% Ruby 0.01% Perl 0.03% Yacc 0.01% M4 1.79% Roff 0.08% PHP 0.01% Objective-C 3.40% Dockerfile 0.18%
cgi-support cplusplus library web-application

ulib's People

Contributors

archnemsys avatar stefanocasazza avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

ulib's Issues

Multiple ab -n 10000 -c 1000 test for calc.usp with error

i did multiple ab -c 1000 -n 100000 tests, how do i resolve this? what should i put to handle multiple concurrent requests?

userver_tcp: DEBUG: 13/12/17 15:43:39 (pid 31729) Out of space on client image preallocation(129): num_connection(129)
userver_tcp: WARNING: 13/12/17 15:43:39 (pid 31730) Polling mode suspect: cround = 2 nothing = 129 num_connection = 129

userver_tcp: DEBUG: 13/12/17 15:43:39 (pid 31730) It has returned below the client threshold(86): preallocation(129) num_connection(84)
userver_tcp: DEBUG: 13/12/17 15:43:39 (pid 31731) It has returned below the client threshold(86): preallocation(129) num_connection(84)
userver_tcp: DEBUG: 13/12/17 15:43:39 (pid 31729) It has returned below the client threshold(86): preallocation(129) num_connection(84)
userver_tcp: DEBUG: 13/12/17 15:43:39 (pid 31728) It has returned below the client threshold(86): preallocation(129) num_connection(84)
userver_tcp: DEBUG: 13/12/17 15:43:40 (pid 31731) It has passed the client threshold(86): preallocation(129) num_connection(85)
userver_tcp: DEBUG: 13/12/17 15:43:40 (pid 31731) It has returned below the client threshold(86): preallocation(129) num_connection(84)


| ***** **** **** *** **** |
| * * * * * * * * * |
| ***** **** **** * * **** |
| * * * * * * * * * |
| ***** * * * * *** * * |

userver_tcp: NOT DIFFERENT

pid: 31731
file: notifier.cpp
line: 624
function: static void UNotifier::waitForEvent(UEventTime*)
assertion: "((handler_event->fd)!=(-1))"

For real world practical usage's docker container

I'm ready to take the next step to explore in greater detail but I'm having problem with some of the configuration settings. I'm using Ubuntu 16.04 docker container.
Can you please provide the instructions to compile / configure for these options inside the docker container? It took me quite some time and I can't seem to make "some useful ones" work.

Will really appreciate if you can provide the ./configure (for real world application these settings)

  1. --with-mysql
  2. --with-mongodb
  3. --enable-http2
  4. --enable-HIS
  5. --enable-throttling (not sure what is this for? cache?)
  6. --enable-evasive (good to have but quite optional for me)
  7. --enable-curl (good to have)
  8. --with-ssh (for the cookie.usp? cant seem to get this right)
  9. --with-v8-javascript (for testing purposes)
  10. --with-ssl (for cookie.usp?)

these are the very real world practical example. Hope to deploy a case studies and help speed up the development of this. Appreciate it. I would like to run a few .usp examples inside for serious real world work asap... Thanks in advance.

USP arg.strtod() erroneous output

encountering odd string to double conversion issues ?
please find a minimal example and logs.

log.zip

.usp

<!--#args
arg1("0");
  -->

<!--#code
double val1 = arg1.strtod();
USP_PRINTF("\n %v = %lf", arg1.rep, val1);
USP_PRINTF("\n %v = %g", arg1.rep, val1);
  -->

Output

0 = nan
0 = 2.8088955232223686e308

System date not updated

Got the following error trying to run (and benchmark) ulib:
userver_tcp: ERROR: 02/07/15 02:30:37 (pid 34590) System date not updated - Exiting...

What does this mean and how do I resolve it?

How to route in USP code?

Consider I have an usp file say one.usp which gives me one.so so that my URL served is http://localhost/one. Now if I want to serve http://localhost/one/two then how can I achieve that?

Compilaion problems

On a new Linux installation I downloaded ULib 1.4.2 release. Build and install went clean. However, I am still having problems with usp file compilation.

shiv@laptop:~/Downloads/ULib-1.4.2/src/ulib/net/server/plugin/usp$ usp_compile.sh hello
g++: error: unrecognized command line option ‘-Wduplicated-cond’
g++: error: unrecognized command line option ‘-Wtautological-compare’
g++: error: unrecognized command line option ‘-Wshift-negative-value’
g++: error: unrecognized command line option ‘-Wshift-overflow’
g++: error: unrecognized command line option ‘-Wshift-overflow=2’
g++: error: unrecognized command line option ‘-Wnull-dereference’
g++: error: unrecognized command line option ‘-Wterminate’
g++: error: unrecognized command line option ‘-Wlto-type-mismatch’
g++: error: unrecognized command line option ‘-Wsubobject-linkage’
g++: error: unrecognized command line option ‘-Wplacement-new’
g++: error: unrecognized command line option ‘-Wvirtual-inheritance’
g++: error: unrecognized command line option ‘-Wnamespaces’
mv: cannot stat '.libs/hello.usp': No such file or directory
mv: cannot stat '.libs/hello.so': No such file or directory
shiv@laptop:~/Downloads/ULib-1.4.2/src/ulib/net/server/plugin/usp$

usp_compile.sh is located in /usr/local/bin. userver_tcp works fine but I am unable to compile any usp file.

memleak

hi stefano,

i experienced memleak when PREFORK_CHILD was set bigger than 1 in server config.

I found that logbuf and clientAddress in UClientImage_Base::destroy() deleted in case DEBUG define set.

i don't experience memleak after deleting #ifdef DEBUG.

regards,
ivan

Benchmarking "problem"

I did benchmark with wrk

wrk -c 10000 -d 10 -t 4 http://172.17.0.33/upload


Results


Running 10s test @ http://172.17.0.33/upload
4 threads and 10000 connections
Thread Stats Avg Stdev Max +/- Stdev
Latency 5.46ms 4.89ms 124.78ms 95.82%
Req/Sec 15.59k 5.59k 27.59k 68.18%
614353 requests in 10.07s, 170.49MB read
Socket errors: connect 0, read 8257, write 0, timeout 0
Requests/sec: 61024.54
Transfer/sec: 16.94MB

"Errors" generated. Seems like some "read" is dropped/failed? Is this normal?

How do I make wrk run to complete all requests made? I've already made whitelist userver.cfg for my IP.


userver_tcp: WARNING: 21/12/17 17:57:11 (pid 16559) Polling mode suspect: cround = 2 nothing = 85 num_connection = 85
userver_tcp: WARNING: 21/12/17 17:57:11 (pid 16558) Polling mode suspect: cround = 2 nothing = 85 num_connection = 85
userver_tcp: WARNING: 21/12/17 17:57:11 (pid 16559) Polling mode suspect: cround = 2 nothing = 85 num_connection = 85
userver_tcp: WARNING: 21/12/17 17:57:11 (pid 16558) Polling mode suspect: cround = 2 nothing = 85 num_connection = 85
userver_tcp: WARNING: 21/12/17 17:57:11 (pid 16559) Polling mode suspect: cround = 2 nothing = 85 num_connection = 85
userver_tcp: WARNING: 21/12/17 17:57:11 (pid 16558) Polling mode suspect: cround = 2 nothing = 85 num_connection = 85
userver_tcp: WARNING: 21/12/17 17:57:11 (pid 16558) Polling mode suspect: cround = 2 nothing = 85 num_connection = 85
userver_tcp: WARNING: 21/12/17 17:57:11 (pid 16558) Polling mode suspect: cround = 2 nothing = 85 num_connection = 85
userver_tcp: WARNING: 21/12/17 17:57:11 (pid 16558) Polling mode suspect: cround = 2 nothing = 85 num_connection = 85
userver_tcp: WARNING: 21/12/17 17:57:11 (pid 16558) Polling mode suspect: cround = 2 nothing = 85 num_connection = 85
userver_tcp: WARNING: 21/12/17 17:57:11 (pid 16558) Polling mode suspect: cround = 2 nothing = 85 num_connection = 85
userver_tcp: WARNING: 21/12/17 17:57:11 (pid 16558) Polling mode suspect: cround = 2 nothing = 85 num_connection = 85
userver_tcp: WARNING: 21/12/17 17:57:11 (pid 16558) Polling mode suspect: cround = 2 nothing = 85 num_connection = 85
userver_tcp: WARNING: 21/12/17 17:57:11 (pid 16558) Polling mode suspect: cround = 2 nothing = 85 num_connection = 85
userver_tcp: WARNING: 21/12/17 17:57:11 (pid 16558) Polling mode suspect: cround = 2 nothing = 85 num_connection = 85
userver_tcp: WARNING: 21/12/17 17:57:11 (pid 16558) Polling mode suspect: cround = 2 nothing = 85 num_connection = 85
userver_tcp: WARNING: 21/12/17 17:57:11 (pid 16558) Polling mode suspect: cround = 2 nothing = 85 num_connection = 85
userver_tcp: WARNING: 21/12/17 17:57:11 (pid 16558) Polling mode suspect: cround = 2 nothing = 85 num_connection = 85
userver_tcp: WARNING: 21/12/17 17:57:11 (pid 16558) Polling mode suspect: cround = 2 nothing = 85 num_connection = 85
userver_tcp: WARNING: 21/12/17 17:57:11 (pid 16558) Polling mode suspect: cround = 2 nothing = 85 num_connection = 85
userver_tcp: WARNING: 21/12/17 17:57:11 (pid 16558) Polling mode suspect: cround = 2 nothing = 85 num_connection = 85
userver_tcp: WARNING: 21/12/17 17:57:11 (pid 16558) Polling mode suspect: cround = 2 nothing = 85 num_connection = 85
userver_tcp: WARNING: 21/12/17 17:57:11 (pid 16558) Polling mode suspect: cround = 2 nothing = 85 num_connection = 85
userver_tcp: WARNING: 21/12/17 17:57:11 (pid 16558) Polling mode suspect: cround = 2 nothing = 85 num_connection = 85
userver_tcp: WARNING: 21/12/17 17:57:11 (pid 16558) Polling mode suspect: cround = 2 nothing = 85 num_connection = 85
userver_tcp: WARNING: 21/12/17 17:57:11 (pid 16558) Polling mode suspect: cround = 2 nothing = 85 num_connection = 85
userver_tcp: WARNING: 21/12/17 17:57:11 (pid 16558) Polling mode suspect: cround = 2 nothing = 85 num_connection = 85
userver_tcp: WARNING: 21/12/17 17:57:11 (pid 16558) Polling mode suspect: cround = 2 nothing = 85 num_connection = 85
userver_tcp: WARNING: 21/12/17 17:57:11 (pid 16558) ::recv(10,0x7faa81f8a000,8192,0) = -1 - ECONNRESET (104, Connection reset by peer)
userver_tcp: WARNING: 21/12/17 17:57:11 (pid 16560) Polling mode suspect: cround = 2 nothing = 85 num_connection = 85
userver_tcp: WARNING: 21/12/17 17:57:11 (pid 16560) ::recv(10,0x7faa81f8a000,8192,0) = -1 - ECONNRESET (104, Connection reset by peer)
userver_tcp: WARNING: 21/12/17 17:57:11 (pid 16559) Polling mode suspect: cround = 2 nothing = 85 num_connection = 85
userver_tcp: DEBUG: 21/12/17 17:57:11 (pid 16558) It has returned below the client threshold(86): preallocation(129) num_connection(84)
userver_tcp: DEBUG: 21/12/17 17:57:11 (pid 16558) It has passed the client threshold(86): preallocation(129) num_connection(85)
userver_tcp: WARNING: 21/12/17 17:57:11 (pid 16558) ::recv(11,0x7faa81f8a000,8192,0) = -1 - ECONNRESET (104, Connection reset by peer)
userver_tcp: DEBUG: 21/12/17 17:57:11 (pid 16558) It has returned below the client threshold(86): preallocation(129) num_connection(84)
userver_tcp: WARNING: 21/12/17 17:57:11 (pid 16559) Polling mode suspect: cround = 2 nothing = 85 num_connection = 85
userver_tcp: WARNING: 21/12/17 17:57:11 (pid 16559) Polling mode suspect: cround = 2 nothing = 85 num_connection = 85
userver_tcp: WARNING: 21/12/17 17:57:11 (pid 16561) Polling mode suspect: cround = 2 nothing = 85 num_connection = 85
userver_tcp: WARNING: 21/12/17 17:57:11 (pid 16559) Polling mode suspect: cround = 2 nothing = 85 num_connection = 85
userver_tcp: WARNING: 21/12/17 17:57:11 (pid 16561) ::recv(10,0x7faa81f8a000,8192,0) = -1 - ECONNRESET (104, Connection reset by peer)
userver_tcp: DEBUG: 21/12/17 17:57:11 (pid 16561) It has returned below the client threshold(86): preallocation(129) num_connection(84)
userver_tcp: DEBUG: 21/12/17 17:57:11 (pid 16560) It has returned below the client threshold(86): preallocation(129) num_connection(84)
userver_tcp: DEBUG: 21/12/17 17:57:11 (pid 16561) It has passed the client threshold(86): preallocation(129) num_connection(85)
userver_tcp: WARNING: 21/12/17 17:57:11 (pid 16561) ::recv(11,0x7faa81f8a000,8192,0) = -1 - ECONNRESET (104, Connection reset by peer)

How to use/set plugin_echo ?

Hello !

After getting userver_tcp to work I was looking for a way to use plugin_echo to test but could not find any reference to how to do that.

I was thinking that it would be possible to attach/manage a specific location inside a server definition, more or less like nginx, I mean "location /myecho => palugin_echo".

How to to it ?

Again any sort of tutorial about plugins and it's usage would allow more people to use/test ULIB.

Cheers !

Binding UString with sqlite3_bind_text

Consider the attached query of the sample fortunes db.

SELECT id, message FROM Fortune WHERE message='Feature: A bug with seniority.'
result
"9"	"Feature: A bug with seniority."

A static query such as the above returns the correct result as does queries with integer bind parameters. However when binding UString types such as below no rows are returned.

SELECT id, message FROM Fortune WHERE message=?
pstmt_query->use(p_query->message);
pstmt_query->into(p_query->id, p_query->message);

Adjusting the trace parameter as below:pc

void UOrmDriverSqlite::execute(USqlStatement* pstmt)
{
   //U_TRACE(0, "UOrmDriverSqlite::execute(%p)", pstmt)
   U_TRACE(0, "UOrmDriverSqlite::execute(%s)", sqlite3_expanded_sql((sqlite3_stmt*)pstmt->pHandle));

reveals that although the bind returned true the statement has NULL for the parameter?

Return USqliteStatement::setBindParam(0x555555790a20) = true
::sqlite3_step(0x5555557ab030) = 101 // Sqlite ready no rows returned
Return UOrmDriverSqlite::execute(SELECT id, message FROM Fortune WHERE message=NULL)

To recreate the above install ULib unzip the attached make and execute bin/webserver.sh
code.zip

Not sure how to use...

I've managed to installed with make and make install

i've put the ULib/src/ulib/net/server/plugin/usp/hello.usp into /var/www

i ran with 127.0.0.1/hello.usp and below is the result I got. index.html is running fine. how do i resolve the problem below?


userver_tcp: WARNING: 07/12/17 14:08:06 (pid 28693) Cannot set posix realtime scheduling policy
userver_tcp: WARNING: 07/12/17 14:08:07 (pid 28694) Cannot set posix realtime scheduling policy
userver_tcp: WARNING: 07/12/17 14:08:07 (pid 28695) Cannot set posix realtime scheduling policy
userver_tcp: WARNING: 07/12/17 14:08:08 (pid 28696) Cannot set posix realtime scheduling policy
-
 pid: 28562
 address: 0x8 - SEGV_MAPERR (1, Address not mapped to object)
 rss usage: 316.31 MBytes
 address space usage: 66.33 MBytes
-
userver_tcp: ABORT: 07/12/17 14:05:21 (pid 28561) program interrupt by the kernel - SIGSEGV (11, Segmentation fault)
-

Compilation error

I face following error while compiling:


shiv@shiv-VirtualBox:~/Downloads/ULib$ make -j4 
Making all in include
make[1]: Entering directory '/home/shiv/Downloads/ULib/include'
Making all in ulib
make[2]: Entering directory '/home/shiv/Downloads/ULib/include/ulib'
make[2]: Nothing to be done for 'all'.
make[2]: Leaving directory '/home/shiv/Downloads/ULib/include/ulib'
make[2]: Entering directory '/home/shiv/Downloads/ULib/include'
make[2]: Nothing to be done for 'all-am'.
make[2]: Leaving directory '/home/shiv/Downloads/ULib/include'
make[1]: Leaving directory '/home/shiv/Downloads/ULib/include'
Making all in src/ulib
make[1]: Entering directory '/home/shiv/Downloads/ULib/src/ulib'
  CXX      all_cpp.lo
In file included from all_cpp.cpp:34:0:
net/socket.cpp:27:56: note: #pragma message: LINUX_VERSION_CODE = 263247
In file included from all_cpp.cpp:38:0:
net/server/server.cpp: In member function ‘virtual void UTimeThread::run()’:
net/server/server.cpp:1133:76: error: ‘class ULog’ has no member named ‘checkForLogRotateDataToWrite’
   if (UServer_Base::log)                         UServer_Base::log->checkForLog
                                                                     ^
net/server/server.cpp:1134:76: error: ‘class ULog’ has no member named ‘checkForLogRotateDataToWrite’
   if (UServer_Base::apache_like_log) UServer_Base::apache_like_log->checkForLog
                                                                     ^
In file included from all_cpp.cpp:49:0:
utility/semaphore.cpp: At global scope:
utility/semaphore.cpp:20:56: note: #pragma message: LINUX_VERSION_CODE = 263247
Makefile:1735: recipe for target 'all_cpp.lo' failed
make[1]: *** [all_cpp.lo] Error 1
make[1]: Leaving directory '/home/shiv/Downloads/ULib/src/ulib'
Makefile:559: recipe for target 'all-recursive' failed
make: *** [all-recursive] Error 1

configure on mac os fails

Platform: �[1mDarwin 15.0.0 (i386)�[m
Configuring �[1mULib�[m (C++ Library)

�[1mInitial phase:�[m
checking build system type... x86_64-apple-darwin15.0.0
checking host system type... x86_64-apple-darwin15.0.0
checking target system type... x86_64-apple-darwin15.0.0
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... ./install-sh -c -d
checking for gawk... no
checking for mawk... no
checking for nawk... no
checking for awk... awk
checking whether make sets $(MAKE)... yes
checking whether make supports nested variables... yes
checking how to create a pax tar archive... gnutar
checking whether to enable maintainer-specific portions of Makefiles... no
checking whether make supports nested variables... (cached) yes
checking for style of include used by make... GNU
checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking whether gcc understands -c and -o together... yes
checking dependency style of gcc... gcc3
checking how to run the C preprocessor... gcc -E
checking for grep that handles long lines and -e... /usr/bin/grep
checking for egrep... /usr/bin/grep -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking minix/config.h usability... no
checking minix/config.h presence... no
checking for minix/config.h... no
checking whether it is safe to define EXTENSIONS... yes
checking initial CFLAGS... -g -O2
checking which architecture the target is... unknown
checking which operating system the target is... unknown
checking which libc is detected for the target... unknown

�[1mChecking for programs:�[m
checking for g++... g++
checking whether we are using the GNU C++ compiler... yes
checking whether g++ accepts -g... yes
checking dependency style of g++... gcc3
checking for gawk... (cached) awk
checking for gcc... (cached) gcc
checking whether we are using the GNU C compiler... (cached) yes
checking whether gcc accepts -g... (cached) yes
checking for gcc option to accept ISO C89... (cached) none needed
checking whether gcc understands -c and -o together... (cached) yes
checking dependency style of gcc... (cached) gcc3
checking how to run the C preprocessor... gcc -E
checking whether ln -s works... yes
checking whether make sets $(MAKE)... (cached) yes
checking for C/C++ restrict keyword... __restrict
checking for working volatile... yes
checking for inline... inline
checking if compiling with clang... yes
checking for a supported OS... maybe (darwin15.0.0)
checking how to print strings... printf
checking for a sed that does not truncate output... /usr/bin/sed
checking for fgrep... /usr/bin/grep -F
checking for ld used by gcc... /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld
checking if the linker (/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld) is GNU ld... no
checking for BSD- or MS-compatible name lister (nm)... /usr/bin/nm
checking the name lister (/usr/bin/nm) interface... BSD nm
checking the maximum length of command line arguments... 196608
checking whether the shell understands some XSI constructs... yes
checking whether the shell understands "+="... yes
checking how to convert x86_64-apple-darwin15.0.0 file names to x86_64-apple-darwin15.0.0 format... func_convert_file_noop
checking how to convert x86_64-apple-darwin15.0.0 file names to toolchain format... func_convert_file_noop
checking for /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld option to reload object files... -r
checking for objdump... no
checking how to recognize dependent libraries... pass_all
checking for dlltool... no
checking how to associate runtime and link libraries... printf %s\n
checking for ar... ar
checking for archiver @file support... no
checking for strip... strip
checking for ranlib... ranlib
checking command to parse /usr/bin/nm output from gcc object... ok
checking for sysroot... no
checking for mt... no
checking if : is a manifest tool... no
checking for dsymutil... dsymutil
checking for nmedit... nmedit
checking for lipo... lipo
checking for otool... otool
checking for otool64... no
checking for -single_module linker flag... yes
checking for -exported_symbols_list linker flag... yes
checking for -force_load linker flag... yes
checking for dlfcn.h... yes
checking for objdir... .libs
checking if gcc supports -fno-rtti -fno-exceptions... yes
checking for gcc option to produce PIC... -fno-common -DPIC
checking if gcc PIC flag -fno-common -DPIC works... yes
checking if gcc static flag -static works... no
checking if gcc supports -c -o file.o... yes
checking if gcc supports -c -o file.o... (cached) yes
checking whether the gcc linker (/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld) supports shared libraries... yes
checking dynamic linker characteristics... darwin15.0.0 dyld
checking how to hardcode library paths into programs... immediate
checking for dlopen in -ldl... yes
checking whether a program can dlopen itself... yes
checking whether a statically linked program can dlopen itself... yes
checking whether stripping libraries is possible... yes
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... yes
checking whether to build static libraries... yes
checking how to run the C++ preprocessor... g++ -E
checking for ld used by g++... /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld
checking if the linker (/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld) is GNU ld... no
checking whether the g++ linker (/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld) supports shared libraries... yes
checking for g++ option to produce PIC... -fno-common -DPIC
checking if g++ PIC flag -fno-common -DPIC works... yes
checking if g++ static flag -static works... no
checking if g++ supports -c -o file.o... yes
checking if g++ supports -c -o file.o... (cached) yes
checking whether the g++ linker (/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld) supports shared libraries... yes
checking dynamic linker characteristics... darwin15.0.0 dyld
checking how to hardcode library paths into programs... immediate
checking for full c++ support and linking model... yes
checking for debugging... no
checking for target that allows unaligned reads and writes... yes

�[1mChecking for headers:�[m
checking for ANSI C header files... (cached) yes
checking whether time.h and sys/time.h may both be included... yes
checking whether sys/types.h defines makedev... yes
checking for dirent.h that defines DIR... yes
checking for library containing opendir... none required
checking for sys/wait.h that is POSIX.1 compatible... yes
checking for size_t... yes
checking for working alloca.h... yes
checking for alloca... yes
checking arpa/inet.h usability... yes
checking arpa/inet.h presence... yes
checking for arpa/inet.h... yes
checking fcntl.h usability... yes
checking fcntl.h presence... yes
checking for fcntl.h... yes
checking float.h usability... yes
checking float.h presence... yes
checking for float.h... yes
checking for inttypes.h... (cached) yes
checking libintl.h usability... no
checking libintl.h presence... no
checking for libintl.h... no
checking limits.h usability... yes
checking limits.h presence... yes
checking for limits.h... yes
checking malloc.h usability... no
checking malloc.h presence... no
checking for malloc.h... no
checking netdb.h usability... yes
checking netdb.h presence... yes
checking for netdb.h... yes
checking netinet/in.h usability... yes
checking netinet/in.h presence... yes
checking for netinet/in.h... yes
checking stddef.h usability... yes
checking stddef.h presence... yes
checking for stddef.h... yes
checking for stdint.h... (cached) yes
checking for stdlib.h... (cached) yes
checking for string.h... (cached) yes
checking sys/ioctl.h usability... yes
checking sys/ioctl.h presence... yes
checking for sys/ioctl.h... yes
checking sys/param.h usability... yes
checking sys/param.h presence... yes
checking for sys/param.h... yes
checking sys/socket.h usability... yes
checking sys/socket.h presence... yes
checking for sys/socket.h... yes
checking sys/time.h usability... yes
checking sys/time.h presence... yes
checking for sys/time.h... yes
checking sys/timeb.h usability... yes
checking sys/timeb.h presence... yes
checking for sys/timeb.h... yes
checking sys/resource.h usability... yes
checking sys/resource.h presence... yes
checking for sys/resource.h... yes
checking syslog.h usability... yes
checking syslog.h presence... yes
checking for syslog.h... yes
checking termios.h usability... yes
checking termios.h presence... yes
checking for termios.h... yes
checking for unistd.h... (cached) yes
checking wchar.h usability... yes
checking wchar.h presence... yes
checking for wchar.h... yes
checking assert.h usability... yes
checking assert.h presence... yes
checking for assert.h... yes
checking byteswap.h usability... no
checking byteswap.h presence... no
checking for byteswap.h... no
checking endian.h usability... no
checking endian.h presence... no
checking for endian.h... no
checking execinfo.h usability... yes
checking execinfo.h presence... yes
checking for execinfo.h... yes
checking ifaddrs.h usability... yes
checking ifaddrs.h presence... yes
checking for ifaddrs.h... yes
checking mcheck.h usability... no
checking mcheck.h presence... no
checking for mcheck.h... no
checking ndir.h usability... no
checking ndir.h presence... no
checking for ndir.h... no
checking dirent.h usability... yes
checking dirent.h presence... yes
checking for dirent.h... yes
checking for ndir.h... (cached) no
checking for string.h... (cached) yes
checking netpacket/packet.h usability... no
checking netpacket/packet.h presence... no
checking for netpacket/packet.h... no
checking sched.h usability... yes
checking sched.h presence... yes
checking for sched.h... yes
checking semaphore.h usability... yes
checking semaphore.h presence... yes
checking for semaphore.h... yes
checking sysexits.h usability... yes
checking sysexits.h presence... yes
checking for sysexits.h... yes
checking streambuf.h usability... no
checking streambuf.h presence... no
checking for streambuf.h... no
checking poll.h usability... yes
checking poll.h presence... yes
checking for poll.h... yes
checking net/if_arp.h usability... yes
checking net/if_arp.h presence... yes
checking for net/if_arp.h... yes
checking sys/dir.h usability... yes
checking sys/dir.h presence... yes
checking for sys/dir.h... yes
checking sys/ndir.h usability... no
checking sys/ndir.h presence... no
checking for sys/ndir.h... no
checking sys/inotify.h usability... no
checking sys/inotify.h presence... no
checking for sys/inotify.h... no
checking sys/sendfile.h usability... no
checking sys/sendfile.h presence... no
checking for sys/sendfile.h... no
checking sys/sched.h usability... no
checking sys/sched.h presence... no
checking for sys/sched.h... no
checking sys/syscall.h usability... yes
checking sys/syscall.h presence... yes
checking for sys/syscall.h... yes
checking linux/netfilter_ipv4/ipt_ACCOUNT.h usability... no
checking linux/netfilter_ipv4/ipt_ACCOUNT.h presence... no
checking for linux/netfilter_ipv4/ipt_ACCOUNT.h... no
checking libnetfilter_conntrack/libnetfilter_conntrack.h usability... no
checking libnetfilter_conntrack/libnetfilter_conntrack.h presence... no
checking for libnetfilter_conntrack/libnetfilter_conntrack.h... no
checking /usr/src/linux/include/generated/uapi/linux/version.h usability... no
checking /usr/src/linux/include/generated/uapi/linux/version.h presence... no
checking for /usr/src/linux/include/generated/uapi/linux/version.h... no
checking whether sys/inotify.h actually works... nope, using own inotify headers
checking for fopen in -lmsvcrt... no
checking for socketpair in -lc... yes
checking for getaddrinfo in -lc... yes
checking for gethostbyname2 in -lc... yes
checking for inet_ntop in -lc... yes
checking for socket in -lsocket... no
checking for lstat in -lc... yes
checking for strcoll in -lc... yes
checking for stricmp in -lc... no
checking for stristr in -lc... no
checking for sysconf in -lc... yes
checking for posix_memalign in -lc... yes
checking if you want to enable build of thread support... yes
checking if you want to always use GNU pth for threading... no
checking pthread.h usability... yes
checking pthread.h presence... yes
checking for pthread.h... yes
checking for pthread_create in -lpthread... yes
checking for pthread_suspend in -lpthread... no
checking for pthread_cancel in -lpthread... yes
checking for pthread_condattr_setclock in -lpthread... no
checking for pthread_setconcurrency in -lpthread... yes
checking for pthread_yield in -lpthread... no
checking for pthread_delay in -lpthread... no
checking for pthread_delay_np in -lpthread... no
checking for pthread_setschedprio in -lpthread... no
checking for pthread_attr_setinheritsched in -lpthread... yes
checking whether g++ supports -mt... no
checking whether g++ supports -pthread... yes
checking for numa_max_node in -lnuma... no

�[1mChecking for functions:�[m
checking for uid_t in sys/types.h... yes
checking for unistd.h... (cached) yes
checking for working chown... yes
checking for error_at_line... no
checking for pid_t... yes
checking vfork.h usability... no
checking vfork.h presence... no
checking for vfork.h... no
checking for fork... yes
checking for vfork... yes
checking for working fork... yes
checking for working vfork... (cached) yes
checking whether lstat correctly handles trailing slash... no
checking for sys/time.h... (cached) yes
checking for unistd.h... (cached) yes
checking for stdlib.h... (cached) yes
checking for sys/param.h... (cached) yes
checking for alarm... yes
checking for working mktime... no
checking for getpagesize... yes
checking for working mmap... yes
checking for working strnlen... yes
checking for working strtod... yes
checking whether closedir returns void... no
checking for accept4... no
checking for accept4 in -lposix4... no
checking for accept4 in -lrt... no
checking for accept4 in -lpthread... no
checking for atexit... yes
checking for daemon... yes
checking for dup3... no
checking for dup3 in -lposix4... no
checking for dup3 in -lrt... no
checking for dup3 in -lpthread... no
checking for epoll_create1... no
checking for epoll_create1 in -lposix4... no
checking for epoll_create1 in -lrt... no
checking for epoll_create1 in -lpthread... no
checking for epoll_wait... no
checking for epoll_wait in -lposix4... no
checking for epoll_wait in -lrt... no
checking for epoll_wait in -lpthread... no
checking for epoll_ctl_batch... no
checking for epoll_ctl_batch in -lposix4... no
checking for epoll_ctl_batch in -lrt... no
checking for epoll_ctl_batch in -lpthread... no
checking for fallocate... no
checking for fallocate in -lposix4... no
checking for fallocate in -lrt... no
checking for fallocate in -lpthread... no
checking for fallocate64... no
checking for fallocate64 in -lposix4... no
checking for fallocate64 in -lrt... no
checking for fallocate64 in -lpthread... no
checking for fnmatch... yes
checking for getaddrinfo... yes
checking for getnameinfo... yes
checking for getopt_long... yes
checking for getpriority... yes
checking for inet_ntop... yes
checking for memmem... yes
checking for memrchr... no
checking for memrchr in -lposix4... no
checking for memrchr in -lrt... no
checking for memrchr in -lpthread... no
checking for mkdtemp... yes
checking for mremap... no
checking for mremap in -lposix4... no
checking for mremap in -lrt... no
checking for mremap in -lpthread... no
checking for pipe2... no
checking for pipe2 in -lposix4... no
checking for pipe2 in -lrt... no
checking for pipe2 in -lpthread... no
checking for posix_spawn... yes
checking for pread... yes
checking for sched_getaffinity... no
checking for sched_getaffinity in -lposix4... no
checking for sched_getaffinity in -lrt... no
checking for sched_getaffinity in -lpthread... no
checking for sem_init... yes
checking for sem_getvalue... yes
checking for sendfile... yes
checking for sendfile64... no
checking for sendfile64 in -lposix4... no
checking for sendfile64 in -lrt... no
checking for sendfile64 in -lpthread... no
checking for strndup... yes
checking for strptime... yes
checking for strsignal... yes
checking for strtof... yes
checking for strtold... yes
checking for strtoull... yes
checking for gmtime_r... yes
checking for timegm... yes
checking for nanosleep... yes
checking for strerror... yes
checking for shm_open... yes

�[1mC++ stuff:�[m
checking netinet6/in6.h usability... no
checking netinet6/in6.h presence... no
checking for netinet6/in6.h... no
checking linux/in6.h usability... no
checking linux/in6.h presence... no
checking for linux/in6.h... no
checking for inet_pton in -lc... yes
checking for gethostbyname2 in -lc... yes
checking if you want to enable build of examples... yes
checking if you want to enable use of memory pool... yes
checking if you want to enable Large File Support... yes
checking if you want to enable use of coverage... no
checking for compile with GCC optimizations flags enabled... yes
checking if you want to enable mode final for build of ulib library... yes
checking for use of the new linker flags... yes
checking whether g++ supports -fvisibility-inlines-hidden... no
checking for C/C++ restrict keyword... (cached) __restrict
checking if you want to enable client response partial write support... no
checking if you want to enable server check time between request for parallelization... no
checking if you want to enable server captive portal mode... no
checking if you want to enable server thread approach support... no
checking if you want to enable HTTP inotify support... no
checking if you want to enable client and server log support... no
checking if you want to enable GDB stack dump support... no
checking if you want to enable cache request support... yes
checking if you want to enable homogeneous pipeline request support... yes
checking if you want to enable HTTP/2 support... no
checking if you want to enable server classic model support... no
checking if you want to enable server bandwidth throttling support... no
checking if you want to enable alias URI support... no
checking if you want to enable welcome message support... no
checking if you want to enable ACL filtering support... no
checking if you want to enable RFC1918 filtering support... no
checking if you want to enable HTTP Strict Transport Security support... no
checking if you want to enable HTML pagination support... no
checking if you want to enable use of bison/yacc... no
checking if you want to use distcc... no
checking whether g++ supports C++11 features by default... no
checking whether g++ supports C++11 features with -std=c++11... yes
checking whether std::chrono::steady_clock is available... yes
checking whether std::future is available... yes

�[1mChecking for libraries to link against:�[m
checking if LIBZ library is wanted... yes
Cannot find LIBZ library
checking if you want to enable build of ZIP support... no
checking if tdb library is wanted... yes
Cannot find libtdb library
checking if zopfli library is wanted... yes
Cannot find libzopfli library
checking if libuuid library is wanted... yes
Cannot find LIBUUID library
checking if MAGIC library is wanted... yes
Cannot find MAGIC library
checking if SSL library is wanted... yes
Cannot find SSL library
checking if PCRE library is wanted... yes
Cannot find PCRE library
checking if EXPAT library for XML parsing is wanted... yes
Cannot find EXPAT library
checking if c-ares library for DNS resolution is wanted... yes
Cannot find c-ares library
checking if SSH library is wanted... no
checking if cURL library is wanted... no
checking if LDAP library is wanted... no
checking if DBI library is wanted... no
checking if libevent library is wanted... no
checking if libxml2 library is wanted... no
checking if you want to use page-speed SDK... no
checking if you want to use V8 JavaScript Engine... no
checking for SQLite3 support... no
checking for MySQL support... no
checking for PostgreSQL support... no

�[1mChecking for libraries specific:�[m
checking for tcc_compile_string in -ltcc... no
checking for GeoIP_id_by_ipnum in -lGeoIP... no
checking for siginfo_t... yes
checking for siginfo_t.si_addr... yes
checking whether new ldflags are wanted... no
checking if you want to use php-embedded... no
checking if you want to use ruby-embedded... no
checking for stdbool.h that conforms to C99... no
checking for _Bool... no
checking for uid_t in sys/types.h... (cached) yes
checking for inline... (cached) inline
checking for int16_t... yes
checking for int32_t... yes
checking for int64_t... yes
checking for int8_t... yes
checking for mode_t... yes
checking for off_t... yes
checking for pid_t... (cached) yes
checking for C/C++ restrict keyword... (cached) __restrict
checking for size_t... (cached) yes
checking for ssize_t... yes
checking for struct stat.st_blksize... yes
checking for struct stat.st_blocks... yes
checking for struct stat.st_rdev... yes
checking for uint16_t... yes
checking for uint32_t... yes
checking for uint64_t... yes
checking for uint8_t... yes
checking for ptrdiff_t... yes

�[1mChecking for structures:�[m
checking whether struct tm is in sys/time.h or time.h... time.h
checking whether stat file-mode macros are broken... no
checking for struct stat.st_blocks... (cached) yes
checking for struct iphdr... no
checking for struct dirent.d_reclen... yes
checking for struct dirent.d_namlen... yes
checking for struct tm.tm_gmtoff... yes

�[1mChecking for types:�[m
checking for an ANSI C-conforming const... yes
checking for size_t... (cached) yes
checking for ptrdiff_t... (cached) yes
checking size of unsigned char... 1
checking size of short... 2
checking size of int... 4
checking size of long... 8
checking size of time_t... 8
checking size of size_t... 8
checking size of long long... 8
checking size of __int64... 0
checking size of void *... 8
checking size of ptrdiff_t... 8
checking for cpu_set_t... no
checking for working socket option SO_RCVTIMEO... no

�[1mChecking for server plugin:�[m
checking server plugin "rpc"... dynamic
checking server plugin "stream"... dynamic
checking server plugin "nocat"... dynamic
checking server plugin "socket"... dynamic
checking server plugin "scgi"... dynamic
checking server plugin "fcgi"... dynamic
checking server plugin "ssi"... dynamic
checking server plugin "tsa"... dynamic
checking server plugin "http"... dynamic
checking server plugin "echo"... dynamic
checking loader.autoconf files... done

�[1mChecking for ORM driver:�[m
checking loader.autoconf files... done
checking for cpp... /usr/bin/cpp
checking for mcpp... no
checking for atomic... yes
checking for doxygen... no
checking for dlopen in -lc... yes
checking strstream.h usability... no
checking strstream.h presence... no
checking for strstream.h... no
checking determine if the kind of C++ iostream support is old... no

�[1mOutput Substitution:�[m

configure: Configured to build src/ulib/libulib:

      ULib version: 1.4.2
        Build ULib: Shared=yes, Static=yes

        Host setup: x86_64-apple-darwin15.0.0
    Install prefix: /usr/local
    Install plugin: /usr/local/libexec
Configuration data: /usr/local/etc

  Operating System: Darwin Mac.local 15.0.0 Darwin Kernel Version 15.0.0: Wed Aug 26 16:57:32 PDT 2015; root:xnu-3247.1.106~1/RELEASE_X86_64 x86_64
      C++ Compiler: g++ (  )
            Linker: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld ( unknown )

Standard C library: unknown
Standard C++ library: unknown
Libraries: -lpthread -lc

         C   Flags: -g -O2
         C++ Flags: -g -O2 -std=c++11 -fno-exceptions -fno-rtti
      Linker Flags: 
Preprocessor Flags:  -D__OSX__ -D__APPLE__ -pthread -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64

     debug support: no (--enable-debug)
  final build mode: enabled

memory pool support: enabled
LFS support: enabled
ipv6 support: no (--with-ipv6)
zip support: no (--enable-zip)
thread support: enabled

      LIBZ support: no (--with-libz)
 LIBZOPFLI support: no (--with-libzopfli)
    LIBTDB support: no (--with-libtdb)
      PCRE support: no (--with-pcre)
       SSL support: no (--with-ssl)
       SSH support: no (--with-ssh)
      LDAP support: no (--with-ldap)
      cURL support: no (--with-curl)
       XML support: no (--with-expat)
     MAGIC support: no (--with-magic)
    SQLite support: no (--with-sqlite)
     MySQL support: no (--with-mysql)
     PgSQL support: no (--with-pgsql)
       DBI support: no (--with-libdbi)
   libuuid support: no (--with-libuuid)
  libevent support: no (--with-libevent)
   libxml2 support: no (--with-libxml2)
    c-ares support: no (--enable-libares)
Page-Speed support: no (--with-page-speed)

V8 JavaScript support: no (--with-v8-javascript)
PHP language support: no (--with-php-embedded)
RUBY language support: no (--with-ruby-embedded)

  Examples:         enabled
  LEX/YACC support: no (--with-parser)
  Lexical analyzer:  ( None )
  Parser generator:  ( None )

See include/ulib/internal/config.h for further configuration information

checking that generated files are newer than configure... done
configure: creating ./config.status
config.status: creating Makefile
config.status: creating rpm.sh
config.status: creating ULib.spec
config.status: creating m4/Makefile
config.status: creating doc/Makefile
config.status: creating include/Makefile
config.status: creating contrib/Makefile
config.status: creating src/ulib/Makefile
config.status: creating src/ulib/ULib.rc
config.status: creating src/ulib/ULib.pc
config.status: creating src/ulib/orm/driver/Makefile
config.status: creating src/ulib/net/server/plugin/Makefile
config.status: creating src/ulib/net/server/plugin/v8/Makefile
config.status: creating src/ulib/net/server/plugin/php/Makefile
config.status: creating src/ulib/net/server/plugin/ruby/Makefile
config.status: creating src/ulib/net/server/plugin/usp/Makefile
config.status: creating src/ulib/net/server/plugin/mod_shib/Makefile
config.status: creating src/ulib/net/server/plugin/mod_geoip/Makefile
config.status: creating src/ulib/net/server/plugin/usp/usp_compile.sh
config.status: creating src/ulib/net/server/plugin/page_speed/Makefile
config.status: creating include/ulib/Makefile
config.status: creating contrib/HCSP/Makefile
config.status: creating contrib/RSIGN/Makefile
config.status: creating contrib/signer/Makefile
config.status: creating examples/Makefile
config.status: creating examples/IR/Makefile
config.status: creating examples/csp/Makefile
config.status: creating examples/lcsp/Makefile
config.status: creating examples/rsign/Makefile
config.status: creating examples/hello/Makefile
config.status: creating examples/WiAuth/Makefile
config.status: creating examples/xml2txt/Makefile
config.status: creating examples/uclient/Makefile
config.status: creating examples/userver/Makefile
config.status: creating examples/PEC_log/Makefile
config.status: creating examples/workflow/Makefile
config.status: creating examples/doc_parse/Makefile
config.status: creating examples/lrp_session/Makefile
config.status: creating examples/http_header/Makefile
config.status: creating examples/test_manager/Makefile
config.status: creating examples/doc_classifier/Makefile
config.status: creating examples/form_completion/Makefile
config.status: creating examples/simple_client_server/Makefile
config.status: creating examples/download_accelerator/Makefile
config.status: creating examples/XAdES/Makefile
config.status: creating examples/XAdES/XAdES.spec
config.status: creating examples/xml2txt/xml2txt.spec
config.status: creating examples/IR/searchengine-bin.spec
config.status: creating examples/lcsp/lcsp.spec
config.status: creating examples/lcsp/lcsp_rpc.spec
config.status: creating examples/csp/cspclient.spec
config.status: creating examples/csp/cspclient_rpc.spec
config.status: creating examples/rsign/rsignclient.spec
config.status: creating examples/rsign/rsignclient_rpc.spec
config.status: creating examples/userver/web_server.spec
config.status: creating examples/userver/wagsmserver.spec
config.status: creating examples/workflow/workflow.spec
config.status: creating examples/PEC_log/PEC_log.spec
config.status: creating examples/userver/tsaserver.spec
config.status: creating examples/userver/cspserver.spec
config.status: creating examples/userver/rsignserver.spec
config.status: creating examples/doc_parse/doc_parse.spec
config.status: creating tests/Makefile
config.status: creating tests/base/Makefile
config.status: creating tests/debug/Makefile
config.status: creating tests/ulib/Makefile
config.status: creating tests/examples/Makefile
config.status: creating tests/contrib/Makefile
config.status: creating include/ulib/internal/config.h
config.status: executing depfiles commands
config.status: executing libtool commands


checking if generated configuration is usable... no

x

can't delete issues!

Possible to do a reverse proxy demo?

Hope can be used as a reverse proxy. That'll be really interesting. Do you have any intention of making a demo example for the reverse proxy setup? Don't mind waiting.

How to compile on MacOS 10.14?

I get the following error during configure:

/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/sys/socket.h:717:32: error: expected ','
__API_AVAILABLE(macosx(10.11), ios(9.0), tvos(9.0), watchos(2.0))
                               ^
./include/ulib/internal/common.h:36:28: note: expanded from macro 'ios'
#     define ios        std::ios
                           ^

What could I do to help you support 10.14?

Any chance of a tutorial ?

Hello !

The code only documentation does not give a clear way on how to use this library, any chance to have a tutorial or a sample application that works straight away ?

I could not get anything to work due to missing configuration, it doesn't seem to have default configuration.

I installed to a custom location $HOME/local/ulib .

Cheers !

rest api

is there a way to build rest api?

HTTP/2 Option Compilation Error

when I tried 'sudo make install' after './configure --enable-debug --enable-http2', there was the following error....

Making install in src/ulib
CC all_c.lo
CXX all_cpp.lo
In file included from all_cpp.cpp:101:
./utility/http2.cpp:981:52: error: member access into incomplete type
'USSLSocket'
U_ASSERT(((USSLSocket_)UServer_Base::csocket)->isSSL())
^
../../include/ulib/net/ipaddress.h:52:7: note: forward declaration of
'USSLSocket'
class USSLSocket;
^
1 error generated.
make[1]: *_* [all_cpp.lo] Error 1
make: *** [install-recursive] Error 1

Documentation for ULib server pages

Can you please include more documentation for ULIb server pages? I have a repository called Kunjika and another called Memoir. Both are QA system like Stackoverflow. I would like to re-implement it with ULib but I find lack of documentation a big problem.

make error in ubuntu 16.04

I get the following error when i run 'make' in Ubuntu 16.04. Any idea how to fix this?
make[1]: Entering directory '/home/ash/ULib-master/include'
Making check in ulib
make[2]: Entering directory '/home/ash/ULib-master/include/ulib'
make[2]: Nothing to be done for 'check'.
make[2]: Leaving directory '/home/ash/ULib-master/include/ulib'
make[2]: Entering directory '/home/ash/ULib-master/include'
make[2]: Nothing to be done for 'check-am'.
make[2]: Leaving directory '/home/ash/ULib-master/include'
make[1]: Leaving directory '/home/ash/ULib-master/include'
Making check in src/ulib
make[1]: Entering directory '/home/ash/ULib-master/src/ulib'
make[1]: Nothing to be done for 'check'.
make[1]: Leaving directory '/home/ash/ULib-master/src/ulib'
Making check in src/ulib/net/server/plugin
make[1]: Entering directory '/home/ash/ULib-master/src/ulib/net/server/plugin'
Making check in usp
make[2]: Entering directory '/home/ash/ULib-master/src/ulib/net/server/plugin/usp'
CXXLD usp_translator
/usr/bin/ld: .libs/usp_translator: hidden symbol `__cpu_indicator_init' in /usr/lib/gcc/x86_64-linux-gnu/5/libgcc.a(cpuinfo.o) is referenced by DSO
/usr/bin/ld: final link failed: Bad value
collect2: error: ld returned 1 exit status
Makefile:474: recipe for target 'usp_translator' failed
make[2]: *** [usp_translator] Error 1
make[2]: Leaving directory '/home/ash/ULib-master/src/ulib/net/server/plugin/usp'
Makefile:842: recipe for target 'check-recursive' failed
make[1]: *** [check-recursive] Error 1
make[1]: Leaving directory '/home/ash/ULib-master/src/ulib/net/server/plugin'
Makefile:545: recipe for target 'check-recursive' failed
make: *** [check-recursive] Error 1

UString::strtod() erronious conversion (USP) ?

consider the following docalc.usp http://127.0.0.1/docalc?arg1=1&arg2=2

<!--#args
arg1;
arg2;
-->
<!--#code

double val1   =  std::stod(arg1.data());
double check1 =  arg1.strtod();
double val2   =  std::stod(arg2.data());
double check2 =  arg2.strtod(); 
double result = 0.0;

result = val1 + val2;  
USP_PRINTF("<hr>\n%g + %g = %g", val1, val2, result);

result = check1 + check2;
USP_PRINTF("<hr>\n%g + %g = %g", check1, check2, result);
-->

ouput
1.0 + 2.0 = 3.0
0 + 0 = 0
log.zip

usp_libtool.sh not found

shiv@shiv:~/Downloads/ULib/src/ulib/net/server/plugin/usp$ sudo bash usp_compile.sh session.usp
usp_compile.sh: line 63: /usr/local/bin/usp_libtool.sh: No such file or directory
mv: cannot stat '.libs/session.usp': No such file or directory
mv: cannot stat '.libs/session.so': No such file or directory

First problem is that usp_compile.sh, usp_translator are not copied to INSTALL_PREFIX which is /usr/local/ in my case. Second minor issue is that +x is not set for usp_compile.sh.

cookie.usp error

for running cookie.usp i'm getting these errors.


| ***** **** **** *** **** |
| * * * * * * * * * |
| ***** **** **** * * **** |
| * * * * * * * * * |
| ***** * * * * *** * * |

userver_tcp: NOT EQUALS

pid: 32019
file: utility/services.cpp
line: 808
function: static bool UServices::getTokenData(UString&, const UString&, time_t&)
assertion: "((token.size())==(data.size() + (1U + 10U + 1U + 16U)))"

strings.usp error with two browsers

I was trying to test the session state of strings.usp witih two browsers. when I reload the next browser, it crashes with errors below. One browser works fine, two browsers crashed. The browsers used are Chromium and Firefox.

I'm also trying to figure out how to pass C++ variables as output.


| ***** **** **** *** **** |
| * * * * * * * * * |
| ***** **** **** * * **** |
| * * * * * * * * * |
| ***** * * * * *** * * |

userver_tcp: ASSERTION FALSE

pid: 20693
file: container/vector.cpp
line: 1016
function: std::istream& operator>>(std::istream&, UVector&)
assertion: "(is.peek() == '[' || is.peek() == '(')"

userver_tcp: Press 'c' to continue, 'Enter' to exit:

Userver Http/2 ?

Hi, I am trying to run and test userver with http/2
I've run configure --enable-debug --enable-http2 but I am lost there.
Is there any guide somewhere to do this?

make clean break make install

after "make clean" you cannot "make install"

/usr/bin/install: cannot stat ‘./src/ulib/net/server/plugin/usp/usp_compile.sh’: No such file or directory

Compilation Error on Mac

When installing the framework, getting this output...

ld: unknown option: -R/usr/local/lib
clang: error: linker command failed with exit code 1 (use -v to see invocation)

... when trying to 'make' after './configure'-(ing)

I understand that it is a compiler issue, but at a loss for how to remedy this! I would greatly appreciate some direction :)

the www.unirel.com can not access

Hello Author, I have seen the ulib's performance in web library at a benchmark website. When I want to access your official site "www.unirel.com", the page can not be opened.

It is not be blocked by the China's GFW, and I don't know what is the matter...

No sample config for simple_client_server

simple_client_server # ./server
server: ERROR: 10/06/15 15:07:57 (pid 22751) argument 'file_config' not specified - Exiting...
no config provided and I can't understand what config format required
Those both are not valid
config.ini
ENABLE_IPV6 0
MSG_WELCOME welcome
SERVER_ADDRESS 127.0.0.1

ENABLE_IPV6=0
MSG_WELCOME=welcome
SERVER_ADDRESS=127.0.0.1

./server config.ini
server: ERROR: 10/06/15 15:11:21 (pid 22772) config file 'config.ini' not valid - Exiting...

Do not compile on OS X

Hello !

I was trying to test ULIB on OS X and after a half success with "configure" I've got this error:

In file included from all_c.c:77:
In file included from ./replace/sendfile.c:7:
/usr/include/sys/socket.h:585:5: error: conflicting types for 'sendfile'
int     sendfile(int, int, off_t, off_t *, struct sf_hdtr *, int);
        ^
../../include/ulib/base/replace/replace.h:31:9: note: previous declaration is
      here
ssize_t sendfile(int out_fd, int in_fd, off_t* poffset, size_t count);
        ^
79 warnings and 1 error generated.
make[1]: *** [all_c.lo] Error 1
make: *** [all-recursive] Error 1

Pre-compiled builds

Hello Sir,

Is it possible for you to release pre-compiled binaries for linux as well as windows?

Thank you.

I like this project BUT it's the only one that I can't install properly.

Using Ubuntu 16.04 within a docker container.

Can you please help provide instructions on the "apt-get install" for it to work with a lot of the features?

It can run but segfaults on a few configure options. Would like to know what to run to get it all up.

Please make the documentation a bit better in regards to what I'm asking for and the rest should be easy to figure out. Thanks.

ULib namespaces

I've been using this "great" library for some time now.
I'm still wondering why there is no namespace for this library.
Something like:
ULib::UString, ULib::Net::USocket etc will be great!

Options:
namespace ULib { }
namespace ulib {}

License issue with included files

I notice that you have moved to LGPL, which is a good news for me but I notice that you have included sources which are having GPLv2 and GPLv3 licenses. Are you planning to remove those to cleanup the license conflict?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.