# Re: why does git perpetually complain about include/asm-blackfin/macros.h?

14 messages from 2007-07-02 to 2007-07-14. Participants: Jeff Garzik, Jesper Juhl, Alex Riesen, Robert P. J. Day, Marco Roeland, Linus Torvalds, Bryan Wu, Sam Ravnborg.
Thread: https://gitlist.dev/t/8808

## Jeff Garzik, 2007-07-02 12:29

Subject: Re: why does git perpetually complain about include/asm-blackfin/macros.h?
Message-ID: <4688EF9B.8020405@garzik.org>
URL: https://gitlist.dev/e/4688EF9B.8020405%40garzik.org
In-Reply-To: <Pine.LNX.4.64.0707020800010.1972@localhost.localdomain>

```
Robert P. J. Day wrote:
>   for the umpteenth time, after doing a pull, i see this:
> 
> $ git diff
> diff --git a/include/asm-blackfin/macros.h b/include/asm-blackfin/macros.h
> deleted file mode 100644
> index e69de29..0000000
> $

I have the same problem.  git 1.5.0.6 on Fedora Core 5 or 6.

I even tried a completely fresh clone, but the problem still appears.

	Jeff

```

## Jesper Juhl, 2007-07-02 13:58

Subject: Re: why does git perpetually complain about include/asm-blackfin/macros.h?
Message-ID: <9a8748490707020658t5e6542ag6edb435dbc4499ab@mail.gmail.com>
URL: https://gitlist.dev/e/9a8748490707020658t5e6542ag6edb435dbc4499ab%40mail.gmail.com
In-Reply-To: <4688EF9B.8020405@garzik.org>

```
On 02/07/07, Jeff Garzik <jeff@garzik.org> wrote:
> Robert P. J. Day wrote:
> >   for the umpteenth time, after doing a pull, i see this:
> >
> > $ git diff
> > diff --git a/include/asm-blackfin/macros.h b/include/asm-blackfin/macros.h
> > deleted file mode 100644
> > index e69de29..0000000
> > $
>
> I have the same problem.  git 1.5.0.6 on Fedora Core 5 or 6.
>
> I even tried a completely fresh clone, but the problem still appears.
>
I've seen that as well, but in my case doing a
$ git reset --hard master
fixed it.

-- 
Jesper Juhl <jesper.juhl@gmail.com>
Don't top-post  http://www.catb.org/~esr/jargon/html/T/top-post.html
Plain text mails only, please      http://www.expita.com/nomime.html

```

## Jeff Garzik, 2007-07-02 14:10

Subject: Re: why does git perpetually complain about include/asm-blackfin/macros.h?
Message-ID: <4689073D.1020802@garzik.org>
URL: https://gitlist.dev/e/4689073D.1020802%40garzik.org
In-Reply-To: <9a8748490707020658t5e6542ag6edb435dbc4499ab@mail.gmail.com>

```
Jesper Juhl wrote:
> On 02/07/07, Jeff Garzik <jeff@garzik.org> wrote:
>> Robert P. J. Day wrote:
>> >   for the umpteenth time, after doing a pull, i see this:
>> >
>> > $ git diff
>> > diff --git a/include/asm-blackfin/macros.h 
>> b/include/asm-blackfin/macros.h
>> > deleted file mode 100644
>> > index e69de29..0000000
>> > $
>>
>> I have the same problem.  git 1.5.0.6 on Fedora Core 5 or 6.
>>
>> I even tried a completely fresh clone, but the problem still appears.
>>
> I've seen that as well, but in my case doing a
> $ git reset --hard master
> fixed it.

Sure.  git checkout -f fixes it too.

But then it reappears the every time I switch branches.

	Jeff

```

## Robert P. J. Day, 2007-07-02 14:22

Subject: Re: why does git perpetually complain about include/asm-blackfin/macros.h?
Message-ID: <Pine.LNX.4.64.0707021021090.20805@localhost.localdomain>
URL: https://gitlist.dev/e/Pine.LNX.4.64.0707021021090.20805%40localhost.localdomain
In-Reply-To: <4689073D.1020802@garzik.org>

```
On Mon, 2 Jul 2007, Jeff Garzik wrote:

> Jesper Juhl wrote:
> > On 02/07/07, Jeff Garzik <jeff@garzik.org> wrote:
> > > Robert P. J. Day wrote:
> > > >   for the umpteenth time, after doing a pull, i see this:
> > > >
> > > > $ git diff
> > > > diff --git a/include/asm-blackfin/macros.h
> > > b/include/asm-blackfin/macros.h
> > > > deleted file mode 100644
> > > > index e69de29..0000000
> > > > $
> > >
> > > I have the same problem.  git 1.5.0.6 on Fedora Core 5 or 6.
> > >
> > > I even tried a completely fresh clone, but the problem still appears.
> > >
> > I've seen that as well, but in my case doing a
> > $ git reset --hard master
> > fixed it.
>
> Sure.  git checkout -f fixes it too.
>
> But then it reappears the every time I switch branches.

same here -- checkout fixes it, but back it comes after the next pull.
not fatal -- just annoying.

rday
-- 
========================================================================
Robert P. J. Day
Linux Consulting, Training and Annoying Kernel Pedantry
Waterloo, Ontario, CANADA

http://fsdev.net/wiki/index.php?title=Main_Page
========================================================================

```

## Alex Riesen, 2007-07-02 14:22

Subject: Re: why does git perpetually complain about include/asm-blackfin/macros.h?
Message-ID: <81b0412b0707020722q25e8eb41t456e7316fe4a7b40@mail.gmail.com>
URL: https://gitlist.dev/e/81b0412b0707020722q25e8eb41t456e7316fe4a7b40%40mail.gmail.com
In-Reply-To: <4689073D.1020802@garzik.org>

```
On 7/2/07, Jeff Garzik <jeff@garzik.org> wrote:
> Jesper Juhl wrote:
> > On 02/07/07, Jeff Garzik <jeff@garzik.org> wrote:
> >> Robert P. J. Day wrote:
> >> >   for the umpteenth time, after doing a pull, i see this:
> >> >
> >> > $ git diff
> >> > diff --git a/include/asm-blackfin/macros.h
> >> b/include/asm-blackfin/macros.h
> >> > deleted file mode 100644
> >> > index e69de29..0000000
> >> > $
> >>
> >> I have the same problem.  git 1.5.0.6 on Fedora Core 5 or 6.
> >>
> >> I even tried a completely fresh clone, but the problem still appears.
> >>
> > I've seen that as well, but in my case doing a
> > $ git reset --hard master
> > fixed it.
>
> Sure.  git checkout -f fixes it too.
>
> But then it reappears the every time I switch branches.
>

Do some of your branches miss the commit by which it was removed?
(It was removed in df30b1171714bbf0e55ffe02138be4b8447e4235)
Than it will reappear every time you switch to a branch which still has
the file.

It is somewhat unclear what "reappear" means, though: do you mean
in your working directory (that's what I explained above) or do you
mean: on the commit pointed by HEAD?

In that second case I can only suspect that all your branches point
at the same commit, which is just before the one the file was removed
in...

```

## Marco Roeland, 2007-07-02 14:24

Subject: Re: why does git perpetually complain about include/asm-blackfin/macros.h?
Message-ID: <20070702142430.GA10400@fiberbit.xs4all.nl>
URL: https://gitlist.dev/e/20070702142430.GA10400%40fiberbit.xs4all.nl
In-Reply-To: <9a8748490707020658t5e6542ag6edb435dbc4499ab@mail.gmail.com>

```
On Monday July 2nd 2007 at 15:58 Jesper Juhl wrote:

> [obnoxious zero sized file include/asm-blackfin/macros.h that gets
>  zapped by toolchains and resurrected again by git]
>
> I've seen that as well, but in my case doing a
> $ git reset --hard master
> fixed it.

Dangerous, as it may overwrite local changes you have! A simple "git
checkout include/asm-blackfin/macros.h" is much safer in this case.

In git commit df30b11 this file got redundant. Perhaps because a normal
patch was applied, instead of with git, the file didn't get deleted from
the repository but truncated to size zero. Not strictly wrong perse, but
for the Linux repository highly unusual (and the only one at that).

Your toolchain perhaps deletes files with zero size after cleaning up or
something. Git then notices that you deleted this file.

Perhaps someone can apply something like the following to finally fix
this up:

commit 7d98740800f3d9ad2428afa8c677be9573a51b7b
Author: Marco Roeland <marco.roeland@xs4all.nl>
Date:   Mon Jul 2 16:19:49 2007 +0200

    Blackfin arch: remove zero-sized include/asm-blackfin/macros.h
    
    This file accidentally got truncated instead of deleted in commit df30b11.
    
    Signed-off-by: Marco Roeland <marco.roeland@xs4all.nl>

diff --git a/include/asm-blackfin/macros.h b/include/asm-blackfin/macros.h
deleted file mode 100644
index e69de29..0000000

```

## Alex Riesen, 2007-07-02 14:25

Subject: Re: why does git perpetually complain about include/asm-blackfin/macros.h?
Message-ID: <81b0412b0707020725t2e95b972y2d52ec902a31a616@mail.gmail.com>
URL: https://gitlist.dev/e/81b0412b0707020725t2e95b972y2d52ec902a31a616%40mail.gmail.com
In-Reply-To: <81b0412b0707020722q25e8eb41t456e7316fe4a7b40@mail.gmail.com>

```
On 7/2/07, Alex Riesen <raa.lkml@gmail.com> wrote:
> In that second case I can only suspect that all your branches point
> at the same commit, which is just before the one the file was removed
> in...

_Not_ the same. Just some commit before the file was removed, of course.

```

## Marco Roeland, 2007-07-02 14:29

Subject: Re: why does git perpetually complain about include/asm-blackfin/macros.h?
Message-ID: <20070702142926.GB10400@fiberbit.xs4all.nl>
URL: https://gitlist.dev/e/20070702142926.GB10400%40fiberbit.xs4all.nl
In-Reply-To: <81b0412b0707020722q25e8eb41t456e7316fe4a7b40@mail.gmail.com>

```
On Monday July 2nd 2007 at 16:22 Alex Riesen wrote:

> Do some of your branches miss the commit by which it was removed?
> (It was removed in df30b1171714bbf0e55ffe02138be4b8447e4235)
> Than it will reappear every time you switch to a branch which still has
> the file.

The problem is that this commit didn't delete the file, but truncated it
to zero size. How it got to be like that is another matter. Within the
kernel zero sized files are not supposed to be there, by widely accepted
practice. So lots of tools assume they should delete them!
-- 
Marco Roeland

```

## Jeff Garzik, 2007-07-02 14:37

Subject: Re: why does git perpetually complain about include/asm-blackfin/macros.h?
Message-ID: <46890DA8.4070400@garzik.org>
URL: https://gitlist.dev/e/46890DA8.4070400%40garzik.org
In-Reply-To: <81b0412b0707020722q25e8eb41t456e7316fe4a7b40@mail.gmail.com>

```
Alex Riesen wrote:
> Do some of your branches miss the commit by which it was removed?

git-clone followed by git-checkout master recreates the problem.

But to answer your question directly, I rebase, so they absolutely do 
not miss any commits.


> It is somewhat unclear what "reappear" means, though: do you mean

Attempts to give you precise output to answer your question yielded a 
data point, the kernel's "make distclean" causes this:

[jgarzik@pretzel linux-2.6]$ make distclean && git checkout master && 
git diff HEAD
D       include/asm-blackfin/macros.h
Switched to branch "master"
diff --git a/include/asm-blackfin/macros.h b/include/asm-blackfin/macros.h
deleted file mode 100644
index e69de29..0000000

[jgarzik@pretzel linux-2.6]$ git checkout -f

[jgarzik@pretzel linux-2.6]$ make distclean && git checkout master && 
git diff HEAD
D       include/asm-blackfin/macros.h
Switched to branch "master"
diff --git a/include/asm-blackfin/macros.h b/include/asm-blackfin/macros.h
deleted file mode 100644
index e69de29..0000000

[jgarzik@pretzel linux-2.6]$ git checkout -f

[jgarzik@pretzel linux-2.6]$ git checkout master && git diff 
HEADSwitched to branch "master"

[jgarzik@pretzel linux-2.6]$ git checkout master && git diff HEAD
Switched to branch "master"

[jgarzik@pretzel linux-2.6]$


So, not a git problem but a kernel Makefile problem.  Sorry for the git 
noise.

	Jeff

```

## Marco Roeland, 2007-07-02 15:09

Subject: [PATCH] Blackfin arch: include/asm-blackfin/macros.h die die die
Message-ID: <20070702150915.GC10400@fiberbit.xs4all.nl>
URL: https://gitlist.dev/e/20070702150915.GC10400%40fiberbit.xs4all.nl
In-Reply-To: <20070702142926.GB10400@fiberbit.xs4all.nl>

```
This file accidentally got truncated instead of deleted in commit df30b11.
Doing a "make distclean" or "make mrproper" deletes this file because of
its zero size. Git then sees this as an uncommitted local change.

Signed-off-by: Marco Roeland <marco.roeland@xs4all.nl>
---
 0 files changed, 0 insertions(+), 0 deletions(-)
 delete mode 100644 include/asm-blackfin/macros.h

diff --git a/include/asm-blackfin/macros.h b/include/asm-blackfin/macros.h
deleted file mode 100644
index e69de29..0000000
-- 
1.5.2.2.1451.gb0e5e

```

## Linus Torvalds, 2007-07-02 15:36

Subject: Re: why does git perpetually complain about include/asm-blackfin/macros.h?
Message-ID: <alpine.LFD.0.98.0707020834310.9434@woody.linux-foundation.org>
URL: https://gitlist.dev/e/alpine.LFD.0.98.0707020834310.9434%40woody.linux-foundation.org
In-Reply-To: <4688EF9B.8020405@garzik.org>

```


On Mon, 2 Jul 2007, Jeff Garzik wrote:

> Robert P. J. Day wrote:
> >   for the umpteenth time, after doing a pull, i see this:
> > 
> > $ git diff
> > diff --git a/include/asm-blackfin/macros.h b/include/asm-blackfin/macros.h
> > deleted file mode 100644
> > index e69de29..0000000
> > $
> 
> I have the same problem.  git 1.5.0.6 on Fedora Core 5 or 6.
> 
> I even tried a completely fresh clone, but the problem still appears.

Git complains for a very simple reason: that file is an empty file, and 
"make clean" removes all zero-sized files.

So whenever anybody does a "make clean" (maybe it's "make distclean", I 
forget), you will have removed the empty file, and git will show it as a 
diff.

We probably should just remove the file from the kernel archive.

		Linus

```

## Bryan Wu, 2007-07-03 00:28

Subject: Re: why does git perpetually complain about include/asm-blackfin/macros.h?
Message-ID: <1183422489.10353.2.camel@roc-laptop>
URL: https://gitlist.dev/e/1183422489.10353.2.camel%40roc-laptop
In-Reply-To: <20070702142430.GA10400@fiberbit.xs4all.nl>

```
On Mon, 2007-07-02 at 16:24 +0200, Marco Roeland wrote:
> On Monday July 2nd 2007 at 15:58 Jesper Juhl wrote:
> 
> > [obnoxious zero sized file include/asm-blackfin/macros.h that gets
> >  zapped by toolchains and resurrected again by git]
> >
> > I've seen that as well, but in my case doing a
> > $ git reset --hard master
> > fixed it.
> 
> Dangerous, as it may overwrite local changes you have! A simple "git
> checkout include/asm-blackfin/macros.h" is much safer in this case.
> 
> In git commit df30b11 this file got redundant. Perhaps because a normal
> patch was applied, instead of with git, the file didn't get deleted from
> the repository but truncated to size zero. Not strictly wrong perse, but
> for the Linux repository highly unusual (and the only one at that).
> 
> Your toolchain perhaps deletes files with zero size after cleaning up or
> something. Git then notices that you deleted this file.
> 
> Perhaps someone can apply something like the following to finally fix
> this up:
> 
> commit 7d98740800f3d9ad2428afa8c677be9573a51b7b
> Author: Marco Roeland <marco.roeland@xs4all.nl>
> Date:   Mon Jul 2 16:19:49 2007 +0200
> 
>     Blackfin arch: remove zero-sized include/asm-blackfin/macros.h
>     
>     This file accidentally got truncated instead of deleted in commit df30b11.
>     
>     Signed-off-by: Marco Roeland <marco.roeland@xs4all.nl>
> 
> diff --git a/include/asm-blackfin/macros.h b/include/asm-blackfin/macros.h
> deleted file mode 100644
> index e69de29..0000000
> -

Thanks, Applied to the blackfin-2.6.git tree for Linus pull.

- Bryan

> To unsubscribe from this list: send the line "unsubscribe git" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html

```

## Bryan Wu, 2007-07-03 00:39

Subject: Re: [PATCH] Blackfin arch: include/asm-blackfin/macros.h die die die
Message-ID: <1183423159.10353.10.camel@roc-laptop>
URL: https://gitlist.dev/e/1183423159.10353.10.camel%40roc-laptop
In-Reply-To: <20070702150915.GC10400@fiberbit.xs4all.nl>

```
On Mon, 2007-07-02 at 17:09 +0200, Marco Roeland wrote:
> This file accidentally got truncated instead of deleted in commit df30b11.
> Doing a "make distclean" or "make mrproper" deletes this file because of
> its zero size. Git then sees this as an uncommitted local change.
> 
> Signed-off-by: Marco Roeland <marco.roeland@xs4all.nl>
> ---
>  0 files changed, 0 insertions(+), 0 deletions(-)
>  delete mode 100644 include/asm-blackfin/macros.h
> 
> diff --git a/include/asm-blackfin/macros.h b/include/asm-blackfin/macros.h
> deleted file mode 100644
> index e69de29..0000000

Thanks already in blackfin-2.6.git tree for Linus pull
Acked by: Bryan Wu <bryan.wu@analog.com>

```

## Sam Ravnborg, 2007-07-14 07:45

Subject: Re: why does git perpetually complain about include/asm-blackfin/macros.h?
Message-ID: <20070714074558.GA8047@uranus.ravnborg.org>
URL: https://gitlist.dev/e/20070714074558.GA8047%40uranus.ravnborg.org
In-Reply-To: <46890DA8.4070400@garzik.org>

```
On Mon, Jul 02, 2007 at 10:37:28AM -0400, Jeff Garzik wrote:
> Alex Riesen wrote:
> >Do some of your branches miss the commit by which it was removed?
> 
> git-clone followed by git-checkout master recreates the problem.
> 
> But to answer your question directly, I rebase, so they absolutely do 
> not miss any commits.
> 
> 
> >It is somewhat unclear what "reappear" means, though: do you mean
> 
> Attempts to give you precise output to answer your question yielded a 
> data point, the kernel's "make distclean" causes this:
> 
> [jgarzik@pretzel linux-2.6]$ make distclean && git checkout master && 
> git diff HEAD
> D       include/asm-blackfin/macros.h
> Switched to branch "master"
> diff --git a/include/asm-blackfin/macros.h b/include/asm-blackfin/macros.h
> deleted file mode 100644
> index e69de29..0000000
> 
> [jgarzik@pretzel linux-2.6]$ git checkout -f
> 
> [jgarzik@pretzel linux-2.6]$ make distclean && git checkout master && 
> git diff HEAD
> D       include/asm-blackfin/macros.h
> Switched to branch "master"
> diff --git a/include/asm-blackfin/macros.h b/include/asm-blackfin/macros.h
> deleted file mode 100644
> index e69de29..0000000
> 
> [jgarzik@pretzel linux-2.6]$ git checkout -f
> 
> [jgarzik@pretzel linux-2.6]$ git checkout master && git diff 
> HEADSwitched to branch "master"
> 
> [jgarzik@pretzel linux-2.6]$ git checkout master && git diff HEAD
> Switched to branch "master"
> 
> [jgarzik@pretzel linux-2.6]$
> 
> 
> So, not a git problem but a kernel Makefile problem.  Sorry for the git 
> noise.

distclean on purpose delete zero size files.
And the kernel tree shall not contain such files - if it does it is a bug.

So I do not see a 'problem' with the kernel makefile but instead a problem
with the kernel tree wich is about to be fixed.

Agree?

	Sam

```
