skarnet / skalibs Goto Github PK
View Code? Open in Web Editor NEWThe skarnet.org C system programming library
Home Page: https://skarnet.org/software/skalibs/
License: ISC License
The skarnet.org C system programming library
Home Page: https://skarnet.org/software/skalibs/
License: ISC License
skalibs - a general-purpose low-level C library ----------------------------------------------- skalibs is a C library used by all the skarnet.org packages. It provides APIs more suited to secure and efficient system programming than the libc, especially where network programming and IPCs are concerned. See the enclosed doc/ subdirectory for the documentation, or https://skarnet.org/software/skalibs/ * Installation ------------ See the INSTALL file. * Contact information ------------------- Laurent Bercot <ska-skaware at skarnet.org> Please use the <skaware at list.skarnet.org> mailing-list for questions about skalibs.
for tag 2.12.0.1 the info file contains version number 2.12.1.0
with --enable-slashpackage will install to wrong directory
Steps to reproduce:
Getting error message "Makefile:12: *** Missing config.mak; please use ./configure first. Stop.".
Steps to troubleshoot: ran ./configure, then make (not as one conjoined command with "&&"). Still ran into same issue.
Please let me know what additional info I can provide.
Full output message:
Checking for C compiler... ... gcc Checking whether C compiler works... ... yes Checking target system type... ... x86_64-redhat-linux Checking whether compiler accepts -fPIC ... ... yes Checking whether compiler accepts -std=c99 ... ... yes Checking whether compiler accepts -fomit-frame-pointer ... ... yes Checking whether compiler accepts -fno-exceptions ... ... yes Checking whether compiler accepts -fno-unwind-tables ... ... yes Checking whether compiler accepts -fno-asynchronous-unwind-tables ... ... yes Checking whether compiler accepts -Werror=implicit-function-declaration ... ... yes Checking whether compiler accepts -Werror=implicit-int ... ... yes Checking whether compiler accepts -Werror=pointer-sign ... ... yes Checking whether compiler accepts -Werror=pointer-arith ... ... yes Checking whether compiler accepts -Wno-unused-value ... ... yes Checking whether compiler accepts -Wno-parentheses ... ... yes Checking whether compiler accepts -ffunction-sections ... ... yes Checking whether compiler accepts -fdata-sections ... ... yes Checking whether linker accepts -nostartfiles ... ... yes Checking whether linker accepts -Wl,--as-needed ... ... yes Checking whether linker accepts -Wl,--sort-section=alignment ... ... yes Checking whether linker accepts -Wl,--sort-common ... ... yes Checking whether linker accepts -Wl,--hash-style=both ... ... yes Checking required linker flags for socket functions... ... none Checking whether system has clock_gettime()... ... yes Checking whether system has CLOCK_MONOTONIC... ... yes Checking whether system has CLOCK_BOOTTIME... ... yes Checking whether system has posix_spawn()... ... yes Checking whether system has timer_create()... ... yes, with linker args: -lrt Checking endianness... ... little Checking size and signedness of standard types... ... done Checking whether system has accept4()... ... yes Checking whether system has MSG_CMSG_CLOEXEC... ... yes Checking whether system has dirfd()... ... yes Checking whether system has eventfd()... ... yes Checking whether system has flock()... ... yes Checking whether system has getpeereid()... ... no Checking whether system has SO_PEERCRED... ... yes Checking whether system has getpeerucred()... ... no Checking whether system has IPv6 support... ... yes Checking whether system has MSG_DONTWAIT... ... yes Checking whether system has O_DIRECTORY... ... yes Checking whether system has openat()... ... yes Checking whether system has linkat()... ... yes Checking whether system has memmem()... ... yes Checking whether system has pipe2()... ... yes Checking whether system has ppoll()... ... yes Checking whether system has revoke()... ... no Checking whether system has sendfile()... ... yes Checking whether system has setgroups()... ... yes Checking whether system has settimeofday()... ... yes Checking whether system has signalfd()... ... yes Checking whether system has splice()... ... yes Checking whether system has strcasestr()... ... yes Checking whether system has strnlen()... ... yes Checking whether system has uint64_t... ... yes Checking whether system has futimens()... ... yes Checking whether system has futimes()... ... yes Checking whether system has arc4random()... ... no Checking whether system has arc4random_addrandom()... ... no Checking whether system has setitimer()... ... yes Checking whether system has namespaces... ... yes Checking whether system has NS_GET_PARENT... ... yes Checking whether system has explicit_bzero()... ... yes Checking whether system has getrandom()... ... yes Checking whether system has GRND_INSECURE... ... no Checking whether system has chroot()... ... yes Checking whether system has /dev/urandom... ... yes Checking whether system has posix_spawn() returning early... ... no Creating config.mak... ... done. Creating src/include/skalibs/config.h... ... done. Makefile:12: *** Missing config.mak; please use ./configure first. Stop.
sa->len + n
might wrap arround ( in case of user controlled n
). leaving the "buffer" in a state where len
points past sa->s + sa->a
because in stralloc_ready_tuned
the condition sa->len < n
is not verified/checked. or am i dreaming?
skalibs/src/include/skalibs/stralloc.h
Line 22 in 8c16e68
I try to cross build skalibs (2.12.0.1) on Alpine 3.17 against s390x arch and got the following error:
$ DESTDIR=/out ./configure '--host=s390x-alpine-linux-musl' --enable-slashpackage --enable-static-libc --disable-shared '--with-default-path=/command:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin' '--with-sysdep-devurandom=yes'
...
...
#30 18.75 exec s390x-alpine-linux-musl-clang -D_POSIX_C_SOURCE=200809L -D_XOPEN_SOURCE=700 -Isrc/include -fPIC -Werror=implicit-function-declaration -Werror=implicit-int -Werror=pointer-sign -Werror=pointer-arith -Wno-unused-value -Wno-parentheses -pipe -Wall -std=c99 -fno-exceptions -fno-unwind-tables -fno-asynchronous-unwind-tables -ffunction-sections -fdata-sections -O2 -fomit-frame-pointer -c -o src/libstddjb/uint16_pack.lo src/libstddjb/uint16_pack.c
#30 18.77 src/libstddjb/uint16_pack.c:10:18: error: incompatible integer to pointer conversion passing 'uint16_t' (aka 'unsigned short') to parameter of type 'uint16_t *' (aka 'unsigned short *'); take the address with & [-Wint-conversion]
#30 18.77 uint16_littlep(u) ;
#30 18.77 ^
#30 18.77 &
#30 18.77 src/include/skalibs/uint16.h:12:41: note: expanded from macro 'uint16_littlep'
#30 18.77 #define uint16_littlep(u) uint16_bswapp(u)
#30 18.77 ^
#30 18.77 src/include/skalibs/uint16.h:22:38: note: passing argument to parameter here
#30 18.77 extern void uint16_bswapp (uint16_t *) ;
#30 18.77 ^
#30 18.77 1 error generated.
#30 18.77 make: *** [Makefile:123: src/libstddjb/uint16_pack.lo] Error 1
Only happens for s390x
, other archs work just fine. Cannot repro on Alpine 3.16.
Steps to reproduce:
Spun up EC2 on AWS (OS = Amazon Linux, AMI = amzn2-ami-hvm-2.0.20230628.0-x86_64-gp2, size = t2.micro)
SSH to machine
Install git (sudo yum install git)
Install C compiler (sudo yum install gcc)
Clone git repo (git clone git://git.skarnet.org/skalibs)
Change directory into /skalibs (cd skalibs)
Run install instructions (./configure && make && sudo make install)
Getting error message "Makefile:12: *** Missing config.mak; please use ./configure first. Stop.".
Steps to troubleshoot: ran ./configure, then make (not as one conjoined command with "&&"). Still ran into same issue.
Please let me know what additional info I can provide.
Full output message:
Checking for C compiler... ... gcc Checking whether C compiler works... ... yes Checking target system type... ... x86_64-redhat-linux Checking whether compiler accepts -fPIC ... ... yes Checking whether compiler accepts -std=c99 ... ... yes Checking whether compiler accepts -fomit-frame-pointer ... ... yes Checking whether compiler accepts -fno-exceptions ... ... yes Checking whether compiler accepts -fno-unwind-tables ... ... yes Checking whether compiler accepts -fno-asynchronous-unwind-tables ... ... yes Checking whether compiler accepts -Werror=implicit-function-declaration ... ... yes Checking whether compiler accepts -Werror=implicit-int ... ... yes Checking whether compiler accepts -Werror=pointer-sign ... ... yes Checking whether compiler accepts -Werror=pointer-arith ... ... yes Checking whether compiler accepts -Wno-unused-value ... ... yes Checking whether compiler accepts -Wno-parentheses ... ... yes Checking whether compiler accepts -ffunction-sections ... ... yes Checking whether compiler accepts -fdata-sections ... ... yes Checking whether linker accepts -nostartfiles ... ... yes Checking whether linker accepts -Wl,--as-needed ... ... yes Checking whether linker accepts -Wl,--sort-section=alignment ... ... yes Checking whether linker accepts -Wl,--sort-common ... ... yes Checking whether linker accepts -Wl,--hash-style=both ... ... yes Checking required linker flags for socket functions... ... none Checking whether system has clock_gettime()... ... yes Checking whether system has CLOCK_MONOTONIC... ... yes Checking whether system has CLOCK_BOOTTIME... ... yes Checking whether system has posix_spawn()... ... yes Checking whether system has timer_create()... ... yes, with linker args: -lrt Checking endianness... ... little Checking size and signedness of standard types... ... done Checking whether system has accept4()... ... yes Checking whether system has MSG_CMSG_CLOEXEC... ... yes Checking whether system has dirfd()... ... yes Checking whether system has eventfd()... ... yes Checking whether system has flock()... ... yes Checking whether system has getpeereid()... ... no Checking whether system has SO_PEERCRED... ... yes Checking whether system has getpeerucred()... ... no Checking whether system has IPv6 support... ... yes Checking whether system has MSG_DONTWAIT... ... yes Checking whether system has O_DIRECTORY... ... yes Checking whether system has openat()... ... yes Checking whether system has linkat()... ... yes Checking whether system has memmem()... ... yes Checking whether system has pipe2()... ... yes Checking whether system has ppoll()... ... yes Checking whether system has revoke()... ... no Checking whether system has sendfile()... ... yes Checking whether system has setgroups()... ... yes Checking whether system has settimeofday()... ... yes Checking whether system has signalfd()... ... yes Checking whether system has splice()... ... yes Checking whether system has strcasestr()... ... yes Checking whether system has strnlen()... ... yes Checking whether system has uint64_t... ... yes Checking whether system has futimens()... ... yes Checking whether system has futimes()... ... yes Checking whether system has arc4random()... ... no Checking whether system has arc4random_addrandom()... ... no Checking whether system has setitimer()... ... yes Checking whether system has namespaces... ... yes Checking whether system has NS_GET_PARENT... ... yes Checking whether system has explicit_bzero()... ... yes Checking whether system has getrandom()... ... yes Checking whether system has GRND_INSECURE... ... no Checking whether system has chroot()... ... yes Checking whether system has /dev/urandom... ... yes Checking whether system has posix_spawn() returning early... ... no Creating config.mak... ... done. Creating src/include/skalibs/config.h... ... done. Makefile:12: *** Missing config.mak; please use ./configure first. Stop.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.