Skip to content

Commit

Permalink
update ci workflow for github
Browse files Browse the repository at this point in the history
  • Loading branch information
cnangel committed Aug 22, 2023
1 parent 6dd5b57 commit dd79bcb
Show file tree
Hide file tree
Showing 4 changed files with 44 additions and 21 deletions.
25 changes: 23 additions & 2 deletions .github/workflows/c-cpp.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ jobs:
- name: "update packages"
run: dnf update -y
- name: "install sudo,git"
run: dnf install -y sudo git automake make autoconf m4 libtool gcc procps jq jo
run: dnf install -y sudo git automake make autoconf m4 libtool gcc gcc-c++ procps jq jo rpm-build rpm-sign
- name: "System Information"
run: |
echo === uname ===
Expand All @@ -38,6 +38,10 @@ jobs:
env
echo === gcc -v ===
gcc -v
echo === pwd ===
pwd
echo === \$HOME ===
echo $HOME
- name: "checkout sources"
uses: actions/checkout@v3
- name: autogen
Expand All @@ -50,5 +54,22 @@ jobs:
run: make check
- name: make distcheck
run: make distcheck
- name: Archive artifacts
uses: actions/upload-artifact@v3
with:
name: packages-source
path: libchardet-*.tar.gz
- name: make rpm
run: make rpm
run: |
curdir=$(pwd)
mkdir -p ${curdir}/target/{BUILD,RPMS,SOURCES,SPECS,SRPMS}
echo "%_topdir $curdir/target" > $HOME/.rpmmacros
cat $HOME/.rpmmacros
ls -l ${curdir}/target/SOURCES
make rpm
- name: create release (Fedora38)
uses: actions/upload-artifact@v3
with:
name: packages-fedora38
path: target/RPMS/x86_64/libchardet-*.rpm

33 changes: 17 additions & 16 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,29 +1,30 @@
**Makefile
**Makefile.in
**~
aclocal.m4
config.sub
autom4te.cache
**.bak
compile
config.guess
config.h
config.h.in
config.log
config.status
config.sub
configure
*.deps
*.la
.libs
libtool
*.lo
*.log
*.loT
ltmain.sh
**Makefile
**Makefile.in
*.o
pkgconfig/libchardet.pc
*.spec
src/chardetor
src/Makefile
src/Makefile.in
autom4te.cache
**~
**.bak
*.o
*.lo
*.loT
.libs
*.la
*.swp
src/chardetor
*.deps
*.log
*.tar.gz
*.spec
pkgconfig/libchardet.pc
5 changes: 3 additions & 2 deletions libchardet.spec.in
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

Name: libchardet
Version: @VERSION@
Release: 1
Release: 2

Summary: a library for charset detector
License: GPLv3
Expand Down Expand Up @@ -61,10 +61,11 @@ fi
%defattr(-,root,root,-)
%{_includedir}
%{_libdir}/*.a
%{_libdir}/*.la
%{_libdir}/pkgconfig/libchardet.pc

%changelog
* Tue Aug 22 2023 Cnangel <[email protected]> 0.9.0-2
- support fedora38
* Thu Mar 03 2011 Cnangel <[email protected]> 0.9.0-1
- add pc file.
* Tue Mar 23 2010 Cnangel <[email protected]> 0.8.0-1
Expand Down
2 changes: 1 addition & 1 deletion src/Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ LangCyrillicModel.cpp

AM_CXXFLAGS = -Wall -Wno-non-virtual-dtor -nostdinc++ -fno-rtti -fno-exceptions
include_HEADERS = chardet.h
libchardet_la_CPPFLAGS = -nostdinc++ -fno-rtti -fno-exceptions -I tables
libchardet_la_CPPFLAGS = -nostdinc++ -fno-rtti -fno-exceptions -I${top_srcdir}/src/tables

bin_PROGRAMS = chardetor
chardetor_SOURCES = chardetor.cpp
Expand Down

0 comments on commit dd79bcb

Please sign in to comment.