File tree Expand file tree Collapse file tree 4 files changed +63
-21
lines changed Expand file tree Collapse file tree 4 files changed +63
-21
lines changed Original file line number Diff line number Diff line change @@ -39,7 +39,7 @@ PackageBuild()
39
39
40
40
local sourceDir;
41
41
sourceDir=$( ./latest.sh \
42
- --host=' github' \
42
+ --host=' github-master ' \
43
43
--package=" webmproject/${package} " \
44
44
-b=" $buildDir "
45
45
) ;
@@ -56,16 +56,22 @@ PackageBuild()
56
56
DieIfFails ./make.sh \
57
57
-b=" $buildDir " \
58
58
-s=" $sourceDir " \
59
- --configure-options=" \
60
- --prefix=$prefix \
61
- " \
62
- --dest-dir=" $destDir " \
63
- --install-options=" install-strip" ;
64
-
65
- local pkgconfigDir=" $dirBin /pkgconfig" ;
66
-
67
- DieIfFails ./adjust-pkgconfig.sh \
68
- -d=" $destDir " \
69
- --prefix=" $prefix " \
70
- -o=" $pkgconfigDir " ;
59
+ --in-source \
60
+ --no-configure \
61
+ --no-install;
62
+
63
+ # manually install. Because there ain't none of that in the makefile
64
+ Log ' Manually installing...'
65
+
66
+ local installDir=" ${destDir} /${prefix} " ;
67
+ printf ' installing to "%s"\n' " $installDir " ;
68
+
69
+ DieIfFails DeleteAllFiles " $installDir " ;
70
+
71
+ for d in include lib; do
72
+ DieIfFails mkdir -p " ${installDir} /${d} " ;
73
+ done
74
+
75
+ DieIfFails cp " ${sourceDir} /src/sjpeg.h" " ${installDir} /include/"
76
+ DieIfFails cp " ${sourceDir} /src/libsjpeg.a" " ${installDir} /lib/"
71
77
}
Original file line number Diff line number Diff line change
1
+ --- sjpeg-master/Makefile
2
+ +++ new/Makefile
3
+ @@ -22,13 +22,9 @@
4
+ EXTRA_FLAGS += -I/opt/local/include
5
+ EXTRA_FLAGS += -Wno-deprecated-declarations
6
+ EXTRA_LIBS += -L/opt/local/lib
7
+ - GL_LIBS = -framework GLUT -framework OpenGL
8
+ - EXTRA_FLAGS += -DHAVE_GLUT_GLUT_H
9
+ else
10
+ EXTRA_FLAGS += -I/usr/local/include
11
+ EXTRA_LIBS += -L/usr/local/lib
12
+ - GL_LIBS = -lglut -lGL
13
+ - EXTRA_FLAGS += -DHAVE_GL_GLUT_H
14
+ endif
15
+
16
+ # Uncomment for build for 32bit platform
Original file line number Diff line number Diff line change @@ -128,9 +128,16 @@ ExtractSource()
128
128
# contents with "tar -t" or extract it. Since we are going to extract it
129
129
# anyway...
130
130
if ! tar -C " $_tmpDir " -xf " ${_buildDir} /${_tarName} " ; then
131
- # if tar fails, try extracting with 7z. 7z will output a bunch of stuff
132
- # so we must redirect the output to /dev/null
133
- DieIfFails 7z x " ${_buildDir} /${_tarName} " -o" $_tmpDir " > /dev/null
131
+ case " $_tarName " in
132
+ * .zip)
133
+ DieIfFails unzip -q -d " $_tmpDir " " ${_buildDir} /${_tarName} " ;
134
+ ;;
135
+ * )
136
+ # try extracting with 7z. 7z will output a bunch of stuff
137
+ # so we must redirect the output to /dev/null
138
+ DieIfFails 7z x " ${_buildDir} /${_tarName} " -o" ${_tmpDir} /" > /dev/null
139
+ ;;
140
+ esac
134
141
fi
135
142
136
143
local version=$( find " $_tmpDir " -maxdepth 1 -mindepth 1) ;
@@ -140,12 +147,13 @@ ExtractSource()
140
147
Die " unable to retrieve the latest version name" ;
141
148
fi
142
149
143
- # and now we can finaly move it out of there
150
+ # and now we can finaly move it out of there
144
151
DieIfFails rm -rf " ${_buildDir} /${version} " ;
145
152
DieIfFails mv " ${_tmpDir} /${version} " " ${_buildDir} /"
146
153
147
- local sourceDir=" ${_buildDir} /" $( printf ' %s' " $version " | sed ' s;\(.*\).tar.*$;\1;' ) ;
148
-
154
+ # local sourceDir="${_buildDir}/"$(printf '%s' "$version" | sed 's;\(.*\).tar.*$;\1;');
155
+ local sourceDir=" ${_buildDir} /${version} " ;
156
+
149
157
printf ' %s' " $sourceDir " ;
150
158
}
151
159
Original file line number Diff line number Diff line change @@ -42,7 +42,7 @@ PrintUsage()
42
42
--gnome-ignore9x
43
43
useful when dealing with GTK related packages because GTK devs are insane
44
44
and decided that the .9x branches are actualy betas of the next major
45
- version.
45
+ version.
46
46
47
47
--host
48
48
lots of source codes are stored in very popular hosts. That (sometimes)
@@ -62,8 +62,11 @@ PrintUsage()
62
62
selecting the correct one, you can use --github-regex to specify a regular
63
63
expression capable of selected the one you need.
64
64
65
+ "github-master"
66
+ retrieve the latest commit on the master branch.
67
+
65
68
"github-tag"
66
- same as above , but the project is using tags instead of releases
69
+ same as "github" , but the project is using tags instead of releases
67
70
68
71
"gitlab"
69
72
package is hosted on gitlab and the latest source code can be retrieved
@@ -311,6 +314,12 @@ content:
311
314
}
312
315
313
316
317
+ GithubMaster ()
318
+ {
319
+ _urlTar=" https://github.com/${_package} /archive/master.zip" ;
320
+ }
321
+
322
+
314
323
GithubTag ()
315
324
{
316
325
local url=" https://api.github.com/repos/${_package} /tags" ;
@@ -528,6 +537,9 @@ LatestVersion()
528
537
github)
529
538
Github;
530
539
;;
540
+ github-master)
541
+ GithubMaster;
542
+ ;;
531
543
github-tag)
532
544
GithubTag;
533
545
;;
You can’t perform that action at this time.
0 commit comments