]> Dogcows Code - chaz/yoink/blobdiff - configure
pkg-config libs parsing bugfix
[chaz/yoink] / configure
index 5ba38b90f5651064230d9d16d32a6cb9ddc68991..49127e4614b5d124be37ae374446a91d87a1c88f 100755 (executable)
--- a/configure
+++ b/configure
@@ -6,9 +6,8 @@
 --
 
 project                = "Yoink"
-package                = project:lower()
 version                = "0.1"
-bugreport      = "chaz@dogcows.com"
+bugreport      = "onefriedrice@brokenzipper.com"
 
 
 function ShowHelp()
@@ -187,6 +186,9 @@ do
 
        -- Define the dependent values.
        
+       package = project:lower()
+       tarname = package.."-"..version
+
        if not host then host = ReadCommand("tools/config.guess") end
        alt_host = ReadCommand("tools/config.sub "..host)
 
@@ -414,12 +416,12 @@ do
        CFLAGS = CFLAGS.." "..pc_cflags
        CXXFLAGS = CXXFLAGS.." "..pc_cflags
 
-       local pc_libs = ReadCommand(command.." --libs "..deps)
+       local pc_libs = " "..ReadCommand(command.." --libs "..deps)
        if not pc_libs then Die("Couldn't determine LDFLAGS or LIBS.") end
-       for lib in pc_libs:gmatch("%-l%S+") do
+       for lib in pc_libs:gmatch("%s%-l%S+") do
                LIBS = LIBS.." "..lib
        end
-       for ldflag in pc_libs:gmatch("%-[^l]%S*") do
+       for ldflag in pc_libs:gmatch("%s%-[^l]%S*") do
                LDFLAGS = LDFLAGS.." "..ldflag
        end
 
@@ -456,7 +458,7 @@ end
 
 do
        -- Determine and define the git revision.
-       local head = ReadCommand("git log -n1 --date=short --pretty=format:\"%h (%ad)\"")
+       local head = ReadCommand("git describe master")
        config.YOINK_GITHEAD = head
 end
 
@@ -467,6 +469,8 @@ config.PACKAGE_VERSION              = version
 config.PACKAGE_STRING          = project.." "..version
 config.PACKAGE_BUGREPORT       = bugreport
 
+define.PACKAGE                         = project
+define.TARNAME                         = tarname
 define.TARGET                          = host
 define.PLATFORM                                = platform
 define.CC                                      = CC
This page took 0.018752 seconds and 4 git commands to generate.