Giter VIP home page Giter VIP logo

musl-fts's People

Contributors

joncfoo avatar pullmoll 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

Watchers

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

musl-fts's Issues

'pkgconfig_DATA' is used but 'pkgconfigdir' is undefined

Trying to build this, getting the error mentioned. Any ideas?

root@~/build/musl-fts > ./bootstrap.sh 
libtoolize: putting auxiliary files in '.'.
libtoolize: linking file './ltmain.sh'
libtoolize: putting macros in AC_CONFIG_MACRO_DIRS, 'm4'.
libtoolize: linking file 'm4/libtool.m4'
libtoolize: linking file 'm4/ltoptions.m4'
libtoolize: linking file 'm4/ltsugar.m4'
libtoolize: linking file 'm4/ltversion.m4'
libtoolize: linking file 'm4/lt~obsolete.m4'
configure.ac:9: installing './compile'
configure.ac:10: installing './config.guess'
configure.ac:10: installing './config.sub'
configure.ac:5: installing './install-sh'
configure.ac:5: installing './missing'
Makefile.am: installing './INSTALL'
Makefile.am: installing './depcomp'
Makefile.am:8: error: 'pkgconfig_DATA' is used but 'pkgconfigdir' is undefined

fts_read and fts_children do not return any file or directory

Hello, I am developing a server program for Alpine Linux, and I want to traverse file hierarchies, so I look up functions to do just that, and I find nftw which apparently sucks (stupid callback) so I saw the fts family of functions from BSD. Turns out musl does not support it but this package should, so I write a function using fts and it doesn't work at all and I don't know why.

Here is the relevant function I wrote. The output is just . Am I doing something wrong or is this fts implementation broken on Alpine Linux?
I rewrote it in nftw and that works, but I don't like nftw's design and that it requires global variables.

/*
 * Free after use with xmlFree
 */
xmlChar *
generate_tracks_xml_fts(void)
{
	xmlNodePtr root_node;
	xmlChar *xmlbuf;
	FTS *fts;
	FTSENT *parent;
	FTSENT *child;

	doc = xmlNewDoc(BAD_CAST "1.0");
	root_node = xmlNewNode(NULL, BAD_CAST "releases");
	xmlDocSetRootElement(doc, root_node);

	char *path_argv[] = { (char*) MUSIC_PATH, NULL };
	fts = fts_open(path_argv, FTS_NOCHDIR | FTS_XDEV, NULL);
	if (fts == NULL) {
		if (errno != ENOENT) {
			fprintf(stderr, "Failed to fts_open %s", MUSIC_PATH);
		}
		return 0;
	}

	while ((parent = fts_read(fts)) != NULL) {
		child = fts_children(fts, 0);

		if (errno != 0) {
			perror("fts_children");
		}

		while ((child != NULL)
			&& (child->fts_link != NULL)) {
			child = child->fts_link;
			switch (child->fts_info) {
				case FTS_F:
					xmlNewTextChild(root_node, NULL, BAD_CAST "track", BAD_CAST child->fts_name);
					puts(child->fts_name);
					break;
			}
		}
	}
	fts_close(fts);

	xmlDocDumpFormatMemory(doc, &xmlbuf, NULL, 1);
	return xmlbuf;
}

Any updates on this as well?

Hey there,

Are there any chances that you're going to keep this on par with the latest fts implementation from NetBSD?

Thank you for your time and effort.

Detached signature for release source code tarballs

Thanks for developing this useful library. Would it be possible to include a detached signature to authenticate the release tarballs?

While simply signing git release tags or even commits would be a step in the right direction, signing the actual released artifacts would be a huge help to users concerned about code authenticity.

It's not foolproof, but if the public key is published to a keyserver like https://keyserver.ubuntu.com/ in addition to someplace independent (like a developers website or maybe even somewhere here on github), then it can be used to provide a greater degree of confidence.

It looks like it should be a pretty straightforward process and would be much appreciated.

clamav 0.99.2 build

I'm trying to build a clamav 0.99.2 for LEDE (OpenWrt fork), made the package to depend on musl-fts which is built properly but I have the following error

onaccess_hash.o: In function `onas_ht_add_hierarchy':
onaccess_hash.c:(.text+0x855): undefined reference to `fts_open'
onaccess_hash.c:(.text+0x886): undefined reference to `fts_read'
onaccess_hash.c:(.text+0x946): undefined reference to `fts_children'
onaccess_hash.c:(.text+0x9af): undefined reference to `fts_close'
onaccess_scth.o: In function `onas_scan_th':
onaccess_scth.c:(.text+0x112): undefined reference to `fts_open'
onaccess_scth.c:(.text+0x122): undefined reference to `fts_read'
collect2: error: ld returned 1 exit status

do you know what I could be missing ?

regards

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.